Update TODO
[pingcheck] / CMakeLists.txt
CommitLineData
0dc2435f
GMF
1# IMPORTANT: Do not add whitespaces between cmake commands! This will break
2# the package build!
3# Do set(CONTENTS) instead of set( CONTENTS ) or set (CONTENTS)
4c2fe1f1 4
0dc2435f
GMF
5# cmake: required version
6cmake_minimum_required (VERSION 2.6)
4ea9706c 7
0dc2435f
GMF
8# cmake: set the directory where the executable will be placed
9set(CMAKE_RUNTIME_OUTPUT_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR})
235ffac2 10
0dc2435f
GMF
11# cmake: set the directory where the make install places the executable
12set(CMAKE_INSTALL_PREFIX ${CMAKE_CURRENT_BINARY_DIR})
4ea9706c 13
0dc2435f
GMF
14# project: definitions
15project(libpingcheck)
16set(VERSION 0.1)
17set(TARGET ${PROJECT_NAME})
4ea9706c 18
0dc2435f
GMF
19# compiler: disable the full compiler output
20set(CMAKE_VERBOSE_MAKEFILE OFF)
4c2fe1f1 21
0dc2435f
GMF
22# compiler: build type
23set(CMAKE_BUILD_TYPE Debug)
24
25# compiler: add definitions and arguments to the compiler
2d591235 26add_definitions(
451c9121 27 -Wall -Wextra -Weffc++ -Wshadow -Wcast-qual -Wconversion -pedantic
ba427d60 28 #-Werror
6e09425c 29 #-O2
451c9121 30 -DVERSION_STRING=${VERSION}
c3535345 31 -DPROJECT_NAME=\"${PROJECT_NAME}\"
2d591235 32)
4c2fe1f1 33
0dc2435f
GMF
34# package: package information
35set(CPACK_PACKAGE_VERSION ${VERSION})
36set(CPACK_PACKAGE_CONTACT "Intra2net AG")
37set(CPACK_PACKAGE_DESCRIPTION ${TARGET})
38set(CPACK_PACKAGE_DESCRIPTION_SUMMARY "Pingcheck")
39set(CPACK_SOURCE_GENERATOR TGZ)
40set(CPACK_SOURCE_IGNORE_FILES "\\\\.git;build;build-rpm")
41set(CPACK_SOURCE_PACKAGE_FILE_NAME "${TARGET}-${VERSION}")
235ffac2
GMF
42
43# build the application in the source directory
0dc2435f
GMF
44add_subdirectory(src)
45
46# package: ???
47include(CPack)