You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have a fairly simple VS 2022 solution, which uses vcpkg in manifest mode. I can build locally without issues, but I can’t make my Azure DevOps pipeline to install the dependencies listed in the vcpkg.json file.
I'm building using VS2022 and the windows-2022 image on Azure DevOps on a hosted agent.
The build fails because it can’t find the includes that should have been installed by vcpkg. What is happening is that the build step simply does not install the required dependencies listed in the vcpkg.json file. Here is the log of the failing job.
PrepareForBuild:
Creating directory "x64\Release\".
Creating directory "x64\Release\AD. BEMStub.tlog\".
InitializeBuildStatus:
Creating "x64\Release\AD. BEMStub.tlog\unsuccessfulbuild" because "AlwaysCreate" was specified.
ClCompile:
C:\Program Files\Microsoft Visual Studio\2022\Enterprise\VC\Tools\MSVC\14.35.32215\bin\HostX64\x64\CL.exe /c /I.. /BEM.MT_AD. Common/include /Zi /nologo /W4 /WX- /diagnostics:column /sdl /MP /O2 /Oi /GL /D _WIN32_WINNT=0x0A00 /D NDEBUG /D _CONSOLE /D _UNICODE /D UNICODE /Gm- /EHsc /MD /GS /Gy /fp:precise /Zc:wchar_t /Zc:forScope /Zc:inline /std:c++20 /permissive- /Fo"x64\Release\\" /Fd"x64\Release\vc143.pdb" /external:W4 /Gd /TP /FC /errorReport: queue main.cpp Receiver.cpp
main.cpp
Receiver.cpp
##[error]AD. BEMStub\Receiver.h(8,10): Error C1083: Cannot open include file: 'asio.hpp': No such file or directory (compiling source file main.cpp)
D:\a\1\s\AD. BEMStub\Receiver.h(8,10): fatal error C1083: Cannot open include file: 'asio.hpp': No such file or directory (compiling source file main.cpp) [D:\a\1\s\AD. BEMStub\AD. BEMStub.vcxproj]
##[error]AD. BEMStub\Receiver.h(8,10): Error C1083: Cannot open include file: 'asio.hpp': No such file or directory (compiling source file Receiver.cpp)
D:\a\1\s\AD. BEMStub\Receiver.h(8,10): fatal error C1083: Cannot open include file: 'asio.hpp': No such file or directory (compiling source file Receiver.cpp) [D:\a\1\s\AD. BEMStub\AD. BEMStub.vcxproj]
Done Building Project "D:\a\1\s\AD. BEMStub\AD. BEMStub.vcxproj" (default targets) -- FAILED.
Done Building Project "D:\a\1\s\AD. Diva.sln" (default targets) -- FAILED.
Build FAILED.
"D:\a\1\s\AD. Diva.sln" (default target) (1) ->
"D:\a\1\s\AD. Diva\AD. Diva.vcxproj" (default target) (2) ->
"D:\a\1\s\AD. Diva.Library\AD. Diva.Library.vcxproj" (default target) (3) ->
(ClCompile target) ->
D:\a\1\s\AD. Diva.Library\src\Settings.cpp(2,10): fatal error C1083: Cannot open include file: 'toml.hpp': No such file or directory [D:\a\1\s\AD. Diva.Library\AD. Diva.Library.vcxproj]
D:\a\1\s\AD. Diva.Library\src\ConcreteLoggers.cpp(3,10): fatal error C1083: Cannot open include file: 'colorconsole.hpp': No such file or directory [D:\a\1\s\AD. Diva.Library\AD. Diva.Library.vcxproj]
"D:\a\1\s\AD. Diva.sln" (default target) (1) ->
"D:\a\1\s\AD. Diva.Sandbox\AD. Diva.Sandbox.vcxproj" (default target) (5) ->
D:\a\1\s\AD. Diva.Sandbox\src\Info.cpp(3,10): fatal error C1083: Cannot open include file: 'magic_enum.hpp': No such file or directory [D:\a\1\s\AD. Diva.Sandbox\AD. Diva.Sandbox.vcxproj]
D:\a\1\s\AD. Diva.Sandbox\src\main.cpp(5,10): fatal error C1083: Cannot open include file: 'AudioFile.h': No such file or directory [D:\a\1\s\AD. Diva.Sandbox\AD. Diva.Sandbox.vcxproj]
"D:\a\1\s\AD. Diva.sln" (default target) (1) ->
"D:\a\1\s\AD. BEMStub\AD. BEMStub.vcxproj" (default target) (7) ->
D:\a\1\s\AD. BEMStub\Receiver.h(8,10): fatal error C1083: Cannot open include file: 'asio.hpp': No such file or directory (compiling source file main.cpp) [D:\a\1\s\AD. BEMStub\AD. BEMStub.vcxproj]
D:\a\1\s\AD. BEMStub\Receiver.h(8,10): fatal error C1083: Cannot open include file: 'asio.hpp': No such file or directory (compiling source file Receiver.cpp) [D:\a\1\s\AD. BEMStub\AD. BEMStub.vcxproj]
0 Warning(s)
6 Error(s)
Time Elapsed 00:03:24.29
The projects in the solution all share the following vcpkg settings:
I've also tried to run msbuild on a new clone of my repo inside a clean machine with only VS2022 and vcpkg, and everything works as expected: in the first steps of the build process, msbuild installs the required vcpkg dependencies and then the build goes on with no issues.
What am I missing here?
The text was updated successfully, but these errors were encountered:
When vs uses vcpkg in manifest mode, you need to restart vs and reopen your own project. This is a known bug and we will fix it in a future release.
You need to confirm whether the corresponding port in the vcpkg_installed directory under the project directory is installed.
If you have any other questions, please let me know in time.
The problem occurs in Azure DevOps: locally everything works fine! I can't restart/reopen my project, nor I can check the vcpkg_intsalled directory on the build machine, since I'm using a hosted build agent.
This is an automated message. Per our repo policy, stale issues get closed if there has been no activity in the past 28 days. The issue will be automatically closed in 14 days. If you wish to keep this issue open, please add a new comment.
I have a fairly simple VS 2022 solution, which uses vcpkg in manifest mode. I can build locally without issues, but I can’t make my Azure DevOps pipeline to install the dependencies listed in the vcpkg.json file.
I'm building using VS2022 and the
windows-2022
image on Azure DevOps on a hosted agent.Here is my
azure-pipelines.yaml
The build fails because it can’t find the includes that should have been installed by vcpkg. What is happening is that the build step simply does not install the required dependencies listed in the
vcpkg.json
file. Here is the log of the failing job.The projects in the solution all share the following vcpkg settings:
The
vcpkg.json
file is very simple:I've also tried to run
msbuild
on a new clone of my repo inside a clean machine with only VS2022 and vcpkg, and everything works as expected: in the first steps of the build process, msbuild installs the required vcpkg dependencies and then the build goes on with no issues.What am I missing here?
The text was updated successfully, but these errors were encountered: