]> git.ipfire.org Git - thirdparty/curl.git/commitdiff
CMake: fix build with `CURL_USE_GSSAPI`
authorJakub Zakrzewski <slither.jz@gmail.com>
Fri, 2 Dec 2022 15:22:32 +0000 (16:22 +0100)
committerDaniel Stenberg <daniel@haxx.se>
Fri, 2 Dec 2022 22:42:40 +0000 (23:42 +0100)
CMAKE_*_LINKER_FLAGS must be a string but GSS_LINKER_FLAGS is a list, so
we need to replace semicolons with spaces when setting those.

Fixes #9017
Closes #1022

CMakeLists.txt

index ce03d4bdaeb3ff02b73bd81755c5110d7d41d4de..091746b4625bdacfd2ced427fccf3f210694b4f2 100644 (file)
@@ -851,6 +851,7 @@ if(CURL_USE_GSSAPI)
     include_directories(${GSS_INCLUDE_DIR})
     link_directories(${GSS_LINK_DIRECTORIES})
     set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${GSS_COMPILER_FLAGS}")
+    string(REPLACE ";" " " GSS_LINKER_FLAGS "${GSS_LINKER_FLAGS}")
     set(CMAKE_SHARED_LINKER_FLAGS "${CMAKE_SHARED_LINKER_FLAGS} ${GSS_LINKER_FLAGS}")
     set(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} ${GSS_LINKER_FLAGS}")
     set(CMAKE_STATIC_LINKER_FLAGS "${CMAKE_STATIC_LINKER_FLAGS} ${GSS_LINKER_FLAGS}")