Skip to content

Commit

Permalink
Add explicit dependency on plugin library
Browse files Browse the repository at this point in the history
Signed-off-by: Michael Carroll <[email protected]>
  • Loading branch information
mjcarroll committed Sep 14, 2023
1 parent f51c800 commit f92eae0
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions test/integration/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,9 @@ if (CMAKE_CXX_COMPILER_ID STREQUAL "MSVC")
# linking generator expressions as described here:
# https://cmake.org/cmake/help/latest/manual/cmake-generator-expressions.7.html#genex:LINK_LIBRARY
target_link_libraries(INTEGRATION_static_plugins -WHOLEARCHIVE:$<TARGET_FILE:GzDummyStaticPlugin>)
# The whole-archive invocation doesn't correctly compute dependencies,
# so explicitly require the plugin before the test can build.
add_dependencies(INTEGRATION_static_plugins GzDummyStaticPlugin)
else()
target_link_libraries(INTEGRATION_static_plugins
$<$<CXX_COMPILER_ID:GNU>:-Wl,--whole-archive>
Expand Down

0 comments on commit f92eae0

Please sign in to comment.