Introducing a core libs wide definition (CMake configuration switch) to enable...

Introducing a core libs wide definition (CMake configuration switch) to enable static linking for all projects/libs/tests/apps
parent e007e634
......@@ -12,6 +12,10 @@ vista_use_package( IPP QUIET )
vista_use_package( PCRE QUIET )
vista_use_package( SimpleIni QUIET )
if( NOT DEFINED ITA_CORE_LIBS_BUILD_STATIC )
set( ITA_CORE_LIBS_BUILD_STATIC OFF CACHE BOOL "Build all ITA core libs in static mode" )
endif( NOT DEFINED ITA_CORE_LIBS_BUILD_STATIC )
if( NOT DEFINED ITA_BASE_WITH_FASTMATH_IPP )
set( ITA_BASE_WITH_FASTMATH_IPP OFF CACHE BOOL "Build with IPP implementation of fast math ops" )
endif( NOT DEFINED ITA_BASE_WITH_FASTMATH_IPP )
......@@ -173,13 +177,13 @@ endif( ITA_BASE_WITH_CONFIG_OLD_IMPL AND NOT ITA_BASE_WITH_CONFIG_SIMPLE_INI )
# ITA defaults to shared library build mode, so extra definition is required if you want to build against a static library
if( NOT DEFINED BUILD_SHARED_LIBS OR BUILD_SHARED_LIBS )
if( NOT ITA_CORE_LIBS_BUILD_STATIC )
add_definitions( -DITA_BASE_EXPORT )
message( "Building shared ITABase library" )
else( NOT DEFINED BUILD_SHARED_LIBS OR BUILD_SHARED_LIBS )
else( NOT ITA_CORE_LIBS_BUILD_STATIC )
add_definitions( -DITA_BASE_STATIC )
message( "Building static ITABase library" )
endif( NOT DEFINED BUILD_SHARED_LIBS OR BUILD_SHARED_LIBS )
endif( NOT ITA_CORE_LIBS_BUILD_STATIC )
# linker
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment