src/CMakeLists.txt

Wed, 28 Jun 2023 20:07:52 +0200

author
Mike Becker <universe@uap-core.de>
date
Wed, 28 Jun 2023 20:07:52 +0200
changeset 727
d92a59f5d261
parent 718
cf2f209b9da2
permissions
-rw-r--r--

improve mempool implementation

universe@375 1 set(sources
universe@483 2 utils.c
universe@391 3 allocator.c
universe@576 4 string.c
universe@503 5 list.c
universe@606 6 array_list.c
universe@398 7 linked_list.c
universe@483 8 buffer.c
universe@706 9 map.c
universe@563 10 hash_key.c
universe@549 11 hash_map.c
universe@727 12 mempool.c
universe@599 13 printf.c
universe@601 14 compare.c
universe@375 15 )
universe@377 16 set(headers
universe@549 17 cx/common.h
universe@483 18 cx/utils.h
universe@576 19 cx/string.h
universe@391 20 cx/allocator.h
universe@494 21 cx/iterator.h
universe@677 22 cx/collection.h
universe@390 23 cx/list.h
universe@606 24 cx/array_list.h
universe@398 25 cx/linked_list.h
universe@483 26 cx/buffer.h
universe@549 27 cx/map.h
universe@563 28 cx/hash_key.h
universe@549 29 cx/hash_map.h
universe@571 30 cx/mempool.h
universe@599 31 cx/printf.h
universe@601 32 cx/compare.h
universe@549 33 )
universe@375 34
universe@375 35 add_library(ucx SHARED ${sources})
universe@375 36 add_library(ucx_static STATIC ${sources})
universe@375 37
universe@375 38 target_include_directories(ucx PUBLIC ${CMAKE_CURRENT_SOURCE_DIR})
universe@375 39 target_include_directories(ucx_static PUBLIC ${CMAKE_CURRENT_SOURCE_DIR})
universe@375 40
universe@390 41 set_target_properties(ucx PROPERTIES SOVERSION 4 VERSION 4.0.0)
universe@375 42 set_target_properties(ucx_static PROPERTIES VERSION ${CMAKE_PROJECT_VERSION})
universe@377 43
universe@377 44 # it is sufficient to specify the headers for one of the targets
universe@377 45 set_target_properties(ucx PROPERTIES PUBLIC_HEADER "${headers}")
universe@377 46
universe@377 47 include(GNUInstallDirs)
universe@377 48 install(TARGETS ucx ucx_static
universe@377 49 LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}
universe@377 50 ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR}
universe@632 51 PUBLIC_HEADER DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}/cx)

mercurial