[sdl2-mixer] Fix pc file on *-windows-static (#46828)

Co-authored-by: Billy Robert O'Neal III <bion@microsoft.com>
This commit is contained in:
Pierre Wendling 2025-08-13 00:04:49 +02:00 committed by GitHub
parent 70b96c6aeb
commit b61e5146d2
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
5 changed files with 14 additions and 5 deletions

View File

@ -63,8 +63,14 @@ vcpkg_cmake_config_fixup(
)
vcpkg_fixup_pkgconfig()
set(debug_libname "SDL2_mixerd")
if(VCPKG_LIBRARY_LINKAGE STREQUAL "static" AND VCPKG_TARGET_IS_WINDOWS AND NOT VCPKG_TARGET_IS_MINGW)
vcpkg_replace_string("${CURRENT_PACKAGES_DIR}/lib/pkgconfig/SDL2_mixer.pc" "-lSDL2_mixer" "-lSDL2_mixer-static")
set(debug_libname "SDL2_mixer-staticd")
endif()
if(NOT VCPKG_BUILD_TYPE)
vcpkg_replace_string("${CURRENT_PACKAGES_DIR}/debug/lib/pkgconfig/SDL2_mixer.pc" "-lSDL2_mixer" "-lSDL2_mixerd")
vcpkg_replace_string("${CURRENT_PACKAGES_DIR}/debug/lib/pkgconfig/SDL2_mixer.pc" "-lSDL2_mixer" "-l${debug_libname}")
endif()
file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/include")

View File

@ -1,7 +1,7 @@
{
"name": "sdl2-mixer",
"version": "2.8.1",
"port-version": 1,
"port-version": 2,
"description": "Multi-channel audio mixer library for SDL.",
"homepage": "https://github.com/libsdl-org/SDL_mixer",
"license": "Zlib",

View File

@ -1896,9 +1896,7 @@ sdformat9:x64-windows-static = cascade
sdl1-mixer(android) = cascade
sdl1-net(android | osx | uwp) = cascade
sdl2-mixer[fluidsynth,libmodplug,opusfile](uwp) = cascade
sdl2-mixer[wavpack](android) = cascade
sdl2-mixer-ext[fluidsynth,libmodplug,opusfile](uwp) = cascade
sdl2-mixer-ext[wavpack](android) = cascade
sdl2-ttf[harfbuzz]:arm64-uwp = cascade
sdl2-ttf[harfbuzz]:x64-uwp = cascade
seacas:arm64-uwp = cascade

View File

@ -8666,7 +8666,7 @@
},
"sdl2-mixer": {
"baseline": "2.8.1",
"port-version": 1
"port-version": 2
},
"sdl2-mixer-ext": {
"baseline": "2.6.0",

View File

@ -1,5 +1,10 @@
{
"versions": [
{
"git-tree": "ee2053a681764a5fda41536fee42df58397d0c37",
"version": "2.8.1",
"port-version": 2
},
{
"git-tree": "0e4455e30cc3ef71f5da509ca3d6ced01f84a01e",
"version": "2.8.1",