Skip to content

Commit 5807720

Browse files
hjagasiaAMDronlieb
authored andcommitted
[PATCH] offload-tunnel-cmake with proper escape (llvm#161552)
Co-authored-by: ronlieb <[email protected]>
1 parent 66e39ae commit 5807720

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

llvm/runtimes/CMakeLists.txt

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -507,10 +507,14 @@ if(build_runtimes)
507507
endif()
508508

509509
# Forward user-provived system configuration to runtimes for requirement introspection.
510-
# CMAKE_PREFIX_PATH is the search path for CMake packages.
510+
# CMAKE_PREFIX_PATH is the search path for CMake packages. In order to pass through
511+
# the command line interface, the CMake semicolon separator needs to be replaced
512+
# with $<SEMICOLON>
511513
if(CMAKE_PREFIX_PATH)
512-
list(APPEND extra_cmake_args "-DCMAKE_PREFIX_PATH=${CMAKE_PREFIX_PATH}")
514+
string(JOIN "$<SEMICOLON>" escaped_cmake_prefix_path ${CMAKE_PREFIX_PATH})
515+
list(APPEND extra_cmake_args "-DCMAKE_PREFIX_PATH=${escaped_cmake_prefix_path}")
513516
endif()
517+
514518
# CMAKE_PROGRAM_PATH is the search path for executables such as python.
515519
if(CMAKE_PROGRAM_PATH)
516520
list(APPEND extra_cmake_args "-DCMAKE_PROGRAM_PATH=${CMAKE_PROGRAM_PATH}")

0 commit comments

Comments
 (0)