From 2a8198f4d68690f5bb3dac8a4cb32029fc8c3a5b Mon Sep 17 00:00:00 2001 From: Davide Beatrici Date: Thu, 28 Nov 2024 15:52:08 +0100 Subject: [PATCH] FIX(cmake): Don't set WORKING_DIRECTORY for ExternalProject_Add() This is a workaround for a bug that appeared in a recent version of CMake. WORKING_DIRECTORY prepends the specified path to a list instead of using it directly, resulting in: cd /D D:\a\1\b\overlay\overlay_xcompile-prefix;D:\a\1\b\overlay\overlay_xcompile-prefix\src\overlay_xcompile-build For reference, this causes the build to fail on Windows with the following error: "The filename, directory name, or volume label syntax is incorrect." This commit simply removes the parameter from the ExternalProject_Add() call, since the default working directory is perfectly fine. --- overlay/CMakeLists.txt | 2 -- 1 file changed, 2 deletions(-) diff --git a/overlay/CMakeLists.txt b/overlay/CMakeLists.txt index cd4aa1f40d5..ecc5a4da2d8 100644 --- a/overlay/CMakeLists.txt +++ b/overlay/CMakeLists.txt @@ -172,7 +172,6 @@ if(64_BIT AND MSVC) "-Dversion=${PROJECT_VERSION}" ${CMAKE_SOURCE_DIR}/overlay CMAKE_GENERATOR_PLATFORM "Win32" - WORKING_DIRECTORY ${CMAKE_BINARY_DIR}/overlay/overlay_xcompile-prefix INSTALL_COMMAND "" ) else() @@ -194,7 +193,6 @@ if(64_BIT AND MSVC) "-Dsymbols=${symbols}" "-Dversion=${PROJECT_VERSION}" ${CMAKE_SOURCE_DIR}/overlay - WORKING_DIRECTORY ${CMAKE_BINARY_DIR}/overlay/overlay_xcompile-prefix INSTALL_COMMAND "" ) endif()