File: CMakeLists.txt

package info (click to toggle)
libatomic-queue 1.7.2-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 13,356 kB
  • sloc: cpp: 1,704; javascript: 315; makefile: 127; ansic: 91; python: 82; sh: 76
file content (25 lines) | stat: -rw-r--r-- 729 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
CMAKE_MINIMUM_REQUIRED( VERSION 3.25 )

include(GNUInstallDirs)

add_library(atomic_queue INTERFACE)
target_include_directories(atomic_queue INTERFACE
    "$<BUILD_INTERFACE:${CMAKE_CURRENT_LIST_DIR}>"
    "$<INSTALL_INTERFACE:${CMAKE_INSTALL_INCLUDEDIR}>"
)

add_library(atomic_queue::atomic_queue ALIAS atomic_queue)

if ( ATOMIC_QUEUE_ENABLE_INSTALL )
    install(TARGETS atomic_queue EXPORT atomic_queue)
    install(
        DIRECTORY "${CMAKE_CURRENT_LIST_DIR}/atomic_queue"
        DESTINATION "${CMAKE_INSTALL_INCLUDEDIR}"
    )
    install(
        EXPORT atomic_queue
        FILE atomic_queue-config.cmake
        DESTINATION "${CMAKE_INSTALL_DATAROOTDIR}/atomic_queue"
        NAMESPACE atomic_queue::
    )
endif ()