diff options
Diffstat (limited to 'CMakeLists.txt')
-rw-r--r-- | CMakeLists.txt | 13 |
1 files changed, 7 insertions, 6 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt index 5d9126af..30a7292c 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -424,9 +424,9 @@ if (HAVE_SYS_CAPABILITY_H) NAMES cap DOC "libcap library" ) -# On FreeBSD <sys/capabilities.h> is present in libc, so we don't require libcap there. - if (NOT LIBCAP_LIBRARIES AND NOT CMAKE_SYSTEM_NAME STREQUAL "FreeBSD") - message(FATAL_ERROR "Found \"sys/capability.h\" but could not find libcap") +# On FreeBSD <sys/capability.h> is a different thing + if (NOT LIBCAP_LIBRARIES OR CMAKE_SYSTEM_NAME STREQUAL "FreeBSD") + set(HAVE_SYS_CAPABILITY_H 0) endif() else() set(LIBCAP_LIBRARIES "") @@ -437,7 +437,8 @@ endif() ################################################################################ check_include_file(pty.h HAVE_PTY_H) check_include_file(util.h HAVE_UTIL_H) -if (HAVE_PTY_H OR HAVE_UTIL_H) +check_include_file(libutil.h HAVE_LIBUTIL_H) +if (HAVE_PTY_H OR HAVE_UTIL_H OR HAVE_LIBUTIL_H) check_function_exists(openpty openpty_in_libc) if (NOT openpty_in_libc) check_library_exists(util openpty "" openpty_in_libutil) @@ -447,7 +448,7 @@ if (HAVE_PTY_H OR HAVE_UTIL_H) message(FATAL_ERROR "Could not find libutil") endif (openpty_in_libutil) endif (NOT openpty_in_libc) -endif (HAVE_PTY_H OR HAVE_UTIL_H) +endif (HAVE_PTY_H OR HAVE_UTIL_H OR HAVE_LIBUTIL_H) ################################################################################ # Miscellaneous header file detection @@ -634,7 +635,7 @@ if (ENABLE_KLEE_LIBCXX) message(STATUS "Use libc++ include path: \"${KLEE_LIBCXX_INCLUDE_DIR}\"") # Find the library bitcode archive - + # Check for static first set(KLEE_LIBCXX_BC_NAME "libc++.bca") set(KLEE_LIBCXX_BC_PATH "${KLEE_LIBCXX_DIR}/lib/${KLEE_LIBCXX_BC_NAME}") |