diff --git a/CMakeLists.txt b/CMakeLists.txt index 3a57a62ac..724aa3680 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -77,6 +77,14 @@ endif () #----------------------------------------------------------------------------- # Add supplemental compiler warnings, and GCC visibility support. +# include export header modules so that we can easily control symbol exporting +# VTK-m is setup by default not to export symbols unless explicitly stated. +# We prefer to only export symbols of a small set of user facing classes, +# rather than exporting all symbols. In practice we will try to not export +# symbols for any third party library +set(CMAKE_CXX_VISIBILITY_PRESET hidden) +set(CMAKE_VISIBILITY_INLINES_HIDDEN 1) +include(GenerateExportHeader) include(CMake/VTKmCompilerExtras.cmake) #-----------------------------------------------------------------------------