summaryrefslogtreecommitdiff
path: root/CMake
diff options
context:
space:
mode:
authorMarc Aldorasi <marc@groundctl.com>2023-01-09 16:38:28 -0500
committerJay Satiro <raysatiro@yahoo.com>2023-01-24 03:09:09 -0500
commit71cc27f0d6de7abf0f4e41b8d1ea74e60b6fce7c (patch)
tree8d76228f9ff91f6453d3d25cd23318653c313e65 /CMake
parent3eabedc027e887600eb1612fb70c99e7e83918e7 (diff)
downloadcurl-71cc27f0d6de7abf0f4e41b8d1ea74e60b6fce7c.tar.gz
cmake: use list APPEND syntax for CMAKE_REQUIRED_DEFINITIONS
- Use list() instead of set() for CMAKE_REQUIRED_DEFINITIONS list since the former is clearer. Closes https://github.com/curl/curl/pull/10272
Diffstat (limited to 'CMake')
-rw-r--r--CMake/FindGSS.cmake4
1 files changed, 2 insertions, 2 deletions
diff --git a/CMake/FindGSS.cmake b/CMake/FindGSS.cmake
index 28b4de796..b244e610e 100644
--- a/CMake/FindGSS.cmake
+++ b/CMake/FindGSS.cmake
@@ -181,14 +181,14 @@ if(NOT _GSS_FOUND) #not found by pkg-config. Let's take more traditional approac
set(GSS_FLAVOUR "MIT")
else()
# prevent compiling the header - just check if we can include it
- set(CMAKE_REQUIRED_DEFINITIONS "${CMAKE_REQUIRED_DEFINITIONS} -D__ROKEN_H__")
+ list(APPEND CMAKE_REQUIRED_DEFINITIONS -D__ROKEN_H__)
check_include_file( "roken.h" _GSS_HAVE_ROKEN_H)
check_include_file( "heimdal/roken.h" _GSS_HAVE_HEIMDAL_ROKEN_H)
if(_GSS_HAVE_ROKEN_H OR _GSS_HAVE_HEIMDAL_ROKEN_H)
set(GSS_FLAVOUR "Heimdal")
endif()
- set(CMAKE_REQUIRED_DEFINITIONS "")
+ list(REMOVE_ITEM CMAKE_REQUIRED_DEFINITIONS -D__ROKEN_H__)
endif()
else()
# I'm not convinced if this is the right way but this is what autotools do at the moment