File: CMakeLists.txt

package info (click to toggle)
glyr 1.0.6+git20140423-1
  • links: PTS, VCS
  • area: main
  • in suites: jessie, jessie-kfreebsd
  • size: 1,724 kB
  • ctags: 1,275
  • sloc: ansic: 13,062; python: 1,052; ruby: 75; makefile: 15
file content (33 lines) | stat: -rw-r--r-- 1,238 bytes parent folder | download
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
# Configuration for Version / versionname
configure_file (
  "config.h.in"
  "config.h"
)

SET(GENERIC_LIB_VERSION ${GLYR_VERSION_MAJOR}.${GLYR_VERSION_MINOR})
SET(GLYR_API_SOVERSION 1)

# Link libglyr as shared library
ADD_LIBRARY(glyr SHARED	${LIB_SOURCE_LOCATIONS})

# Win32 needs that socket library for libcurl
IF(WIN32)
  TARGET_LINK_LIBRARIES(glyr ${CURL_LIBRARY} ${GLIBPKG_LIBRARIES} ${SQLITE3_LIBRARIES} ws2_32) 
  SET_TARGET_PROPERTIES(glyr PROPERTIES
    OUTPUT_NAME "glyr-${GLYR_API_SOVERSION}"
    VERSION ${GENERIC_LIB_VERSION} )
ELSE(WIN32) 
  TARGET_LINK_LIBRARIES(glyr ${CURL_LIBRARY} ${GLIBPKG_LIBRARIES} ${SQLITE3_LIBRARIES} ) 
  SET_TARGET_PROPERTIES(glyr PROPERTIES
    VERSION ${GLYR_API_SOVERSION}.${GENERIC_LIB_VERSION}
    SOVERSION ${GLYR_API_SOVERSION})
ENDIF(WIN32)

# Install Files
INSTALL(FILES glyr.h    DESTINATION ${INSTALL_INC_DIR}/glyr)
INSTALL(FILES types.h   DESTINATION ${INSTALL_INC_DIR}/glyr)
INSTALL(FILES misc.h    DESTINATION ${INSTALL_INC_DIR}/glyr)
INSTALL(FILES cache.h   DESTINATION ${INSTALL_INC_DIR}/glyr)
INSTALL(FILES config.h  DESTINATION ${INSTALL_INC_DIR}/glyr)
INSTALL(FILES testing.h DESTINATION ${INSTALL_INC_DIR}/glyr)
INSTALL(TARGETS glyr LIBRARY DESTINATION ${INSTALL_LIB_DIR})