mirror of
https://github.com/microsoft/vcpkg.git
synced 2024-12-27 10:21:07 +08:00
[sdl2] Don't propagate shared link options (#14992)
This commit is contained in:
parent
c3e6d937e6
commit
1fca0cb761
13
ports/sdl2/no-propagate-shared-link-options.patch
Normal file
13
ports/sdl2/no-propagate-shared-link-options.patch
Normal file
@ -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}")
|
@ -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)
|
||||
|
@ -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": {
|
||||
|
Loading…
x
Reference in New Issue
Block a user