summaryrefslogtreecommitdiff
path: root/cmake/modules/FindKolabInternal.cmake
diff options
context:
space:
mode:
authorChristian Mollekopf <mollekopf@kolabsys.com>2012-04-21 15:12:07 (GMT)
committerChristian Mollekopf <mollekopf@kolabsys.com>2012-04-21 15:12:07 (GMT)
commit13f2f6138eb63401579279139e226dc3165162d4 (patch)
tree9cba6e061c3c078c66e53a8ae4610bd25e224bed /cmake/modules/FindKolabInternal.cmake
parentafb5c81d35e007c25e566bb0b8b57cc95a6cf38d (diff)
downloadlibkolabxml-13f2f6138eb63401579279139e226dc3165162d4.tar.gz
Revamp of buildsystem to use cmake config files and avoid several other quirks.
- Find files should never be installed, that is what configure files are for. - Variables which should be configurable should be added using the CACHE option, making the available in the cmake cache. They can still be overridden as ususal. - The libdir suffix can now be specified using -DLIB_INSTALL_DIR_SUFFIX=64. - The builddirectory is no longer hardcoded.
Diffstat (limited to 'cmake/modules/FindKolabInternal.cmake')
-rw-r--r--cmake/modules/FindKolabInternal.cmake58
1 files changed, 0 insertions, 58 deletions
diff --git a/cmake/modules/FindKolabInternal.cmake b/cmake/modules/FindKolabInternal.cmake
deleted file mode 100644
index b187875..0000000
--- a/cmake/modules/FindKolabInternal.cmake
+++ /dev/null
@@ -1,58 +0,0 @@
-
-# The install directory is defined by the CMAKE_INSTALL_PREFIX which defaults to /usr/local if not specified.
-# To install i.e. to /usr use "cmake -DCMAKE_INSTALL_PREFIX=/usr ."
-#
-# The library directory suffix (64/32) is detected automatically based on the available directories in CMAKE_INSTALL_PREFIX
-# The Result of this can be overridden by setting KOLAB_LIB_INSTALL_DIR "cmake -DKOLAB_LIB_INSTALL_DIR=/usr/lib64/ ."
-#
-# The runtime install is controlled by KOLAB_BIN_INSTALL_DIR
-# The header install is controlled by KOLAB_HEADER_INSTALL_DIR
-#
-# KOLAB_INSTALL_DIRECTORIES contains the determined install directories and should be used with install commands
-
-if (LIB_INSTALL_DIR)
- set(KOLAB_LIB_INSTALL_DIR ${LIB_INSTALL_DIR})
-else ()
- get_property(LIB64 GLOBAL PROPERTY FIND_LIBRARY_USE_LIB64_PATHS)
-
- if (${LIB64} STREQUAL "TRUE")
- find_path(LIB32FOUND "${CMAKE_INSTALL_PREFIX}/lib32")
- find_path(LIB64FOUND "${CMAKE_INSTALL_PREFIX}/lib64")
- if (LIB64FOUND)
- set(LIBSUFFIX 64)
- else()
- set(LIBSUFFIX "")
- endif()
- else()
- set(LIBSUFFIX "")
- endif()
-endif ()
-
-if(KOLAB_LIB_INSTALL_DIR)
- message("KOLAB_LIB_INSTALL_DIR specified manually")
-else()
- set(KOLAB_LIB_INSTALL_DIR "${CMAKE_INSTALL_PREFIX}/lib${LIBSUFFIX}")
-endif()
-message("KOLAB_LIB_INSTALL_DIR: ${KOLAB_LIB_INSTALL_DIR}")
-
-if(KOLAB_BIN_INSTALL_DIR)
- message("KOLAB_BIN_INSTALL_DIR specified manually")
-else()
- set(KOLAB_BIN_INSTALL_DIR "${CMAKE_INSTALL_PREFIX}/bin")
-endif()
-message("KOLAB_BIN_INSTALL_DIR: ${KOLAB_BIN_INSTALL_DIR}")
-
-set(KOLAB_INSTALL_DIRECTORIES RUNTIME DESTINATION "${KOLAB_BIN_INSTALL_DIR}"
- LIBRARY DESTINATION "${KOLAB_LIB_INSTALL_DIR}"
- ARCHIVE DESTINATION "${KOLAB_LIB_INSTALL_DIR}" COMPONENT Devel )
-
-
-if(KOLAB_HEADER_INSTALL_DIR)
- message("KOLAB_HEADER_INSTALL_DIR specified manually")
-else()
- set(KOLAB_HEADER_INSTALL_DIR "${CMAKE_INSTALL_PREFIX}/include/kolab")
-endif()
-message("KOLAB_HEADER_INSTALL_DIR: ${KOLAB_HEADER_INSTALL_DIR}")
-
-set(KOLAB_DATA_INSTALL_DIR "${CMAKE_INSTALL_PREFIX}/share/apps")
-set(KOLAB_CMAKE_MODULE_INSTALL_DIR ${KOLAB_DATA_INSTALL_DIR}/cmake/modules )