Danny Robson
f269ef3f4f
Some libraries detect the debug mode of the stdlib and try to integrate with the system headers (eg, range-v3) which obviously doesn't work well if we're using an alternative stdlib like clang's libc++.
22 lines
876 B
CMake
22 lines
876 B
CMake
if (NOT AUTOCONF_DEFINES)
|
|
add_definitions(-DPACKAGE="${PROJECT_NAME}")
|
|
add_definitions(-DPACKAGE_VERSION="${PROJECT_VERSION}")
|
|
add_definitions(-DPACKAGE_NAME="${PROJECT_NAME}")
|
|
add_definitions(-DPACKAGE_STRING="${PROJECT_NAME} ${PROJECT_VERSION}")
|
|
|
|
set (AUTOCONF_DEFINES 1)
|
|
endif()
|
|
|
|
# Unconditionally link pthreads in. Some projects won't need it, but most
|
|
# will in some capacity if only through implied dependency (like thread pools).
|
|
set (THREADS_PREFER_PTHREAD_FLAG ON)
|
|
find_package (Threads REQUIRED)
|
|
link_libraries (Threads::Threads)
|
|
|
|
# cxx.cmake must be imported first
|
|
include ("${CMAKE_CURRENT_LIST_DIR}/nc_cxx.cmake")
|
|
include ("${CMAKE_CURRENT_LIST_DIR}/nc_sanitizer.cmake")
|
|
include ("${CMAKE_CURRENT_LIST_DIR}/nc_platform.cmake")
|
|
include ("${CMAKE_CURRENT_LIST_DIR}/nc_optimisation.cmake")
|
|
include ("${CMAKE_CURRENT_LIST_DIR}/nc_warnings.cmake")
|