diff options
author | fiaxh <git@lightrise.org> | 2020-11-14 17:00:09 +0100 |
---|---|---|
committer | fiaxh <git@lightrise.org> | 2020-11-14 17:00:09 +0100 |
commit | b8d216a0575fbdc5a8eeeed07a1aeda8bd83ffea (patch) | |
tree | 7f9bc7265f1f286cb1226e8a1e2b8a2b92700cff /libdino/CMakeLists.txt | |
parent | 2a775bcfb9365058376bd45dd88f5bf164dec688 (diff) | |
download | dino-b8d216a0575fbdc5a8eeeed07a1aeda8bd83ffea.tar.gz dino-b8d216a0575fbdc5a8eeeed07a1aeda8bd83ffea.zip |
Add a WeakMap implementation + tests
Diffstat (limited to 'libdino/CMakeLists.txt')
-rw-r--r-- | libdino/CMakeLists.txt | 24 |
1 files changed, 23 insertions, 1 deletions
diff --git a/libdino/CMakeLists.txt b/libdino/CMakeLists.txt index 95b95ae2..9c2145e3 100644 --- a/libdino/CMakeLists.txt +++ b/libdino/CMakeLists.txt @@ -49,7 +49,8 @@ SOURCES src/service/stream_interactor.vala src/service/util.vala - src/util.vala + src/util/util.vala + src/util/weak_map.vala CUSTOM_VAPIS "${CMAKE_BINARY_DIR}/exports/xmpp-vala.vapi" "${CMAKE_BINARY_DIR}/exports/qlite.vapi" @@ -89,3 +90,24 @@ set_target_properties(libdino PROPERTIES PREFIX "" VERSION 0.0 SOVERSION 0) install(TARGETS libdino ${TARGET_INSTALL}) install(FILES ${CMAKE_BINARY_DIR}/exports/dino.vapi ${CMAKE_BINARY_DIR}/exports/dino.deps DESTINATION ${VAPI_INSTALL_DIR}) install(FILES ${CMAKE_BINARY_DIR}/exports/dino.h ${CMAKE_BINARY_DIR}/exports/dino_i18n.h DESTINATION ${INCLUDE_INSTALL_DIR}) + +if(BUILD_TESTS) + vala_precompile(LIBDINO_TEST_VALA_C + SOURCES + "tests/weak_map.vala" + "tests/testcase.vala" + "tests/common.vala" + CUSTOM_VAPIS + ${CMAKE_BINARY_DIR}/exports/dino_internal.vapi + ${CMAKE_BINARY_DIR}/exports/xmpp-vala.vapi + ${CMAKE_BINARY_DIR}/exports/qlite.vapi + PACKAGES + ${LIBDINO_PACKAGES} + OPTIONS + ${LIBDINO_EXTRA_OPTIONS} + ) + + add_definitions(${VALA_CFLAGS}) + add_executable(libdino-test ${LIBDINO_TEST_VALA_C}) + target_link_libraries(libdino-test libdino) +endif(BUILD_TESTS) |