%{?mingw_package_header}
Name: mingw-SDL
Version: 1.2.15
Release: 5%{?dist}
Summary: MinGW Windows port of SDL cross-platform multimedia library
License: LGPLv2+
Group: Development/Libraries
URL: http://www.libsdl.org/
Source0: http://www.libsdl.org/release/SDL-%{version}.tar.gz
BuildArch: noarch
BuildRequires: mingw32-filesystem >= 95
BuildRequires: mingw32-gcc
BuildRequires: mingw32-binutils
BuildRequires: mingw32-win-iconv
BuildRequires: mingw64-filesystem >= 95
BuildRequires: mingw64-gcc
BuildRequires: mingw64-binutils
BuildRequires: mingw64-win-iconv
# Not required at the moment, but SDL does contain plenty of C++ code,
# I just haven't worked out how to enable it.
#BuildRequires: mingw32-gcc-c++
%ifarch %{ix86}
BuildRequires: nasm
%endif
%description
Simple DirectMedia Layer (SDL) is a cross-platform multimedia library
designed to provide fast access to the graphics frame buffer and audio
device.
# Win32
%package -n mingw32-SDL
Summary: MinGW Windows port of SDL cross-platform multimedia library
Requires: pkgconfig
# kraxel pointed out that the headers need <iconv.h>, hence:
Requires: mingw32-win-iconv
%description -n mingw32-SDL
Simple DirectMedia Layer (SDL) is a cross-platform multimedia library
designed to provide fast access to the graphics frame buffer and audio
device.
# Win32
%package -n mingw64-SDL
Summary: MinGW Windows port of SDL cross-platform multimedia library
Requires: pkgconfig
# kraxel pointed out that the headers need <iconv.h>, hence:
Requires: mingw64-win-iconv
%description -n mingw64-SDL
Simple DirectMedia Layer (SDL) is a cross-platform multimedia library
designed to provide fast access to the graphics frame buffer and audio
device.
%?mingw_debug_package
%prep
%setup -q -n SDL-%{version}
%build
%mingw_configure
%mingw_make %{?_smp_mflags}
%install
%mingw_make DESTDIR=$RPM_BUILD_ROOT install
# Remove static libraries but DON'T remove *.dll.a files.
rm $RPM_BUILD_ROOT%{mingw32_libdir}/libSDL.a
rm $RPM_BUILD_ROOT%{mingw64_libdir}/libSDL.a
# Actually libSDLmain.a seems to be required. It just contains
# a single object file called SDL_win32_main.o.
#rm $RPM_BUILD_ROOT%{mingw32_libdir}/libSDLmain.a
#rm $RPM_BUILD_ROOT%{mingw64_libdir}/libSDLmain.a
# Delete man pages since they duplicate what is already available
# in base Fedora package.
rm $RPM_BUILD_ROOT%{mingw32_mandir}/man3/*.3*
rm $RPM_BUILD_ROOT%{mingw64_mandir}/man3/*.3*
# Drop all .la files
find $RPM_BUILD_ROOT -name "*.la" -delete
# Win32
%files -n mingw32-SDL
%doc COPYING
%{mingw32_bindir}/SDL.dll
%{mingw32_bindir}/sdl-config
%{mingw32_libdir}/libSDL.dll.a
%{mingw32_libdir}/libSDLmain.a
%{mingw32_libdir}/pkgconfig/sdl.pc
%{mingw32_datadir}/aclocal/sdl.m4
%{mingw32_includedir}/SDL
# Win64
%files -n mingw64-SDL
%doc COPYING
%{mingw64_bindir}/SDL.dll
%{mingw64_bindir}/sdl-config
%{mingw64_libdir}/libSDL.dll.a
%{mingw64_libdir}/libSDLmain.a
%{mingw64_libdir}/pkgconfig/sdl.pc
%{mingw64_datadir}/aclocal/sdl.m4
%{mingw64_includedir}/SDL
%changelog
* Sat Jun 07 2014 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.2.15-5
- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_Mass_Rebuild
* Sat Aug 03 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.2.15-4
- Rebuilt for https://fedoraproject.org/wiki/Fedora_20_Mass_Rebuild
* Thu Feb 14 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.2.15-3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild
* Fri Jul 20 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.2.15-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild
* Sun Jun 02 2012 Erik van Pienbroek <epienbro@fedoraproject.org> - 1.2.15-1
- Update to 1.2.15
- Dropped upstreamed patches
- Dropped all configure arguments which aren't relevant for the win32/win64 targets
- Add BR: nasm
* Sat Apr 14 2012 Erik van Pienbroek <epienbro@fedoraproject.org> - 1.2.13-15
- Added win64 support
- Automatically generate debuginfo package
- Use parallel make
- Dropped unneeded BR: mingw32-dlfcn
* Fri Mar 09 2012 Erik van Pienbroek <epienbro@fedoraproject.org> - 1.2.13-14
- Dropped .la files
* Wed Mar 07 2012 Kalev Lember <kalevlember@gmail.com> - 1.2.13-13
- Renamed the source package to mingw-SDL (#801028)
- Modernize the spec file
- Use mingw macros without leading underscore
* Mon Feb 27 2012 Erik van Pienbroek <epienbro@fedoraproject.org> - 1.2.13-12
- Rebuild against the mingw-w64 toolchain
- Build without directx support as it isn't ready yet for the mingw-w64 toolchain
* Fri Jan 13 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.2.13-11
- Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild
* Wed Jul 06 2011 Kalev Lember <kalevlember@gmail.com> - 1.2.13-10
- Rebuilt against win-iconv
* Tue Feb 08 2011 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.2.13-9
- Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild
* Sat Jul 25 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.2.13-8
- Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild
* Tue Apr 29 2009 Richard W.M. Jones <rjones@redhat.com> - 1.2.13-7
- Add runtime Requires mingw32-iconv (kraxel).
* Wed Feb 25 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.2.13-6
- Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild
* Fri Feb 20 2009 Richard W.M. Jones <rjones@redhat.com> - 1.2.13-5
- Rebuild for mingw32-gcc 4.4
* Tue Jan 13 2009 Richard W.M. Jones <rjones@redhat.com> - 1.2.13-4
- Verify we are still up to date with Fedora release.
- Include COPYING in documentation.
- Build with dlfcn.
- List all BRs.
- No need to package the man pages, don't duplicate what's in the
base Fedora package already.
- Requires pkgconfig.
* Fri Oct 24 2008 Richard W.M. Jones <rjones@redhat.com> - 1.2.13-2
- Initial RPM release.