mirror of
https://github.com/yuzu-emu/yuzu
synced 2024-11-24 13:28:25 +00:00
externals: Use SDL2 statically
Building it as a shared library causes issues distributing it to an AppImage, since linuxdeploy expects the executable to only dynamically link to system libraries. Additionally, simply dynamically linking to a library in the binary directory is bound to cause issues. Solution is to use SDL's CMake switches and build it statically. We also alias `SDL2` to `SDL2-static` on the external submodule for compatibility with the rest of the project.
This commit is contained in:
parent
751cc687bb
commit
b021e09fc0
1 changed files with 3 additions and 0 deletions
3
externals/CMakeLists.txt
vendored
3
externals/CMakeLists.txt
vendored
|
@ -47,7 +47,10 @@ target_include_directories(unicorn-headers INTERFACE ./unicorn/include)
|
|||
|
||||
# SDL2
|
||||
if (NOT SDL2_FOUND AND ENABLE_SDL2)
|
||||
set(SDL_STATIC ON)
|
||||
set(SDL_SHARED OFF)
|
||||
add_subdirectory(SDL EXCLUDE_FROM_ALL)
|
||||
add_library(SDL2 ALIAS SDL2-static)
|
||||
endif()
|
||||
|
||||
# SoundTouch
|
||||
|
|
Loading…
Reference in a new issue