2008-02-27 20:56:47 +03:00
|
|
|
include(CheckIncludeFile)
|
|
|
|
include(CheckSymbolExists)
|
|
|
|
include(CheckFunctionExists)
|
|
|
|
include(CheckLibraryExists)
|
|
|
|
include(CheckTypeSize)
|
|
|
|
include(CheckCXXSourceCompiles)
|
|
|
|
|
|
|
|
set(PACKAGE ${APPLICATION_NAME})
|
|
|
|
set(VERSION ${APPLICATION_VERSION})
|
|
|
|
set(DATADIR ${DATA_INSTALL_DIR})
|
|
|
|
set(LIBDIR ${LIB_INSTALL_DIR})
|
2009-01-08 18:03:31 +03:00
|
|
|
set(PLUGINDIR "${PLUGIN_INSTALL_DIR}-${LIBRARY_SOVERSION}")
|
2008-05-07 17:33:55 +04:00
|
|
|
set(SYSCONFDIR ${SYSCONF_INSTALL_DIR})
|
|
|
|
|
|
|
|
set(BINARYDIR ${CMAKE_BINARY_DIR})
|
|
|
|
set(SOURCEDIR ${CMAKE_SOURCE_DIR})
|
2009-09-01 14:25:10 +04:00
|
|
|
|
|
|
|
# FUNCTIONS
|
|
|
|
|
|
|
|
check_library_exists(dl dlopen "" HAVE_LIBDL)
|
|
|
|
if (HAVE_LIBDL)
|
|
|
|
find_library(DLFCN_LIBRARY dl)
|
|
|
|
set(CMAKE_REQUIRED_LIBRARIES ${CMAKE_REQUIRED_LIBRARIES} ${DLFCN_LIBRARY})
|
|
|
|
endif (HAVE_LIBDL)
|
|
|
|
|
|
|
|
check_library_exists(rt clock_gettime "" HAVE_LIBRT)
|
|
|
|
if (HAVE_LIBRT)
|
|
|
|
find_library(RT_LIBRARY rt)
|
|
|
|
set(CMAKE_REQUIRED_LIBRARIES ${CMAKE_REQUIRED_LIBRARIES} ${RT_LIBRARY})
|
|
|
|
endif (HAVE_LIBRT)
|
|
|
|
|
|
|
|
set(CSYNC_REQUIRED_LIBRARIES ${CMAKE_REQUIRED_LIBRARIES} CACHE INTERNAL "csync required system libraries")
|