fix build with sdl2 2.24.1
This commit is contained in:
parent
e9a2791988
commit
8c382fdd17
@ -5,6 +5,7 @@ CATEGORIES = games x11
|
||||
GH_ACCOUNT = diasurgical
|
||||
GH_PROJECT = devilutionX
|
||||
GH_TAGNAME = 1.1.0
|
||||
REVISION = 0
|
||||
|
||||
MAINTAINER = Brian Callahan <bcallah@openbsd.org>
|
||||
|
||||
@ -26,7 +27,8 @@ LIB_DEPENDS = devel/sdl2-mixer \
|
||||
CONFIGURE_ARGS = -DBINARY_RELEASE=ON \
|
||||
-DDEBUG=OFF \
|
||||
-DDISABLE_LTO=ON \
|
||||
-DVERSION_NUM="${GH_TAGNAME}"
|
||||
-DVERSION_NUM="${GH_TAGNAME}" \
|
||||
-DSDL2_INCLUDE_DIR=${LOCALBASE}/include/SDL2
|
||||
|
||||
NO_TEST = Yes
|
||||
|
||||
|
12
games/devilutionx/patches/patch-CMakeLists_txt
Normal file
12
games/devilutionx/patches/patch-CMakeLists_txt
Normal file
@ -0,0 +1,12 @@
|
||||
EXPERIMENTAL: don't link SDL2::SDL2main (removed in SDL 2.24.0)
|
||||
Index: CMakeLists.txt
|
||||
--- CMakeLists.txt.orig
|
||||
+++ CMakeLists.txt
|
||||
@@ -479,7 +479,6 @@ foreach(target devilution ${BIN_TARGET})
|
||||
target_compile_definitions(${target} PRIVATE USE_SDL1)
|
||||
else()
|
||||
target_link_libraries(${target} PRIVATE
|
||||
- SDL2::SDL2main
|
||||
SDL2::SDL2_ttf
|
||||
SDL2::SDL2_mixer)
|
||||
endif()
|
14
games/devilutionx/patches/patch-CMake_FindSDL2_cmake
Normal file
14
games/devilutionx/patches/patch-CMake_FindSDL2_cmake
Normal file
@ -0,0 +1,14 @@
|
||||
comment out set_property to avoid error "set_property can not be used on an
|
||||
ALIAS target"
|
||||
|
||||
Index: CMake/FindSDL2.cmake
|
||||
--- CMake/FindSDL2.cmake.orig
|
||||
+++ CMake/FindSDL2.cmake
|
||||
@@ -251,5 +251,5 @@ mark_as_advanced(SDL2_LIBRARY
|
||||
SDL2_MWINDOWS_LIBRARY)
|
||||
|
||||
find_package(Threads REQUIRED)
|
||||
-set_property(TARGET SDL2::SDL2 APPEND PROPERTY
|
||||
- INTERFACE_LINK_LIBRARIES Threads::Threads)
|
||||
+#set_property(TARGET SDL2::SDL2 APPEND PROPERTY
|
||||
+# INTERFACE_LINK_LIBRARIES Threads::Threads)
|
Loading…
Reference in New Issue
Block a user