Host Environment
To Reproduce
Steps to reproduce the behavior:
.\vcpkg.exe install --x-use-aria2 --recurse --keep-going --editable magnum[al-info,anyaudioimporter,anyimageconverter,anyimageimporter,anysceneconverter,anysceneimporter,audio,cglcontext,core,debugtools,distancefieldconverter,fontconverter,gl,gl-info,glfwapplication,imageconverter,magnumfont,magnumfontconverter,meshtools,objimporter,opengltester,primitives,scenegraph,sdl2application,shaders,text,texturetools,tgaimageconverter,tgaimporter,trade,wavaudioimporter,wglcontext,windowlesswglapplication]:x64-windows magnum-extras[core,ui]:x64-windows magnum-integration[bullet,core,glm,imgui]:x64-windows magnum-plugins[core,ddsimporter,devilimageimporter,drflacaudioimporter,freetypefont,harfbuzzfont,icoimporter,jpegimageconverter,jpegimporter,miniexrimageconverter,openddl,opengeximporter,pngimageconverter,pngimporter,stanfordimporter,stanfordsceneconverter,stbimageconverter,stbimageimporter,stlimporter]:x64-windows
Failure logs
Computing installation plan...The following packages will be built and installed:magnum[al-info,anyaudioimporter,anyimageconverter,anyimageimporter,anysceneconverter,anysceneimporter,audio,cglcontext,core,debugtools,distancefieldconverter,fontconverter,gl,gl-info,glfwapplication,imageconverter,magnumfont,magnumfontconverter,meshtools,objimporter,opengltester,primitives,scenegraph,sdl2application,shaders,text,texturetools,tgaimageconverter,tgaimporter,trade,wavaudioimporter,wglcontext,windowlesswglapplication]:x64-windowsmagnum-extras[core,ui]:x64-windowsmagnum-integration[bullet,core,glm,imgui]:x64-windowsmagnum-plugins[core,ddsimporter,devilimageimporter,drflacaudioimporter,freetypefont,harfbuzzfont,icoimporter,jpegimageconverter,jpegimporter,miniexrimageconverter,openddl,opengeximporter,pngimageconverter,pngimporter,stanfordimporter,stanfordsceneconverter,stbimageconverter,stbimageimporter,stlimporter]:x64-windowsStarting package 1/4: magnum:x64-windowsBuilding package magnum[al-info,anyaudioimporter,anyimageconverter,anyimageimporter,anysceneconverter,anysceneimporter,audio,cglcontext,core,debugtools,distancefieldconverter,fontconverter,gl,gl-info,glfwapplication,imageconverter,magnumfont,magnumfontconverter,meshtools,objimporter,opengltester,primitives,scenegraph,sdl2application,shaders,text,texturetools,tgaimageconverter,tgaimporter,trade,wavaudioimporter,wglcontext,windowlesswglapplication]:x64-windows...-- Using cached D:/vcpkg_x64/vs2019/prod/downloads/mosra-magnum-v2020.06.tar.gz-- Extracting source D:/vcpkg_x64/vs2019/prod/downloads/mosra-magnum-v2020.06.tar.gz-- Applying patch 001-tools-path.patch-- Applying patch 002-sdl-includes.patch-- Using source at D:/vcpkg_x64/vs2019/prod/buildtrees/magnum/src/v2020.06-97c0869c1f-- Configuring x64-windows-- Building x64-windows-dbg-- Building x64-windows-rel-- magnum-al-infomagnum-distancefieldconvertermagnum-fontconvertermagnum-gl-infomagnum-imageconverterCMake Error at scripts/cmake/vcpkg_copy_tools.cmake:45 (if):if given arguments:"EXISTS" "D:/vcpkg_x64/vs2019/prod/packages/magnum_x64-windows/bin/magnum-al-info" "magnum-distancefieldconverter" "magnum-fontconverter" "magnum-gl-info" "magnum-imageconverter.exe"Unknown arguments specifiedCall Stack (most recent call first):ports/magnum/portfile.cmake:105 (vcpkg_copy_tools)scripts/ports.cmake:135 (include)Error: Building package magnum:x64-windows failed with: BUILD_FAILEDPlease ensure you're using the latest portfiles with.vcpkg update, thensubmit an issue at https://github.com/Microsoft/vcpkg/issues including:Package: magnum:x64-windowsVcpkg version: 2020.06.15-nohashAdditionally, attach any relevant sections from the log files above.Additional context
Add any other context about the problem here, such as what you have already tried to resolve the issue.
cmake_parse_arguments(_vct "AUTO_CLEAN" "SEARCH_DIR" "TOOL_NAMES" ${ARGN}) tocmake_parse_arguments(PARSE_ARGV 0 _vct "AUTO_CLEAN" "SEARCH_DIR" "TOOL_NAMES")@StarGate-One, thanks for reporting this issue!
It looks regression isssues involved by PR https://github.com/microsoft/vcpkg/pull/13968 recently, cc @jgehw
Repro:
./vcpkg install magnum[al-info,distancefieldconverter,fontconverter,gl-info,imageconverter]:x64-windows
After some investigation, and found the changes in https://github.com/microsoft/vcpkg/blob/e9ff3cd5a04cd0e8122ff56e9873985ff71aa3ca/scripts/cmake/vcpkg_copy_tools.cmake#L30 cause the issue.
Currently it switch to
cmake_parse_arguments(PARSE_ARGV 0 _vct "AUTO_CLEAN" "SEARCH_DIR" "TOOL_NAMES")
The TOOL_NAMES is
magnum-al-info\;magnum-distancefieldconverter\;magnum-fontconverter\;magnum-gl-info\;magnum-imageconverter
And for previous revision:
cmake_parse_arguments(_vct "AUTO_CLEAN" "SEARCH_DIR" "TOOL_NAMES" ${ARGN})
The TOOL_NAMES is
magnum-al-info;magnum-distancefieldconverter;magnum-fontconverter;magnum-gl-info;magnum-imageconverter
This is is known CMake issue https://gitlab.kitware.com/cmake/cmake/-/issues/20317.
I think we have 2 workaounds:
@PhoebeHui thank you.
Right now I have backed out the change for now, but I believe the best fix would be to remove the "" in TOOL_NAMES list as you suggest in the second work around.
CMake has been aware of the issue for 8 months without much progress as it seems they are debating whether they should change it or not??? :
I would attempt to figure a fix, but I am not well versed/familiar in CMake to figure out a regex to remove the "" before semi-colons in the tool list?
@StarGate-One, I have summited PR https://github.com/microsoft/vcpkg/pull/14383 to remove the backslash in args.
@PhoebeHui Thank you very much.
Most helpful comment
@StarGate-One, I have summited PR https://github.com/microsoft/vcpkg/pull/14383 to remove the backslash in args.