Skip to content

Commit

Permalink
Export symbols for all compilers on Windows
Browse files Browse the repository at this point in the history
  • Loading branch information
ChrisThrasher committed Jan 20, 2023
1 parent 2d3c971 commit baab9e8
Showing 1 changed file with 4 additions and 6 deletions.
10 changes: 4 additions & 6 deletions src/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -487,12 +487,10 @@ set(CATCH_WARNING_TARGETS ${CATCH_WARNING_TARGETS} PARENT_SCOPE)
# so we want to check & warn users if they do this. However, we won't abort
# the configuration step so that we don't have to also provide an override.
if (BUILD_SHARED_LIBS)
if (MSVC)
set_target_properties(Catch2 Catch2WithMain
PROPERTIES
WINDOWS_EXPORT_ALL_SYMBOLS ON
)
endif()
set_target_properties(Catch2 Catch2WithMain
PROPERTIES
WINDOWS_EXPORT_ALL_SYMBOLS ON
)

get_target_property(_VisPreset Catch2 CXX_VISIBILITY_PRESET)
if (NOT MSVC AND _VisPreset STREQUAL "hidden")
Expand Down

0 comments on commit baab9e8

Please sign in to comment.