Merge branch 'test1'
This commit is contained in:
commit
0eb74fc971
@ -96,31 +96,21 @@ function(common_target_properties Name)
|
|||||||
target_compile_definitions(
|
target_compile_definitions(
|
||||||
${Name}
|
${Name}
|
||||||
${__visibility}
|
${__visibility}
|
||||||
PROFILE=1)
|
PROFILE)
|
||||||
elseif(CMAKE_BUILD_TYPE STREQUAL Debug)
|
elseif(CMAKE_BUILD_TYPE STREQUAL Debug)
|
||||||
target_compile_definitions(
|
target_compile_definitions(
|
||||||
${Name}
|
${Name}
|
||||||
${__visibility}
|
${__visibility}
|
||||||
DEBUG=1)
|
DEBUG)
|
||||||
elseif(CMAKE_BUILD_TYPE STREQUAL Release)
|
elseif(CMAKE_BUILD_TYPE STREQUAL Release)
|
||||||
target_compile_definitions(
|
target_compile_definitions(
|
||||||
${Name}
|
${Name}
|
||||||
${__visibility}
|
${__visibility}
|
||||||
RELEASE=1)
|
RELEASE)
|
||||||
elseif(CMAKE_BUILD_TYPE STREQUAL None)
|
elseif(CMAKE_BUILD_TYPE STREQUAL None)
|
||||||
target_compile_definitions(
|
target_compile_definitions(
|
||||||
${Name}
|
${Name}
|
||||||
${__visibility}
|
${__visibility}
|
||||||
ANALYSIS=1)
|
ANALYSIS)
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
target_compile_definitions(
|
|
||||||
${Name}
|
|
||||||
${__visibility}
|
|
||||||
"ORGANIZATION_NAME=${CMLIB_ORGANIZATION_NAME_CANONICAL}")
|
|
||||||
target_compile_definitions(
|
|
||||||
${Name}
|
|
||||||
${__visibility}
|
|
||||||
"PROJECT_NAME=${CMLIB_PROJECT_NAME_CANONICAL}")
|
|
||||||
|
|
||||||
endfunction()
|
endfunction()
|
||||||
|
@ -3,6 +3,6 @@ function(cmlib_config_hpp_generate)
|
|||||||
cmlib_test_large_files(HAVE_LARGEFILES)
|
cmlib_test_large_files(HAVE_LARGEFILES)
|
||||||
|
|
||||||
get_property(PROJECT_VERSION_INT GLOBAL PROPERTY PROJECT_VERSION_INT)
|
get_property(PROJECT_VERSION_INT GLOBAL PROPERTY PROJECT_VERSION_INT)
|
||||||
configure_file(${CMLIB_MODULE_DIR}/hpp/cmlib_config.hpp.in
|
configure_file(${CMLIB_MODULE_DIR}/hpp/cmlib_private_config.hpp.in
|
||||||
${CMAKE_BINARY_DIR}/include/${CMLIB_PROJECT_NAME_LOWER}_cmlib_config.hpp)
|
${CMAKE_BINARY_DIR}/include/cmlib_private_config.hpp)
|
||||||
endfunction()
|
endfunction()
|
||||||
|
69
hpp/cmlib_private_config.hpp.in
Normal file
69
hpp/cmlib_private_config.hpp.in
Normal file
@ -0,0 +1,69 @@
|
|||||||
|
#ifndef @CMLIB_PROJECT_NAME_CANONICAL@_CMLIB_CONFIG_HPP_
|
||||||
|
#define @CMLIB_PROJECT_NAME_CANONICAL@_CMLIB_CONFIG_HPP_
|
||||||
|
|
||||||
|
#pragma once
|
||||||
|
|
||||||
|
#define @CMLIB_PROJECT_NAME_CANONICAL@_VERSION_STR "@PROJECT_VERSION@"
|
||||||
|
#define @CMLIB_PROJECT_NAME_CANONICAL@_VERSION_INT @PROJECT_VERSION_INT@
|
||||||
|
|
||||||
|
#if defined (CMLIB_ORGANIZATION_NAME)
|
||||||
|
#error "Duplicate definition of macros CMLIB_ORGANIZATION_NAME"
|
||||||
|
#else
|
||||||
|
#define CMLIB_ORGANIZATION_NAME "@ORGANIZATION_NAME@"
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#if defined (CMLIB_ORGANIZATION_NAME_LOWER)
|
||||||
|
#error "Duplicate definition of macros CMLIB_ORGANIZATION_NAME_LOWER"
|
||||||
|
#else
|
||||||
|
#define CMLIB_ORGANIZATION_NAME_LOWER "@ORGANIZATION_NAME_LOWER@"
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#if defined (CMLIB_ORGANIZATION_NAME_UPPER)
|
||||||
|
#error "Duplicate definition of macros CMLIB_ORGANIZATION_NAME_UPPER"
|
||||||
|
#else
|
||||||
|
#define CMLIB_ORGANIZATION_NAME_UPPER "@ORGANIZATION_NAME_UPPER@"
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#if defined (CMLIB_PROJECT_NAME)
|
||||||
|
#error "Duplicate definition of macros CMLIB_PROJECT_NAME"
|
||||||
|
#else
|
||||||
|
#define CMLIB_PROJECT_NAME "@CMAKE_PROJECT_NAME@"
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#if defined (CMLIB_PROJECT_NAME_LOWER)
|
||||||
|
#error "Duplicate definition of macros CMLIB_PROJECT_NAME_LOWER"
|
||||||
|
#else
|
||||||
|
#define CMLIB_PROJECT_NAME_LOWER "@CMAKE_PROJECT_NAME_LOWER@"
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#if defined (CMLIB_PROJECT_NAME_UPPER)
|
||||||
|
#error "Duplicate definition of macros CMLIB_PROJECT_NAME_UPPER"
|
||||||
|
#else
|
||||||
|
#define CMLIB_PROJECT_NAME_UPPER "@CMAKE_PROJECT_NAME_UPPER@"
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#if defined (CMLIB_BUILD_TYPE)
|
||||||
|
#error "Duplicate definition of macros CMLIB_BUILD_TYPE"
|
||||||
|
#else
|
||||||
|
#define CMLIB_BUILD_TYPE "@CMAKE_BUILD_TYPE@"
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#if defined (CMLIB_BUILD_DATE)
|
||||||
|
#error "Duplicate definition of macros CMLIB_BUILD_DATE"
|
||||||
|
#else
|
||||||
|
#define CMLIB_BUILD_DATE "@TODAY@"
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#cmakedefine _LARGEFILE_SOURCE
|
||||||
|
#cmakedefine _LARGE_FILES
|
||||||
|
#cmakedefine _FILE_OFFSET_BITS @_FILE_OFFSET_BITS@
|
||||||
|
#cmakedefine HAVE_FSEEKO
|
||||||
|
#cmakedefine HAVE__FSEEKI64
|
||||||
|
#cmakedefine HAVE_LARGEFILES @HAVE_LARGEFILES@
|
||||||
|
|
||||||
|
#define TARGET_LSB_ID_@LSB_DISTRIBUTOR_ID@
|
||||||
|
#define TARGET_LSB_CODENAME_@LSB_CODENAME@
|
||||||
|
#define TARGET_LSB_RELEASE "@LSB_RELEASE@"
|
||||||
|
|
||||||
|
#endif /* @CMLIB_PROJECT_NAME_CANONICAL@_CMLIB_CONFIG_HPP_ */
|
||||||
|
|
Loading…
Reference in New Issue
Block a user