diff options
| -rw-r--r-- | ports/sdl2/no-propagate-shared-link-options.patch | 13 | ||||
| -rw-r--r-- | ports/sdl2/portfile.cmake | 1 | ||||
| -rw-r--r-- | ports/sdl2/vcpkg.json | 2 |
3 files changed, 15 insertions, 1 deletions
diff --git a/ports/sdl2/no-propagate-shared-link-options.patch b/ports/sdl2/no-propagate-shared-link-options.patch new file mode 100644 index 000000000..5a26ad3c5 --- /dev/null +++ b/ports/sdl2/no-propagate-shared-link-options.patch @@ -0,0 +1,13 @@ +diff --git a/CMakeLists.txt b/CMakeLists.txt +index 7dfd35389..648218cc5 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -2062,7 +2062,7 @@ if(SDL_SHARED) + set_target_properties(SDL2 PROPERTIES STATIC_LIBRARY_FLAGS "/NODEFAULTLIB") + endif() + set(_INSTALL_LIBS "SDL2" ${_INSTALL_LIBS}) +- target_link_libraries(SDL2 ${EXTRA_LIBS} ${EXTRA_LDFLAGS}) ++ target_link_libraries(SDL2 PRIVATE ${EXTRA_LIBS} ${EXTRA_LDFLAGS}) + target_include_directories(SDL2 PUBLIC "$<BUILD_INTERFACE:${SDL2_SOURCE_DIR}/include>" $<INSTALL_INTERFACE:include> $<INSTALL_INTERFACE:include/SDL2>) + if (NOT ANDROID) + set_target_properties(SDL2 PROPERTIES DEBUG_POSTFIX "${SDL_CMAKE_DEBUG_POSTFIX}") diff --git a/ports/sdl2/portfile.cmake b/ports/sdl2/portfile.cmake index e1c027bf7..837ef4f70 100644 --- a/ports/sdl2/portfile.cmake +++ b/ports/sdl2/portfile.cmake @@ -18,6 +18,7 @@ vcpkg_extract_source_archive_ex( 0006-sdl2-Enable-creation-of-pkg-cfg-file-on-windows.patch 0007-sdl2-skip-ibus-on-linux.patch 0008-fix-macos-metal-test.patch + no-propagate-shared-link-options.patch ) string(COMPARE EQUAL "${VCPKG_LIBRARY_LINKAGE}" "static" SDL_STATIC) diff --git a/ports/sdl2/vcpkg.json b/ports/sdl2/vcpkg.json index e05f94106..5445b69d7 100644 --- a/ports/sdl2/vcpkg.json +++ b/ports/sdl2/vcpkg.json @@ -1,7 +1,7 @@ { "name": "sdl2", "version-string": "2.0.12", - "port-version": 7, + "port-version": 8, "description": "Simple DirectMedia Layer is a cross-platform development library designed to provide low level access to audio, keyboard, mouse, joystick, and graphics hardware via OpenGL and Direct3D.", "homepage": "https://www.libsdl.org/download-2.0.php", "features": { |
