summaryrefslogtreecommitdiffstats
path: root/Modules/CheckLibraryExists.cmake
diff options
context:
space:
mode:
Diffstat (limited to 'Modules/CheckLibraryExists.cmake')
-rw-r--r--Modules/CheckLibraryExists.cmake3
1 files changed, 2 insertions, 1 deletions
diff --git a/Modules/CheckLibraryExists.cmake b/Modules/CheckLibraryExists.cmake
index f720e3e..e206a7c 100644
--- a/Modules/CheckLibraryExists.cmake
+++ b/Modules/CheckLibraryExists.cmake
@@ -8,7 +8,8 @@
MACRO(CHECK_LIBRARY_EXISTS LIBRARY FUNCTION LOCATION VARIABLE)
IF("${VARIABLE}" MATCHES "^${VARIABLE}$")
- SET(MACRO_CHECK_LIBRARY_EXISTS_DEFINITION -DCHECK_FUNCTION_EXISTS=${FUNCTION})
+ SET(MACRO_CHECK_LIBRARY_EXISTS_DEFINITION -DCHECK_FUNCTION_EXISTS=${FUNCTION}
+ ${CMAKE_REQUIRED_FLAGS})
MESSAGE(STATUS "Looking for ${FUNCTION} in ${LIBRARY}")
SET(CHECK_LIBRARY_EXISTS_LIBRARIES ${LIBRARY})
IF(CMAKE_REQUIRED_LIBRARIES)