[CMake] CMAKE_SHARED_LIBRARY_PREFIX
Micha Renner
Micha.Renner at t-online.de
Tue Dec 28 08:28:22 EST 2010
Am Dienstag, den 28.12.2010, 07:46 -0500 schrieb David Cole:
> What's the context of your question?
>
>
> When processing a CMakeLists file, on Linux, the typical value is
> "lib".
Aha.
The following small script...
PROJECT(T)
CMAKE_MINIMUM_REQUIRED(VERSION 2.8.3)
MESSAGE(STATUS "----> CMAKE_HOST_SYSTEM " ${CMAKE_HOST_SYSTEM})
MESSAGE(STATUS "----> CMAKE_SYSTEM_NAME " ${CMAKE_SYSTEM_NAME})
MESSAGE(STATUS "----> CMAKE_HOST_SYSTEM_PROCESSOR "
${CMAKE_HOST_SYSTEM_PROCESSOR})
MESSAGE(STATUS "----> CMAKE_SYSTEM_PROCESSOR "
${CMAKE_SYSTEM_PROCESSOR})
MESSAGE(STATUS "----> CMAKE_LINK_LIBRARY_SUFFIX "
${CMAKE_LINK_LIBRARY_SUFFIX})
MESSAGE(STATUS "----> CMAKE_SHARED_LIBRARY_SUFFIX "
${CMAKE_SHARED_LIBRARY_SUFFIX})
MESSAGE(STATUS "----> CMAKE_SHARED_LIBRARY_PREFFIX "
${CMAKE_SHARED_LIBRARY_PREFFIX})
MESSAGE(STATUS "----> CMAKE_STATIC_LIBRARY_SUFFIX "
${CMAKE_STATIC_LIBRARY_SUFFIX})
MESSAGE(STATUS "----> CMAKE_STATIC_LIBRARY_PREFFIX "
${CMAKE_STATIC_LIBRARY_PREFFIX})
MESSAGE(STATUS "----> CMAKE_FIND_LIBRARY_PREFIXES "
${CMAKE_FIND_LIBRARY_PREFIXES})
MESSAGE(STATUS "----> CMAKE_FIND_LIBRARY_SUFFIXES "
${CMAKE_FIND_LIBRARY_SUFFIXES})
MESSAGE(STATUS "----> CMAKE_CURRENT_BINARY_DIR "
${CMAKE_CURRENT_BINARY_DIR})
MESSAGE(STATUS "----> CMAKE_CFG_INTDIR: " ${CMAKE_CFG_INTDIR})
MESSAGE(STATUS "----> CMAKE_BUILD_TYPE: " ${CMAKE_BUILD_TYPE})
MESSAGE(STATUS "----> CMAKE_MODULE_PATH: " ${CMAKE_MODULE_PATH})
MESSAGE(STATUS "----> CMAKE_COMMAND:" ${CMAKE_COMMAND})
# ================================================
# Test area path
# ------------------------------------------------
INCLUDE(CMakeGlobal.cmake)
INCLUDE(ProcessorCount)
ProcessorCount(num)
MESSAGE(STATUS "------> " ${num})
# ================================================
# Source - elements
# -----------------------------------------------
INCLUDE_DIRECTORIES(${CMAKE_CURRENT_BINARY_DIR})
ADD_EXECUTABLE(cTest CTest.c)
...generates this output:
-- ----> CMAKE_HOST_SYSTEM Linux-2.6.35-22-generic
-- ----> CMAKE_SYSTEM_NAME Linux
-- ----> CMAKE_HOST_SYSTEM_PROCESSOR i686
-- ----> CMAKE_SYSTEM_PROCESSOR i686
-- ----> CMAKE_LINK_LIBRARY_SUFFIX
-- ----> CMAKE_SHARED_LIBRARY_SUFFIX .so
-- ----> CMAKE_SHARED_LIBRARY_PREFFIX
-- ----> CMAKE_STATIC_LIBRARY_SUFFIX .a
-- ----> CMAKE_STATIC_LIBRARY_PREFFIX
-- ----> CMAKE_FIND_LIBRARY_PREFIXES lib
-- ----> CMAKE_FIND_LIBRARY_SUFFIXES .so.a
-- ----> CMAKE_CURRENT_BINARY_DIR /home/gildemeister/work-c/T/CMake
-- ----> CMAKE_CFG_INTDIR: .
-- ----> CMAKE_BUILD_TYPE: Debug
-- ----> CMAKE_MODULE_PATH:
-- ----> CMAKE_COMMAND:/usr/local/bin/cmake
-- CMake's build type is: Debug
-- ------> 2
-- Configuring done
-- Generating done
-- Build files have been written to: /home/gildemeister/work-c/T/CMake
As you can see CMAKE_SHARED_LIBRARY_PREFFIX is blank.
Ubuntu 9/10; CMake 2.8.3.
Greetings
Micha
More information about the CMake
mailing list