Remove PROJECTM_EXPORT from PCM class methods#949
Conversation
|
I was already working on that issue, see my early WIP branch: https://github.com/kblaschke/projectm/commits/fix-pcm-exports/ There are actually exports missing instead of being too many. These exports are required for the ENABLE_CXX_INTERFACE option, otherwise libprojectM (static or shared) won't link to apps using the C++ interface due to unresolved symbols. The actual fix requires a new export header for the C++ interface, so these export macros can be toggled separately. So there's the existing |
Added separate export header, export macros for all required classes and functions and installing the headers in the correct directory structure.
c6a8823 to
fb1505a
Compare
|
Properly fixed the whole ordeal, which was way more complex than I thought due to how Windows declares exports/imports and some other things which were wrong or missing in the CMake files. Here's what I've done:
Depending on how projectm-eval has been built, its symbols might end up being visible in |
PCM is an internal class with the C API (
projectm_pcm_*) providing the public interface. Exporting these methods caused symbols to leak into the shared library even whenENABLE_CXX_INTERFACEwas off.Verified with
nm -Dthat the C++ PCM class symbols are no longer exported while the C API functions remain available.Fixes #937