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

[vcpkg-tool] /source/src/vcpkg/commands.build.cpp(1723): unreachable code was reached #43501

Closed
dg0yt opened this issue Jan 27, 2025 · 5 comments · Fixed by #43525
Closed

[vcpkg-tool] /source/src/vcpkg/commands.build.cpp(1723): unreachable code was reached #43501

dg0yt opened this issue Jan 27, 2025 · 5 comments · Fixed by #43525

Comments

@dg0yt
Copy link
Contributor

dg0yt commented Jan 27, 2025

Describe the bug
When the source download fails, the vcpkg tool reaches "unreachable code".

Environment

  • OS: Linux

To Reproduce
Steps to reproduce the behavior:

  1. Bump sdl3-image version.
  2. Install sdl3-image

Expected behavior
Just a normal error.

Failure logs

Installing 2/2 sdl3-image:[email protected]...
Building sdl3-image:[email protected]...
Downloading https://github.com/libsdl-org/SDL_image/archive/preview-3.1.1.tar.gz -> libsdl-org-SDL_image-preview-3.1.1.tar.gz
error: curl: (22) The requested URL returned error: 404 
note: If you are using a proxy, please ensure your proxy settings are correct.
Possible causes are:
1. You are actually using an HTTP proxy, but setting HTTPS_PROXY variable to `https//address:port`.
This is not correct, because `https://` prefix claims the proxy is an HTTPS proxy, while your proxy (v2ray, shadowsocksr, etc...) is an HTTP proxy.
Try setting `http://address:port` to both HTTP_PROXY and HTTPS_PROXY instead.
2. If you are using Windows, vcpkg will automatically use your Windows IE Proxy Settings set by your proxy software. See: https://github.com/microsoft/vcpkg-tool/pull/77
The value set by your proxy might be wrong, or have same `https://` prefix issue.
3. Your proxy's remote server is our of service.
If you've tried directly download the link, and believe this is not a temporary download server failure, please submit an issue at https://github.com/Microsoft/vcpkg/issues
to report this upstream download server failure.
CMake Error at scripts/cmake/vcpkg_download_distfile.cmake:231 (message):
  Download failed, halting portfile.
Call Stack (most recent call first):
  scripts/cmake/vcpkg_from_github.cmake:106 (vcpkg_download_distfile)
  ports/sdl3-image/portfile.cmake:1 (vcpkg_from_github)
  scripts/ports.cmake:196 (include)


error: building sdl3-image:x64-linux failed with: BUILD_FAILED
See https://learn.microsoft.com/vcpkg/troubleshoot/build-failures?WT.mc_id=vcpkg_inproduct_cli for more information.
Elapsed time to handle sdl3-image:x64-linux: 240 ms
/source/src/vcpkg/commands.build.cpp(1723): unreachable code was reached

Additional context

$ ./vcpkg --version
vcpkg package management program version 2025-01-24-874e302b1fa28cc81caefbb1483f80103c51ab52

See LICENSE.txt for license information.
@dg0yt
Copy link
Contributor Author

dg0yt commented Jan 27, 2025

... also for (some) build errors.

@autoantwort
Copy link
Contributor

Can you test if microsoft/vcpkg-tool#1588 fix it

@BillyONeal
Copy link
Member

:sigh: I saw this happen once and fixed it in microsoft/vcpkg-tool@cfd44ca but didn't see it happen in 'release' builds so I assumed I didn't need to do an immediate release for it.

This is my bug, @autoantwort 's original PR didn't have the problem and I introduced it trying to staple it to our existing CI detection.

@BillyONeal
Copy link
Member

Please try 2025-01-29 and let us know if it is fixed ( #43525 )

@BillyONeal
Copy link
Member

I'm just going to go ahead with that release with the understanding that it will resolve this. If it does not for you, please reopen.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
3 participants