cmake: fix LDFLAGS for external libs
authorMichael Wallner <mike@php.net>
Thu, 27 Feb 2020 09:34:30 +0000 (10:34 +0100)
committerMichael Wallner <mike@php.net>
Thu, 27 Feb 2020 09:34:30 +0000 (10:34 +0100)
CMake/CheckDependency.cmake

index e1bdd5b900ab7eefa08e72d3749cff07c778ee4d..3cb575354562ac81a36956531a1201a396a47786 100644 (file)
@@ -10,8 +10,8 @@ function(check_dependency NAME LIB HEADER)
             pkg_check_modules(${NAME} ${LIB}${ARGN})
         endif()
         set(${NAME} ${${NAME}_FOUND} PARENT_SCOPE)
-        set(${NAME}_LIBRARIES ${${NAME}_LIBRARIES} PARENT_SCOPE)
-        set(${NAME}_INCLUDEDIR ${${NAME}_INCLUDEDIR}} PARENT_SCOPE)
+               set(${NAME}_LIBRARIES ${${NAME}_LDFLAGS} PARENT_SCOPE)
+        set(${NAME}_INCLUDEDIR ${${NAME}_INCLUDEDIR} PARENT_SCOPE)
 
         safe_string(${LIB} LIB_CONST)
         set(HAVE_${NAME} ${${NAME}_FOUND} PARENT_SCOPE)