diff --git a/.github/workflows/test-linux.yml b/.github/workflows/test-linux.yml index aa24692..93604f5 100644 --- a/.github/workflows/test-linux.yml +++ b/.github/workflows/test-linux.yml @@ -6,6 +6,10 @@ on: pull_request: branches: [ main, dev ] + # Run tests once a week on Sunday. + schedule: + - cron: "0 6 * * 0" + permissions: contents: read diff --git a/.github/workflows/test-windows.yml b/.github/workflows/test-windows.yml index 84d84bb..05f89a6 100644 --- a/.github/workflows/test-windows.yml +++ b/.github/workflows/test-windows.yml @@ -6,6 +6,10 @@ on: pull_request: branches: [ main, dev ] + # Run tests once a week on Sunday. + schedule: + - cron: "0 6 * * 0" + permissions: contents: read diff --git a/cmake/modules/FindTBB.cmake b/cmake/modules/FindTBB.cmake index 6a65693..8ef97fc 100644 --- a/cmake/modules/FindTBB.cmake +++ b/cmake/modules/FindTBB.cmake @@ -283,10 +283,21 @@ if(NOT TBB_FOUND) # Create targets ################################## + # Linker scripts from TBB are not resolved correctly with older versions of + # GNU LD (before 2.35) when the 'INTERFACE_LINK_DIRECTORIES' property + # is not set. + set(TBB_LIBRARY_DIRS "") + foreach(lib ${TBB_LIBRARIES}) + get_filename_component(dir ${lib} DIRECTORY) + list(APPEND TBB_LIBRARY_DIRS ${dir}) + endforeach() + list(REMOVE_DUPLICATES TBB_LIBRARY_DIRS) + if(NOT CMAKE_VERSION VERSION_LESS 3.0 AND TBB_FOUND) add_library(TBB::tbb UNKNOWN IMPORTED) set_target_properties(TBB::tbb PROPERTIES INTERFACE_INCLUDE_DIRECTORIES ${TBB_INCLUDE_DIRS} + INTERFACE_LINK_DIRECTORIES ${TBB_LIBRARY_DIRS} IMPORTED_LOCATION ${TBB_LIBRARIES}) if(TBB_LIBRARIES_RELEASE AND TBB_LIBRARIES_DEBUG) set_target_properties(TBB::tbb PROPERTIES @@ -313,4 +324,4 @@ if(NOT TBB_FOUND) unset(TBB_LIB_PATH_SUFFIX) unset(TBB_DEFAULT_SEARCH_DIR) -endif() \ No newline at end of file +endif() diff --git a/doc/sphinx/release/release_notes.rst b/doc/sphinx/release/release_notes.rst index e2d1f53..b6c07fa 100644 --- a/doc/sphinx/release/release_notes.rst +++ b/doc/sphinx/release/release_notes.rst @@ -4,6 +4,13 @@ Release Notes ************* +.. release:: Upcoming + + .. change:: fixed + + Updated TBB CMake module finder to ensure proper resolution of linker + scripts on older versions of GNU LD (prior to 2.35). + .. release:: 0.6.0 :date: 2024-03-12