-
Notifications
You must be signed in to change notification settings - Fork 3.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Support -lSDL2_mixer and others #12589
Comments
One possiblity it so have many different version of So
Then SDL2_MIXER_OGG would add Basically would move variant from the library name to the library path. |
I confirm this broke my pygame_sdl2 build. However I have troubles determining when that broke. My build worked in 2.0.2 but the related SDL2_mixer changes seem to predate. |
I believe it was when SDL_mixer to split into multiple different libraries with different names. Maybe #11577? But yes that would have been way back in 1.39.20. You say it worked for you in 2.0.2, can you check 2.0.3? |
This did not just work because we build libSDL2_mixer_ogg etc., with a suffix for the codecs we build in. This PR adds an explicit mapping to handle such cases. Also improve the test to check this, and add a lot more checks there, like that we don't use SDL1 somehow (which can happen with files like this where the SDL1 and SDL2 APIs agree, and so SDL2 does not need to be linked in to get a running executable). Fixes #12589
Background: emscripten-ports/SDL2_mixer#2
Things like
-lSDL2
work because the internal library name matches the flag. ButSDL2_mixer
has a different internal name, with_ogg
as a suffix, which prevents this.The internal name is important as we build a different SDL2_mixer depending on the codecs. But it makes simple link flags not work.
It would be good to make such link flags just work, perhaps by mapping
-l
names to the internal ones. This would require some changes inemcc.py
and related code's handling of link flag libraries, and maybe also the ports code itself liketools/ports/sdl2_mixer.py
.The text was updated successfully, but these errors were encountered: