From 4a44ad9f6abd1125e207e40fe30b71ab4167f2ec Mon Sep 17 00:00:00 2001 From: FritzFlorian Date: Thu, 30 Jan 2020 14:27:04 +0100 Subject: [PATCH] WIP: temporally fix cmake issues with export tangets. Older CMAKE versions wont work with export targets in different directories. For now we simply add the context_switcher manually to the export target of pls. --- app/benchmark_fft/main.cpp | 2 +- cmake/SetupThreadSanitizer.cmake | 8 ++++---- lib/context_switcher/CMakeLists.txt | 18 +++++++++++++++++- lib/pls/CMakeLists.txt | 67 +++++++++++++++++++------------------------------------------------ 4 files changed, 41 insertions(+), 54 deletions(-) diff --git a/app/benchmark_fft/main.cpp b/app/benchmark_fft/main.cpp index d6ffd78..73c9a1f 100644 --- a/app/benchmark_fft/main.cpp +++ b/app/benchmark_fft/main.cpp @@ -37,7 +37,7 @@ void conquer(fft::complex_vector::iterator data, int n) { constexpr int MAX_NUM_THREADS = 8; constexpr int MAX_NUM_TASKS = 32; -constexpr int MAX_STACK_SIZE = 1024 * 8; +constexpr int MAX_STACK_SIZE = 1024 * 1; static_scheduler_memory,$,$>: + -Wall> + $<$: + -W4>) -# Rules for istalling the library on a system +# Rules for installing the library on a system # ...binaries -INSTALL(TARGETS pls context_switcher +INSTALL(TARGETS pls EXPORT pls-targets - LIBRARY - DESTINATION lib/pls - ARCHIVE - DESTINATION lib/pls + LIBRARY DESTINATION lib/pls + ARCHIVE DESTINATION lib/pls ) # ...all headers in `include` INSTALL( @@ -111,17 +89,10 @@ INSTALl( FILES pls-config.cmake DESTINATION lib/pls ) -# ...add a custom target that will only build the library when istalling. +# ...add a custom target that will only build the library when installing. # This can allow us to speed up the installation on embedded devices. ADD_CUSTOM_TARGET(install.pls ${CMAKE_COMMAND} -DBUILD_TYPE=${CMAKE_BUILD_TYPE} -P ${CMAKE_BINARY_DIR}/cmake_install.cmake) -ADD_DEPENDENCIES(install.pls pls) - -# Enable warnings/tidy code checking from our compiler -target_compile_options(pls PRIVATE - $<$,$,$>: - -Wall> - $<$: - -W4>) +ADD_DEPENDENCIES(install.pls context_switcher pls) -- libgit2 0.26.0