diff options
Diffstat (limited to 'muse2/synti/vam')
-rw-r--r-- | muse2/synti/vam/CMakeLists.txt | 2 | ||||
-rw-r--r-- | muse2/synti/vam/vam.cpp | 7 |
2 files changed, 7 insertions, 2 deletions
diff --git a/muse2/synti/vam/CMakeLists.txt b/muse2/synti/vam/CMakeLists.txt index b93a5c9d..d146b2f9 100644 --- a/muse2/synti/vam/CMakeLists.txt +++ b/muse2/synti/vam/CMakeLists.txt @@ -38,7 +38,7 @@ add_library ( vam SHARED # set_target_properties ( vam PROPERTIES PREFIX "" - COMPILE_FLAGS "-include ${PROJECT_BINARY_DIR}/all-pic.h" + COMPILE_FLAGS "-fvisibility=hidden -include ${PROJECT_BINARY_DIR}/all-pic.h" ) target_link_libraries(vam diff --git a/muse2/synti/vam/vam.cpp b/muse2/synti/vam/vam.cpp index 95b80c13..9d0d6e30 100644 --- a/muse2/synti/vam/vam.cpp +++ b/muse2/synti/vam/vam.cpp @@ -1044,7 +1044,12 @@ extern "C" { MESS_MAJOR_VERSION, MESS_MINOR_VERSION, instantiate, }; - + // We must compile with -fvisibility=hidden to avoid namespace + // conflicts with global variables. + // Only visible symbol is "mess_descriptor". + // (TODO: all plugins should be compiled this way) + + __attribute__ ((visibility("default"))) const MESS* mess_descriptor() { return &descriptor; } } |