diff options
Diffstat (limited to 'muse2/synti/simpledrums')
-rw-r--r-- | muse2/synti/simpledrums/CMakeLists.txt | 2 | ||||
-rw-r--r-- | muse2/synti/simpledrums/simpledrums.cpp | 6 |
2 files changed, 7 insertions, 1 deletions
diff --git a/muse2/synti/simpledrums/CMakeLists.txt b/muse2/synti/simpledrums/CMakeLists.txt index 696389c6..6b015f2b 100644 --- a/muse2/synti/simpledrums/CMakeLists.txt +++ b/muse2/synti/simpledrums/CMakeLists.txt @@ -40,7 +40,7 @@ add_library ( simpledrums SHARED # set_target_properties ( simpledrums PROPERTIES PREFIX "" - COMPILE_FLAGS "-O6 -include ${PROJECT_BINARY_DIR}/all-pic.h" + COMPILE_FLAGS "-O6 -fvisibility=hidden -include ${PROJECT_BINARY_DIR}/all-pic.h" ) target_link_libraries(simpledrums diff --git a/muse2/synti/simpledrums/simpledrums.cpp b/muse2/synti/simpledrums/simpledrums.cpp index 5a0431a0..8bca91a4 100644 --- a/muse2/synti/simpledrums/simpledrums.cpp +++ b/muse2/synti/simpledrums/simpledrums.cpp @@ -1531,6 +1531,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; } } |