Fix duplicated SDL symbols in plugins#112
Merged
Merged
Conversation
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #112 +/- ##
==========================================
+ Coverage 78.50% 78.51% +0.01%
==========================================
Files 605 605
Lines 60548 60548
==========================================
+ Hits 47531 47540 +9
+ Misses 13017 13008 -9 see 3 files with indirect coverage changes Continue to review full report in Codecov by Harness.
🚀 New features to boost your workflow:
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This pull request introduces a new mechanism to ensure that when SDL is statically linked into plugin bundles, its Objective-C runtime symbols are made private to avoid symbol collisions. The main changes involve generating a symbol patch header, configuring per-plugin private static SDL builds, and updating the build system to integrate these steps for all plugin formats (CLAP, VST3, AU).
SDL symbol privatization and build integration:
yup_sdl.cmake, which provides functions to generate a header file (sdl-symbols-patch.h) that renames SDL Objective-C symbols for each plugin, and to build a private static SDL library per plugin target.sdl-symbols-patch.h.in, which defines macros to rename all relevant SDL Objective-C and related symbols using a plugin-specific prefix.Build system updates for plugin targets:
yup_audio_plugin.cmaketo use the new SDL privatization mechanism for CLAP, VST3, and AU plugin targets, ensuring each gets its own patched SDL static library and header. The patch and private SDL libraries are linked into each plugin. [1] [2] [3] [4] [5] [6]yup.cmaketo include the newyup_sdl.cmakemodule.Other improvements:
-Wno-gnu-folding-constant) for the SDL2 static target on Apple platforms.sdl2::sdl2from the plugin build process, as the new mechanism handles SDL linkage.