Sun, 07 Feb 2021 19:42:12 +0100
adds first draft for linked list implementation
1 set(sources
2 allocator.c
3 list.c
4 linked_list.c
5 )
6 set(headers
7 cx/allocator.h
8 cx/list.h
9 cx/linked_list.h
10 )
12 add_library(ucx SHARED ${sources})
13 add_library(ucx_static STATIC ${sources})
15 target_include_directories(ucx PUBLIC ${CMAKE_CURRENT_SOURCE_DIR})
16 target_include_directories(ucx_static PUBLIC ${CMAKE_CURRENT_SOURCE_DIR})
18 set_target_properties(ucx PROPERTIES SOVERSION 4 VERSION 4.0.0)
19 set_target_properties(ucx_static PROPERTIES VERSION ${CMAKE_PROJECT_VERSION})
21 # it is sufficient to specify the headers for one of the targets
22 set_target_properties(ucx PROPERTIES PUBLIC_HEADER "${headers}")
24 include(GNUInstallDirs)
25 install(TARGETS ucx ucx_static
26 LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}
27 ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR}
28 PUBLIC_HEADER DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}/ucx)