File: CMakeLists.txt

package info (click to toggle)
crtmpserver 1.0~dfsg-5
  • links: PTS, VCS
  • area: main
  • in suites: jessie, jessie-kfreebsd
  • size: 4,372 kB
  • ctags: 7,905
  • sloc: cpp: 56,355; sh: 411; makefile: 21
file content (33 lines) | stat: -rw-r--r-- 993 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
cmake_minimum_required(VERSION 2.6)
PROJECT(common)

#make the list with all the source files
FILE(GLOB_RECURSE SOURCES "${CRTMPSERVER_SOURCES_ROOT}/common/src/*.cpp" )

#prepare the include directories
INCLUDE_DIRECTORIES(
	${TINYXML_INCLUDE_DIRS}
	${OPENSSL_INCLUDE_PATH}
	${LUA_INCLUDE_PATH}
	${CRTMPSERVER_SOURCES_ROOT}/common/include
)

#create the library
ADD_LIBRARY(${PROJECT_NAME} ${LIB_TYPE} ${SOURCES})
ADD_PRECOMPILED_HEADER(${PROJECT_NAME} "${CRTMPSERVER_SOURCES_ROOT}/common/include/common.h")
IF(${LIB_TYPE} MATCHES "SHARED")
	TARGET_LINK_LIBRARIES(
		${PROJECT_NAME} 
		${LUA_LIBRARY_PATH} 
		${TINYXML_LIBRARIES}
		${OPENSSL_LIBRARY_PATH} 
		${CRYPTO_LIBRARY_PATH} 
		${Z_LIBRARY_PATH}
	)
	INSTALL(TARGETS ${PROJECT_NAME} LIBRARY DESTINATION ${CRTMPSERVER_ROOT})
ENDIF(${LIB_TYPE} MATCHES "SHARED")

INSTALL(DIRECTORY ${CRTMPSERVER_SOURCES_ROOT}/${PROJECT_NAME}/include/
	DESTINATION ${CMAKE_INSTALL_PREFIX}/include/crtmpserver/${PROJECT_NAME}
	FILES_MATCHING PATTERN "*.h")