summaryrefslogtreecommitdiff
path: root/CMakeLists.txt
diff options
context:
space:
mode:
authorDirk Huss <dirk_huss@mentor.com>2015-11-25 14:38:28 +0100
committerDirk Huss <dirk_huss@mentor.com>2015-11-25 14:38:28 +0100
commitb6f81b22fcf8d9cf8ee9248408b7d2a72fbff1d9 (patch)
tree8b0b1438ccaa9450ca4b21221eb9cd74f14b10f5 /CMakeLists.txt
parent3d2fb21d0e93b6b595610285e910ac80c099a174 (diff)
downloadgenivi-common-api-runtime-b6f81b22fcf8d9cf8ee9248408b7d2a72fbff1d9.tar.gz
CommonAPI 3.1.4
Diffstat (limited to 'CMakeLists.txt')
-rw-r--r--CMakeLists.txt22
1 files changed, 15 insertions, 7 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 52eac34..7b212df 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -10,7 +10,7 @@ PROJECT(libcommonapi)
# version of CommonAPI
SET( LIBCOMMONAPI_MAJOR_VERSION 3 )
SET( LIBCOMMONAPI_MINOR_VERSION 1 )
-SET( LIBCOMMONAPI_PATCH_VERSION 3 )
+SET( LIBCOMMONAPI_PATCH_VERSION 4 )
message(STATUS "Project name: ${PROJECT_NAME}")
@@ -23,7 +23,7 @@ message(STATUS "This is CMake for Common API C++ Version ${COMPONENT_VERSION}.")
# OS
set(DL_LIBRARY "")
if (${CMAKE_SYSTEM_NAME} MATCHES "Linux")
- set(DL_LIBRARY "dl")
+ set(DL_LIBRARY "dl")
endif (${CMAKE_SYSTEM_NAME} MATCHES "Linux")
##############################################################################
@@ -79,11 +79,11 @@ message(STATUS "Build type: ${CMAKE_BUILD_TYPE}")
# CommonAPI build section
IF(MSVC)
- message("using MSVC Compiler")
- add_definitions(-DCOMMONAPI_INTERNAL_COMPILATION)
- add_compile_options(/EHsc /wd"4996")
+ message("using MSVC Compiler")
+ add_definitions(-DCOMMONAPI_INTERNAL_COMPILATION)
+ add_compile_options(/EHsc /wd"4996")
ELSE ()
- set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++0x -Wall -DCOMMONAPI_INTERNAL_COMPILATION -DUSE_CONSOLE")
+ set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++0x -Wall -Wextra -Wformat -Wformat-security -Wconversion -fexceptions -fstrict-aliasing -fstack-protector -fasynchronous-unwind-tables -fno-omit-frame-pointer -Werror -DCOMMONAPI_INTERNAL_COMPILATION -DUSE_CONSOLE")
ENDIF(MSVC)
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -DCOMMONAPI_LOGLEVEL=COMMONAPI_LOGLEVEL_${MAX_LOG_LEVEL}")
@@ -102,7 +102,7 @@ include_directories(
)
link_directories(
- ${DLT_LIBDIR}
+ ${DLT_LIBDIR}
)
file(GLOB CAPI_SRCS "src/CommonAPI/*.cpp")
@@ -226,3 +226,11 @@ else()
endif()
##############################################################################
+# create pkg-config file
+if(NOT WIN32 AND PKG_CONFIG_FOUND)
+ configure_file(CommonAPI.pc.in ${PROJECT_BINARY_DIR}/CommonAPI.pc @ONLY)
+ install(FILES ${PROJECT_BINARY_DIR}/CommonAPI.pc DESTINATION lib/pkconfig)
+endif()
+
+##############################################################################
+