SDL3/SDL2.spec

103 lines
2.8 KiB
RPMSpec
Raw Normal View History

2018-11-07 02:21:16 +03:00
%define oversion 0.9.0
2016-10-24 17:49:59 +10:00
2014-06-08 21:22:29 +11:00
%define api 2.0
%define major 0
2014-06-08 21:22:29 +11:00
%define libname %mklibname %{name}_ %{api} %{major}
%define devname %mklibname %{name} -d
2013-08-05 18:37:46 +04:00
Summary: Simple DirectMedia Layer
Name: SDL2
2018-11-07 02:21:16 +03:00
Version: 2.0.9
2019-07-06 19:10:29 +00:00
Release: 4
2013-08-05 18:37:46 +04:00
License: Zlib
Group: System/Libraries
Url: http://www.libsdl.org/
Source0: http://www.libsdl.org/release/%{name}-%{version}.tar.gz
2014-06-08 21:22:29 +11:00
Patch0: SDL2-2.0.3-cmake.patch
Patch1: SDL2-2.0.7-soversion.patch
2017-11-17 12:28:51 +10:00
Patch2: SDL2-2.0.7-cmake-libdir.patch
2016-10-24 17:49:59 +10:00
BuildRequires: cmake
BuildRequires: wayland-doc
2013-08-06 01:59:15 +11:00
BuildRequires: nas-devel
BuildRequires: pkgconfig(alsa)
BuildRequires: pkgconfig(dbus-1)
BuildRequires: pkgconfig(egl)
2013-08-05 18:37:46 +04:00
BuildRequires: pkgconfig(gl)
BuildRequires: pkgconfig(glu)
BuildRequires: pkgconfig(libpulse)
2013-08-06 02:24:44 +11:00
BuildRequires: pkgconfig(libusb)
2013-08-06 01:59:15 +11:00
BuildRequires: pkgconfig(udev)
BuildRequires: pkgconfig(wayland-client)
BuildRequires: pkgconfig(wayland-cursor)
BuildRequires: pkgconfig(wayland-egl)
BuildRequires: pkgconfig(wayland-protocols)
BuildRequires: pkgconfig(wayland-scanner)
2013-08-06 01:59:15 +11:00
BuildRequires: pkgconfig(xcursor)
BuildRequires: pkgconfig(xext)
BuildRequires: pkgconfig(xi)
BuildRequires: pkgconfig(xinerama)
BuildRequires: pkgconfig(xkbcommon)
2013-08-05 18:37:46 +04:00
BuildRequires: pkgconfig(xrandr)
2013-08-06 01:59:15 +11:00
BuildRequires: pkgconfig(xscrnsaver)
BuildRequires: pkgconfig(xxf86vm)
2013-08-05 18:37:46 +04:00
BuildRequires: pkgconfig(zlib)
%description
This is the Simple DirectMedia Layer, a generic API that provides low level
access to audio, keyboard, mouse, and display framebuffer across multiple
platforms.
2016-10-24 17:49:59 +10:00
#----------------------------------------------------------------------------
%package -n %{libname}
2013-08-05 18:37:46 +04:00
Summary: Main library for %{name}
Group: System/Libraries
2016-10-24 17:49:59 +10:00
%description -n %{libname}
2013-08-05 18:37:46 +04:00
This package contains the library needed to run programs dynamically
linked with %{name}.
%files -n %{libname}
%doc README.txt README-SDL.txt CREDITS.txt COPYING.txt BUGS.txt WhatsNew.txt
2016-10-24 17:49:59 +10:00
%{_libdir}/libSDL2-%{api}.so.%{major}
%{_libdir}/libSDL2-%{api}.so.%{oversion}
2013-08-05 18:37:46 +04:00
#----------------------------------------------------------------------------
2016-10-24 17:49:59 +10:00
%package -n %{devname}
2013-08-05 18:37:46 +04:00
Summary: Headers for developing programs that will use %{name}
Group: Development/C
2016-10-24 17:49:59 +10:00
Requires: %{libname} = %{EVRD}
Provides: %{name}-devel = %{EVRD}
2013-08-05 18:37:46 +04:00
2016-10-24 17:49:59 +10:00
%description -n %{devname}
2013-08-05 18:37:46 +04:00
This package contains the headers that programmers will need to develop
applications which will use %{name}.
%files -n %{devname}
%doc README.txt README-SDL.txt CREDITS.txt COPYING.txt BUGS.txt WhatsNew.txt
%{_bindir}/sdl2-config
%{_libdir}/cmake/SDL2/
2013-08-05 18:37:46 +04:00
%{_libdir}/pkgconfig/sdl2.pc
%{_libdir}/*.so
%{_libdir}/libSDL2main.a
2013-08-05 18:37:46 +04:00
%dir %{_includedir}/SDL2
%{_includedir}/SDL2/*.h
%{_datadir}/aclocal/sdl2.m4
#----------------------------------------------------------------------------
%prep
%setup -q
2013-09-12 15:44:31 +04:00
%apply_patches
2013-08-05 18:37:46 +04:00
%build
2018-11-07 02:34:46 +03:00
%global optflags %{optflags} -mstackrealign
%cmake \
-DRPATH:BOOL=OFF \
-DSDL_STATIC:BOOL=OFF
2018-11-07 02:21:16 +03:00
%make -s
2013-08-05 18:37:46 +04:00
%install
2013-09-12 15:44:31 +04:00
%makeinstall_std -C build