diff options
author | jan Iversen <jan@casacondor.com> | 2019-12-25 16:00:54 +0100 |
---|---|---|
committer | Dirk Hohndel <dirk@hohndel.org> | 2019-12-27 05:40:26 +0900 |
commit | 9d34ab4bc43dbb59822a7fd5a47a1a2f00ad3c0a (patch) | |
tree | df7b72001a68dca3c51d201c6f4ceae79b4344bb /tests | |
parent | 1fc54e907f0e273dc3d63f96a2f48e67eb165926 (diff) | |
download | subsurface-9d34ab4bc43dbb59822a7fd5a47a1a2f00ad3c0a.tar.gz |
buildsystem: update tests to include more libraries
In order to test plannerShared (backend-shared) more
libraries are needed.
Signed-off-by: Jan Iversen <jan@casacondor.com>
Diffstat (limited to 'tests')
-rw-r--r-- | tests/CMakeLists.txt | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/tests/CMakeLists.txt b/tests/CMakeLists.txt index 51abb12ce..c5c611095 100644 --- a/tests/CMakeLists.txt +++ b/tests/CMakeLists.txt @@ -39,12 +39,23 @@ if(CMAKE_SYSTEM_NAME STREQUAL "Windows") endif() endif() +# define libraries to use, due to the fact that some library names are different between mobile and desktop +# extra settings are needed +# even though the targets are test executable the overall target is the same +if (SUBSURFACE_TARGET_EXECUTABLE MATCHES "DesktopExecutable") + set(TEST_SPECIFIC_LIBRARIES subsurface_models_desktop) +else() + set(TEST_SPECIFIC_LIBRARIES subsurface_models_mobile ) +endif() + # Helper function TEST used to created rules to build, link, install and run tests function(TEST NAME FILE) get_filename_component(HDR "${FILE}" NAME_WE) add_executable(${NAME} ${FILE} ${HDR}.h) target_link_libraries( ${NAME} + subsurface_backend_shared + ${TEST_SPECIFIC_LIBRARIES} subsurface_corelib RESOURCE_LIBRARY ${QT_TEST_LIBRARIES} |