2013-05-26 09:01:54 +00:00
|
|
|
#
|
|
|
|
# spec file for package SDL2
|
|
|
|
#
|
2025-01-02 10:57:06 +01:00
|
|
|
# Copyright (c) 2025 SUSE LLC
|
2013-05-26 09:01:54 +00:00
|
|
|
#
|
|
|
|
# All modifications and additions to the file contributed by third parties
|
|
|
|
# remain the property of their copyright owners, unless otherwise agreed
|
|
|
|
# upon. The license for this file, and modifications and additions to the
|
|
|
|
# file, is the same license as for the pristine package itself (unless the
|
|
|
|
# license for the pristine package is not an Open Source License, in which
|
|
|
|
# case the license is the MIT License). An "Open Source License" is a
|
|
|
|
# license that conforms to the Open Source Definition (Version 1.9)
|
|
|
|
# published by the Open Source Initiative.
|
|
|
|
|
2018-11-04 23:49:11 +00:00
|
|
|
# Please submit bugfixes or comments via https://bugs.opensuse.org/
|
2013-05-26 09:01:54 +00:00
|
|
|
#
|
|
|
|
|
|
|
|
|
2025-06-03 10:23:14 +02:00
|
|
|
Name: SDL2
|
|
|
|
Version: 2.32.8
|
2013-08-14 06:45:20 +00:00
|
|
|
Release: 0
|
|
|
|
Summary: Simple DirectMedia Layer Library
|
|
|
|
License: Zlib
|
|
|
|
Group: Development/Libraries/X11
|
2022-11-22 01:58:25 +00:00
|
|
|
URL: https://libsdl.org/
|
2021-12-17 10:46:44 +00:00
|
|
|
#Git-Clone: https://github.com/libsdl-org/SDL
|
2022-11-22 01:58:25 +00:00
|
|
|
Source: https://libsdl.org/release/%name-%version.tar.gz
|
|
|
|
Source2: https://libsdl.org/release/%name-%version.tar.gz.sig
|
2013-08-14 06:45:20 +00:00
|
|
|
Source3: %name.keyring
|
2018-01-10 23:21:40 +00:00
|
|
|
Patch1: sdl2-symvers.patch
|
2016-01-13 12:59:01 +00:00
|
|
|
BuildRequires: cmake
|
2014-07-21 20:15:42 +00:00
|
|
|
BuildRequires: gcc-c++
|
2023-01-03 22:42:54 +00:00
|
|
|
BuildRequires: libdecor-devel
|
2015-01-08 09:05:38 +00:00
|
|
|
BuildRequires: pkg-config
|
2022-11-22 01:58:25 +00:00
|
|
|
BuildRequires: pkgconfig(alsa) >= 1.0.11
|
2014-05-26 13:26:59 +00:00
|
|
|
BuildRequires: pkgconfig(dbus-1)
|
2017-10-02 10:30:55 +00:00
|
|
|
BuildRequires: pkgconfig(egl)
|
2014-07-21 20:15:42 +00:00
|
|
|
BuildRequires: pkgconfig(gl)
|
2017-10-02 10:30:55 +00:00
|
|
|
BuildRequires: pkgconfig(glesv1_cm)
|
|
|
|
BuildRequires: pkgconfig(glesv2)
|
2013-05-26 09:01:54 +00:00
|
|
|
BuildRequires: pkgconfig(glib-2.0)
|
|
|
|
BuildRequires: pkgconfig(glu)
|
2016-01-13 12:59:01 +00:00
|
|
|
BuildRequires: pkgconfig(ibus-1.0)
|
2014-05-26 07:36:24 +00:00
|
|
|
BuildRequires: pkgconfig(ice)
|
2017-10-02 10:29:44 +00:00
|
|
|
# KMS/DRM driver needs libdrm and libgbm
|
2022-11-22 01:58:25 +00:00
|
|
|
BuildRequires: pkgconfig(gbm) >= 11.1.0
|
|
|
|
BuildRequires: pkgconfig(libdrm) >= 2.4.82
|
2023-10-07 00:23:31 +00:00
|
|
|
BuildRequires: pkgconfig(libpipewire-0.3) >= 0.3.20
|
2023-10-07 00:24:10 +00:00
|
|
|
BuildRequires: pkgconfig(libpulse-simple) >= 0.9
|
2016-03-10 13:03:38 +00:00
|
|
|
BuildRequires: pkgconfig(libudev)
|
2023-01-03 22:42:54 +00:00
|
|
|
BuildRequires: pkgconfig(samplerate)
|
2016-03-10 13:40:11 +00:00
|
|
|
BuildRequires: pkgconfig(udev)
|
2022-04-25 21:59:40 +00:00
|
|
|
BuildRequires: pkgconfig(wayland-client) >= 1.18
|
2018-03-17 10:14:44 +00:00
|
|
|
BuildRequires: pkgconfig(wayland-cursor)
|
|
|
|
BuildRequires: pkgconfig(wayland-egl)
|
|
|
|
BuildRequires: pkgconfig(wayland-protocols)
|
|
|
|
BuildRequires: pkgconfig(wayland-scanner)
|
2017-10-02 10:30:55 +00:00
|
|
|
BuildRequires: pkgconfig(x11)
|
|
|
|
BuildRequires: pkgconfig(xcursor)
|
2014-07-21 20:15:42 +00:00
|
|
|
BuildRequires: pkgconfig(xext)
|
|
|
|
BuildRequires: pkgconfig(xi)
|
2017-10-02 10:30:55 +00:00
|
|
|
BuildRequires: pkgconfig(xinerama)
|
2018-03-17 10:14:44 +00:00
|
|
|
BuildRequires: pkgconfig(xkbcommon)
|
2017-10-02 10:30:55 +00:00
|
|
|
BuildRequires: pkgconfig(xrandr)
|
|
|
|
BuildRequires: pkgconfig(xscrnsaver)
|
|
|
|
BuildRequires: pkgconfig(xxf86vm)
|
2025-06-05 21:35:50 +02:00
|
|
|
%define __global_provides_exclude_from %_libdir/SDL2
|
2013-05-26 09:01:54 +00:00
|
|
|
|
|
|
|
%description
|
|
|
|
This is the "Simple DirectMedia Layer" library. It provides a generic
|
|
|
|
API for access to audio, keyboard, mouse, and display framebuffer
|
|
|
|
across multiple platforms.
|
|
|
|
|
2025-06-05 21:35:50 +02:00
|
|
|
This package is provided for corner cases when sdl2_compat is
|
|
|
|
insufficient. To use original SDL2, exercise with the
|
|
|
|
LD_LIBRARY_PATH="%_libdir/SDL2" mechanism.
|
2013-05-26 09:01:54 +00:00
|
|
|
|
2023-01-03 22:39:59 +00:00
|
|
|
SDL2 uses dlopen, so if you experience problems under X11, check
|
|
|
|
again that libXrandr2 and libXi6 are in fact installed.
|
|
|
|
|
2013-05-26 09:01:54 +00:00
|
|
|
%prep
|
2019-08-11 11:37:08 +00:00
|
|
|
%autosetup -p1
|
2022-01-16 15:56:40 +00:00
|
|
|
perl -i -pe 's{\r\n}{\n}g' *.txt README.md
|
2013-05-26 09:01:54 +00:00
|
|
|
|
|
|
|
%build
|
2022-01-11 19:48:57 +00:00
|
|
|
%global _lto_cflags %_lto_cflags -ffat-lto-objects
|
2015-01-08 13:38:01 +00:00
|
|
|
# In this instance, we do want --with-pic because of libSDL2main.a.
|
2017-10-02 19:15:42 +00:00
|
|
|
%configure --with-pic --disable-alsa-shared --disable-video-directfb \
|
2018-03-17 10:14:44 +00:00
|
|
|
--enable-video-kmsdrm --enable-video-wayland \
|
2017-10-02 19:15:42 +00:00
|
|
|
--disable-fcitx \
|
2017-10-16 18:30:42 +00:00
|
|
|
%ifarch ix86
|
|
|
|
--enable-sse2=no \
|
|
|
|
%endif
|
2023-01-03 22:39:59 +00:00
|
|
|
--enable-sse3=no --disable-rpath --disable-3dnow
|
2021-08-11 11:01:11 +00:00
|
|
|
%make_build
|
2013-05-26 09:01:54 +00:00
|
|
|
|
|
|
|
%install
|
2019-08-11 11:37:08 +00:00
|
|
|
%make_install
|
2025-06-05 21:35:50 +02:00
|
|
|
b="%buildroot"
|
|
|
|
mkdir -pv "$b/%_libdir/SDL2"
|
|
|
|
mv -v "$b/%_libdir"/libSDL2-2.0.so.* "$b/%_libdir/SDL2/"
|
|
|
|
rm -Rf "$b/%_bindir" "$b/%_datadir" "$b/%_includedir" "$b/%_libdir/pkgconfig" \
|
|
|
|
"$b/%_libdir"/lib* "$b/%_libdir/cmake"
|
2013-05-26 09:01:54 +00:00
|
|
|
|
2025-06-05 21:35:50 +02:00
|
|
|
%files
|
2021-08-11 11:01:11 +00:00
|
|
|
%license LICENSE.txt
|
2025-06-05 21:35:50 +02:00
|
|
|
%_libdir/SDL2/
|
2013-05-26 09:01:54 +00:00
|
|
|
|
|
|
|
%changelog
|