commit:     38ce6dc0c853bb9000c9c642d19bc2c21b1cfe24
Author:     Ionen Wolkens <ionen <AT> gentoo <DOT> org>
AuthorDate: Thu Oct 30 17:44:54 2025 +0000
Commit:     Ionen Wolkens <ionen <AT> gentoo <DOT> org>
CommitDate: Thu Oct 30 17:46:48 2025 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=38ce6dc0

media-libs/libsdl3: add 3.2.26

While here, add CMAKE_QA_COMPAT_SKIP=1 wrt bug #964577,
triggered by unused files for Android.

Closes: https://bugs.gentoo.org/964577
Signed-off-by: Ionen Wolkens <ionen <AT> gentoo.org>

 media-libs/libsdl3/Manifest              |   1 +
 media-libs/libsdl3/libsdl3-3.2.26.ebuild | 190 +++++++++++++++++++++++++++++++
 2 files changed, 191 insertions(+)

diff --git a/media-libs/libsdl3/Manifest b/media-libs/libsdl3/Manifest
index b46b79045e19..108dab916d41 100644
--- a/media-libs/libsdl3/Manifest
+++ b/media-libs/libsdl3/Manifest
@@ -1,3 +1,4 @@
 DIST SDL3-3.2.20.tar.gz 15895143 BLAKE2B 
343b7f7c4569607efbf1cadfcbc23f328fe78a5e9b8c07ad0010d7333f6654e2595252ab17d0dbfb5bf9b4e93914ffc1167bcb523c526d448001b700d8e7af81
 SHA512 
ce3fbf7cb04c90e1a8e7769538543b4ad98673e6a0801410c2505d686375bc33392330852db6b84d53d09535a29fea8addb2b9f3680f6887e57d99c12e61b4c8
 DIST SDL3-3.2.22.tar.gz 15895755 BLAKE2B 
10f8f09c944c6c8b8de3aa381b6f859f13bad95e92c5aa57ef5b1da503bb14e1bab155956a5342c771d4fda0edc9d320ecefd33851b0c89adb9786d17c1d1663
 SHA512 
e19f02c9b4c4f8029d9ba59c84c2cf90cacbcb4a8b79aff90316313cbfde5a54821e0e785300c04d71a498cf85e8fae9519aeb60abac4a1f78d185026cd88f66
 DIST SDL3-3.2.24.tar.gz 15896958 BLAKE2B 
89f5cdf70982e61352cdd4be3942001c3ac1eeeb1b61ebd8fa61a01e6a9f39b7ddadbe3b5d34559b067f15cb38a9921729a9e4048579ae73d0b158b78d07c705
 SHA512 
7032a6ba17d9c6c495fc948733ad2aeaf8d94b7e594746763f49676c84ca13e7b2f8d45ea068f961ca487dbca3df1968a42926410dbc3a1d381997f46277babc
+DIST SDL3-3.2.26.tar.gz 15900269 BLAKE2B 
baa846fc0662c42a4511dfb222423ea8d626075ed7be0c782767e004e8362c17f46662311f4af7c893b3e2a6ce43bdd8d796e452c448441dacecaa60bae1b2a7
 SHA512 
cdc280946657bc84772198a45512be073e65b3a1875bb688946570d77cecf9b6b468c73044b7ef3287e2cb90b31640799298b22b6ca7806edea7dbf13f31a45b

diff --git a/media-libs/libsdl3/libsdl3-3.2.26.ebuild 
b/media-libs/libsdl3/libsdl3-3.2.26.ebuild
new file mode 100644
index 000000000000..fae69f771e81
--- /dev/null
+++ b/media-libs/libsdl3/libsdl3-3.2.26.ebuild
@@ -0,0 +1,190 @@
+# Copyright 2025 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+inherit cmake-multilib dot-a
+
+DESCRIPTION="Simple Direct Media Layer"
+HOMEPAGE="https://www.libsdl.org/";
+SRC_URI="https://www.libsdl.org/release/SDL3-${PV}.tar.gz";
+S=${WORKDIR}/SDL3-${PV}
+
+LICENSE="ZLIB"
+SLOT="0"
+KEYWORDS="~amd64 ~arm ~arm64 ~hppa ~ppc ~ppc64 ~riscv ~sparc ~x86"
+
+IUSE="
+       X alsa aqua dbus doc ibus io-uring jack kms opengl oss pipewire
+       pulseaudio sndio test udev usb vulkan wayland
+       cpu_flags_ppc_altivec cpu_flags_x86_avx cpu_flags_x86_avx2
+       cpu_flags_x86_avx512f cpu_flags_x86_mmx cpu_flags_x86_sse
+       cpu_flags_x86_sse2 cpu_flags_x86_sse3 cpu_flags_x86_sse4_1
+       cpu_flags_x86_sse4_2
+"
+REQUIRED_USE="
+       ibus? ( dbus )
+       kms? ( opengl )
+       wayland? ( opengl )
+"
+RESTRICT="!test? ( test )"
+
+# dlopen/dbus-only: dbus, ibus, libudev, liburing, vulkan-loader
+RDEPEND="
+       virtual/libiconv[${MULTILIB_USEDEP}]
+       X? (
+               x11-libs/libX11[${MULTILIB_USEDEP}]
+               x11-libs/libXScrnSaver[${MULTILIB_USEDEP}]
+               x11-libs/libXcursor[${MULTILIB_USEDEP}]
+               x11-libs/libXext[${MULTILIB_USEDEP}]
+               x11-libs/libXfixes[${MULTILIB_USEDEP}]
+               x11-libs/libXi[${MULTILIB_USEDEP}]
+               x11-libs/libXrandr[${MULTILIB_USEDEP}]
+       )
+       alsa? ( media-libs/alsa-lib[${MULTILIB_USEDEP}] )
+       dbus? ( sys-apps/dbus[${MULTILIB_USEDEP}] )
+       ibus? ( app-i18n/ibus )
+       io-uring? ( sys-libs/liburing:=[${MULTILIB_USEDEP}] )
+       jack? ( virtual/jack[${MULTILIB_USEDEP}] )
+       kms? (
+               media-libs/mesa[gbm(+),${MULTILIB_USEDEP}]
+               x11-libs/libdrm[${MULTILIB_USEDEP}]
+       )
+       opengl? ( media-libs/libglvnd[X?,${MULTILIB_USEDEP}] )
+       pipewire? ( media-video/pipewire:=[${MULTILIB_USEDEP}] )
+       pulseaudio? ( media-libs/libpulse[${MULTILIB_USEDEP}] )
+       sndio? ( media-sound/sndio:=[${MULTILIB_USEDEP}] )
+       udev? ( virtual/libudev:=[${MULTILIB_USEDEP}] )
+       usb? ( virtual/libusb:1[${MULTILIB_USEDEP}] )
+       wayland? (
+               dev-libs/wayland[${MULTILIB_USEDEP}]
+               gui-libs/libdecor[${MULTILIB_USEDEP}]
+               x11-libs/libxkbcommon[${MULTILIB_USEDEP}]
+       )
+       vulkan? ( media-libs/vulkan-loader[${MULTILIB_USEDEP}] )
+"
+DEPEND="
+       ${RDEPEND}
+       X? ( x11-base/xorg-proto )
+       test? (
+               dev-util/vulkan-headers
+               media-libs/libglvnd
+       )
+       vulkan? ( dev-util/vulkan-headers )
+"
+BDEPEND="
+       doc? (
+               app-text/doxygen
+               media-gfx/graphviz
+       )
+       wayland? ( dev-util/wayland-scanner )
+"
+
+CMAKE_QA_COMPAT_SKIP=1 #964577
+
+src_prepare() {
+       cmake_src_prepare
+
+       # unbundle libglvnd and vulkan headers
+       rm -r src/video/khronos || die
+       ln -s -- "${ESYSROOT}"/usr/include src/video/khronos || die
+}
+
+src_configure() {
+       lto-guarantee-fat
+
+       local mycmakeargs=(
+               -DSDL_ASSERTIONS=disabled
+               -DSDL_DBUS=$(usex dbus)
+               -DSDL_DEPS_SHARED=no # link rather than dlopen() where possible
+               -DSDL_LIBURING=$(usex io-uring)
+               -DSDL_RPATH=no
+               -DSDL_STATIC=no
+               -DSDL_TESTS=$(usex test)
+
+               # audio
+               -DSDL_ALSA=$(usex alsa)
+               -DSDL_JACK=$(usex jack)
+               -DSDL_OSS=$(usex oss)
+               -DSDL_PIPEWIRE=$(usex pipewire)
+               -DSDL_PULSEAUDIO=$(usex pulseaudio)
+               -DSDL_SNDIO=$(usex sndio)
+
+               # input
+               -DSDL_HIDAPI_LIBUSB=$(usex usb)
+               -DSDL_IBUS=$(use ibus)
+               -DSDL_LIBUDEV=$(usex udev)
+
+               # video
+               -DSDL_COCOA=$(usex aqua)
+               -DSDL_DIRECTX=no
+               -DSDL_KMSDRM=$(usex kms)
+               -DSDL_OPENGL=$(usex opengl)
+               -DSDL_OPENGLES=$(usex opengl)
+               -DSDL_OPENVR=no # not packaged, note needs opengl REQUIRED_USE 
if added
+               -DSDL_ROCKCHIP=no
+               -DSDL_RPI=no
+               -DSDL_VIVANTE=no
+               -DSDL_VULKAN=$(usex vulkan)
+               -DSDL_WAYLAND=$(usex wayland)
+               -DSDL_X11=$(usex X)
+               # SDL disallows this by default, allow it but warn in 
pkg_postinst
+               $(use !X && use !wayland && echo -DSDL_UNIX_CONSOLE_BUILD=yes)
+
+               # cpu instruction sets
+               -DSDL_ALTIVEC=$(usex cpu_flags_ppc_altivec)
+               -DSDL_AVX=$(usex cpu_flags_x86_avx)
+               -DSDL_AVX2=$(usex cpu_flags_x86_avx2)
+               -DSDL_AVX512F=$(usex cpu_flags_x86_avx512f)
+               -DSDL_MMX=$(usex cpu_flags_x86_mmx)
+               -DSDL_SSE=$(usex cpu_flags_x86_sse)
+               -DSDL_SSE2=$(usex cpu_flags_x86_sse2)
+               -DSDL_SSE3=$(usex cpu_flags_x86_sse3)
+               -DSDL_SSE4_1=$(usex cpu_flags_x86_sse4_1)
+               -DSDL_SSE4_2=$(usex cpu_flags_x86_sse4_2)
+       )
+
+       cmake-multilib_src_configure
+}
+
+src_compile() {
+       cmake-multilib_src_compile
+
+       if use doc; then
+               cd docs && doxygen || die
+       fi
+}
+
+src_test() {
+       unset "${!SDL_@}" # ignore users' preferences for tests
+
+       cmake-multilib_src_test
+}
+
+src_install() {
+       local DOCS=( {BUGS,WhatsNew}.txt {CREDITS,README}.md docs/*.md )
+       cmake-multilib_src_install
+
+       strip-lto-bytecode
+
+       rm -r -- "${ED}"/usr/share/licenses || die
+
+       use doc && dodoc -r docs/output/html/
+}
+
+pkg_postinst() {
+       # skipping audio/video can make sense given many packages only use SDL
+       # for input, but still warn given off-by-default and may be unexpected
+       if use !X && use !aqua && use !kms && use !wayland; then
+               ewarn
+               ewarn "All typical display drivers (e.g. USE=wayland) are 
disabled,"
+               ewarn "applications using SDL for display may not function 
properly."
+       fi
+
+       if use !alsa && use !jack && use !oss && use !pipewire &&
+               use !pulseaudio && use !sndio; then
+               ewarn
+               ewarn "All typical audio drivers (e.g. USE=pipewire) are 
disabled,"
+               ewarn "applications using SDL for audio may not function 
properly."
+       fi
+}

Reply via email to