src/CMakeLists.txt

Mon, 30 Dec 2019 09:52:44 +0100

author
Mike Becker <universe@uap-core.de>
date
Mon, 30 Dec 2019 09:52:44 +0100
changeset 388
871a8ffe6c9d
parent 377
2099a3aff61e
child 390
d345541018fa
permissions
-rw-r--r--

merges closed feature/array branch

     1 set(sources
     2         allocator.c
     3         array.c
     4         avl.c
     5         buffer.c
     6         list.c
     7         logging.c
     8         map.c
     9         mempool.c
    10         properties.c
    11         stack.c
    12         string.c
    13         test.c
    14         ucx.c
    15         utils.c
    16 )
    17 set(headers
    18         ucx/allocator.h
    19         ucx/array.h
    20         ucx/avl.h
    21         ucx/buffer.h
    22         ucx/list.h
    23         ucx/logging.h
    24         ucx/map.h
    25         ucx/mempool.h
    26         ucx/properties.h
    27         ucx/stack.h
    28         ucx/string.h
    29         ucx/test.h
    30         ucx/ucx.h
    31         ucx/utils.h
    32 )
    34 add_library(ucx SHARED ${sources})
    35 add_library(ucx_static STATIC ${sources})
    37 target_include_directories(ucx PUBLIC ${CMAKE_CURRENT_SOURCE_DIR})
    38 target_include_directories(ucx_static PUBLIC ${CMAKE_CURRENT_SOURCE_DIR})
    40 set_target_properties(ucx PROPERTIES SOVERSION 3 VERSION 3.1.0)
    41 set_target_properties(ucx_static PROPERTIES VERSION ${CMAKE_PROJECT_VERSION})
    43 # it is sufficient to specify the headers for one of the targets
    44 set_target_properties(ucx PROPERTIES PUBLIC_HEADER "${headers}")
    46 include(GNUInstallDirs)
    47 install(TARGETS ucx ucx_static
    48         LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}
    49         ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR}
    50         PUBLIC_HEADER DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}/ucx)

mercurial