File: CMakeLists.txt

package info (click to toggle)
nss-wrapper 1.1.3-1
  • links: PTS, VCS
  • area: main
  • in suites: bullseye, buster, sid, stretch
  • size: 616 kB
  • ctags: 915
  • sloc: ansic: 6,637; perl: 372; makefile: 49; sh: 12
file content (30 lines) | stat: -rw-r--r-- 694 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
project(libnss_wrapper C)

include_directories(${CMAKE_BINARY_DIR})
add_library(nss_wrapper SHARED nss_wrapper.c)
target_link_libraries(nss_wrapper ${NWRAP_REQUIRED_LIBRARIES} ${CMAKE_THREAD_LIBS_INIT})

if (BSD)
    add_definitions(-DBSD)
endif (BSD)

set_target_properties(
  nss_wrapper
    PROPERTIES
      NO_SONAME ON
)

install(
  TARGETS
    nss_wrapper
  RUNTIME DESTINATION ${BIN_INSTALL_DIR}
  LIBRARY DESTINATION ${LIB_INSTALL_DIR}
  ARCHIVE DESTINATION ${LIB_INSTALL_DIR}
)

# This needs to be at the end
if (POLICY CMP0026)
    cmake_policy(SET CMP0026 OLD)
endif()
get_target_property(NWRAP_LOCATION nss_wrapper LOCATION)
set(NSS_WRAPPER_LOCATION ${NWRAP_LOCATION} PARENT_SCOPE)