Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Forked vcpkg and tesseract breaks compilation due to old and obsolete packages removed from servers #1546

Open
netcorefan1 opened this issue Mar 11, 2023 · 2 comments
Labels

Comments

@netcorefan1
Copy link

netcorefan1 commented Mar 11, 2023

I'm trying to compile the wrapper as is, but without success. I'm unable to get the required dependencies from the forked vcpkg because many packages has been removed from the servers.

Environment

Windows 11 Pro, VS 17.5.1, MSVC v143

What did you do when you faced the problem?

Tried to use the downloadable Tesseract, but compilation failed due to inability to install its required dependencies.
I decided to build this myself because I want GPU support and an updated full featured version of OpenCv. Therefore I initially tried to link through the vcpkg CMAKE_TOOLCHAIN_FILE a very basic (no CUDA) version of OpenCv compiled through the official vcpkg repo and the latest tesseract. At the time of compilation I got plenty of errors even after having fixed the linked libraries version in OpenCvSharpExtern. There are dependencies (for example webp.lib, webpdecoder.lib, protobuf etc) that does not exists anymore from very long time in packages.
I would like to ask if it is possible to make OpenCvSharp compatible with the packages provided from the officially vcpkg repo rather than relying in a forked repo with more than 2000 commits behind.
As is I'm not sure if would be possible to link even a minimal recent version of OpenVc. Although downgrading working packages is something that I always try to avoid, I'm afraid that it will not work anyway without breaking the compilation.

Example code:

git clone https://github.com/shimat/vcpkg.git
.\bootstrap-vcpkg.bat
.\vcpkg.exe  install tesseract:x64-windows-static

Output:

The following packages will be built and installed:
  * bzip2[core]:x64-windows-static -> 1.0.8#2
  * giflib[core]:x64-windows-static -> 5.2.1#2
  * leptonica[core]:x64-windows-static -> 1.82.0
  * libarchive[bzip2,core,libxml2,lz4,lzma,openssl,zstd]:x64-windows-static -> 3.6.1
  * libiconv[core]:x64-windows-static -> 1.16#13
  * libjpeg-turbo[core]:x64-windows-static -> 2.1.3#3
  * liblzma[core]:x64-windows-static -> 5.2.5#6
  * libpng[core]:x64-windows-static -> 1.6.37#17
  * libwebp[core,libwebpmux,nearlossless,simd,unicode]:x64-windows-static -> 1.2.2
  * libxml2[core]:x64-windows-static -> 2.9.14
  * lz4[core]:x64-windows-static -> 1.9.3#3
  * openjpeg[core]:x64-windows-static -> 2.5.0
  * openssl[core]:x64-windows-static -> 3.0.3#2
    tesseract[core]:x64-windows-static -> 4.1.1#10
  * tiff[core,jpeg,lzma,zip]:x64-windows-static -> 4.4.0
  * vcpkg-cmake[core]:x64-windows -> 2022-05-10
  * vcpkg-cmake-config[core]:x64-windows -> 2022-02-06
  * vcpkg-cmake-get-vars[core]:x64-windows -> 2022-05-10
  * zlib[core]:x64-windows-static -> 1.2.12#1
  * zstd[core]:x64-windows-static -> 1.5.2#1
[DEBUG] To include the environment variables in debug output, pass --debug-env
[DEBUG] Feature flag 'binarycaching' unset
[DEBUG] Feature flag 'manifests' = off
[DEBUG] Feature flag 'compilertracking' unset
[DEBUG] Feature flag 'registries' unset
[DEBUG] Feature flag 'versions' unset
[DEBUG] Downloading https://repo.msys2.org/msys/x86_64/libtool-2.4.6-9-x86_64.pkg.tar.xz
[DEBUG] Downloading https://www2.futureware.at/~nickoe/msys2-mirror/msys/x86_64/libtool-2.4.6-9-x86_64.pkg.tar.xz
[DEBUG] Downloading https://mirror.yandex.ru/mirrors/msys2/msys/x86_64/libtool-2.4.6-9-x86_64.pkg.tar.xz
[DEBUG] Downloading https://mirrors.tuna.tsinghua.edu.cn/msys2/msys/x86_64/libtool-2.4.6-9-x86_64.pkg.tar.xz
[DEBUG] Downloading https://mirrors.ustc.edu.cn/msys2/msys/x86_64/libtool-2.4.6-9-x86_64.pkg.tar.xz
[DEBUG] Downloading https://mirror.bit.edu.cn/msys2/msys/x86_64/libtool-2.4.6-9-x86_64.pkg.tar.xz
[DEBUG] Download failed -- retrying after 1000 ms.
[DEBUG] Download failed -- retrying after 2000 ms.
[DEBUG] Download failed -- retrying after 4000 ms.
[DEBUG] Downloading https://mirror.selfnet.de/msys2/msys/x86_64/libtool-2.4.6-9-x86_64.pkg.tar.xz
[DEBUG] Downloading https://mirrors.sjtug.sjtu.edu.cn/msys2/msys/x86_64/libtool-2.4.6-9-x86_64.pkg.tar.xz
Error: Failed to download from mirror set:
https://repo.msys2.org/msys/x86_64/libtool-2.4.6-9-x86_64.pkg.tar.xz: failed: status code 404
https://www2.futureware.at/~nickoe/msys2-mirror/msys/x86_64/libtool-2.4.6-9-x86_64.pkg.tar.xz: failed: status code 404
https://mirror.yandex.ru/mirrors/msys2/msys/x86_64/libtool-2.4.6-9-x86_64.pkg.tar.xz: failed: status code 404
https://mirrors.tuna.tsinghua.edu.cn/msys2/msys/x86_64/libtool-2.4.6-9-x86_64.pkg.tar.xz: failed: status code 404
https://mirrors.ustc.edu.cn/msys2/msys/x86_64/libtool-2.4.6-9-x86_64.pkg.tar.xz: failed: status code 404
https://mirror.bit.edu.cn/msys2/msys/x86_64/libtool-2.4.6-9-x86_64.pkg.tar.xz: WinHttpSendRequest() failed: 12007
https://mirror.bit.edu.cn/msys2/msys/x86_64/libtool-2.4.6-9-x86_64.pkg.tar.xz: WinHttpSendRequest() failed: 12007
https://mirror.bit.edu.cn/msys2/msys/x86_64/libtool-2.4.6-9-x86_64.pkg.tar.xz: WinHttpSendRequest() failed: 12007
https://mirror.bit.edu.cn/msys2/msys/x86_64/libtool-2.4.6-9-x86_64.pkg.tar.xz: WinHttpSendRequest() failed: 12007
https://mirror.selfnet.de/msys2/msys/x86_64/libtool-2.4.6-9-x86_64.pkg.tar.xz: failed: status code 404
https://mirrors.sjtug.sjtu.edu.cn/msys2/msys/x86_64/libtool-2.4.6-9-x86_64.pkg.tar.xz: failed: status code 404

[DEBUG] D:\a\_work\1\s\src\vcpkg\base\downloads.cpp(751):
[DEBUG] Time in subprocesses: 0 us
[DEBUG] Time in parsing JSON: 2 us
[DEBUG] Time in JSON reader: 0 us
[DEBUG] Time in filesystem: 3924 us
[DEBUG] Time in loading ports: 0 us
[DEBUG] Exiting after 15.7 s (15694859 us)

CMake Error at scripts/cmake/vcpkg_download_distfile.cmake:84 (message):

      Failed to download file with error: 1
@n0099
Copy link
Contributor

n0099 commented Mar 11, 2023

@stale
Copy link

stale bot commented Sep 17, 2023

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

@stale stale bot added the wontfix label Sep 17, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants