summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--CMakeLists.txt16
1 files changed, 5 insertions, 11 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 168c95bf..28225ad4 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -68,6 +68,11 @@ if (UNIX)
if (SIGNAL)
add_definitions("-DHAVE_SIGNAL_H")
endif ()
+
+ find_file (EXEC_INFO execinfo.h)
+ if (EXEC_INFO)
+ set(VALAFLAGS ${VALAFLAGS} -D HAVE_EXECINFO_H)
+ endif ()
endif ()
find_library (X11 X11)
@@ -101,17 +106,6 @@ else ()
add_definitions("-DHAVE_OSX=0")
endif ()
-# Check if execinfo.h header exists
-string(FIND ${CMAKE_SYSTEM_NAME} "BSD" BEGIN)
-if (${BEGIN} GREATER 0)
- string(SUBSTRING ${CMAKE_SYSTEM_NAME} ${BEGIN} 3 BSD)
-else()
- set(BSD 0)
-endif()
-if (UNIX AND NOT BSD AND NOT DFLY)
- set(VALAFLAGS ${VALAFLAGS} -D HAVE_EXECINFO_H)
-endif ()
-
find_package(PkgConfig)
pkg_check_modules(DEPS REQUIRED
libxml-2.0>=2.6