Name: maniadrive Version: 1.2 Release: 27%{?dist} Summary: 3D stunt driving game Group: Amusements/Games License: GPLv2+ URL: http://maniadrive.raydium.org/ Source0: http://downloads.sourceforge.net/%{name}/ManiaDrive-%{version}-src.tar.gz Source1: %{name}.png Source2: %{name}.desktop Source3: %{name}-track-editor.desktop Patch0: %{name}-1.2-fixes.patch Patch1: %{name}-1.2-php-5.2.8-fix.patch Patch2: %{name}-1.2-fix-ode-assert.h Patch3: %{name}-1.2-fix-modifying-php-strings-inline.patch BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) BuildRequires: glew-devel ode-devel php-devel php-embedded-devel BuildRequires: libjpeg-devel libXinerama-devel BuildRequires: libvorbis-devel desktop-file-utils BuildRequires: openal-soft-devel freealut-devel >= 1.1.0-10 Requires: %{name}-data >= 1.2-5, php-soap, hicolor-icon-theme Requires: opengl-games-utils # for people who try to install this using upstream capitalization Provides: ManiaDrive = %{version}-%{release} %description ManiaDrive is an arcade car game on acrobatic tracks, with a quick and nervous gameplay (tracks almost never exceed one minute). Features: Complex car physics, Challenging "story mode", LAN and Internet mode, Live scores, Track editor, Dedicated server with HTTP interface and More than 30 blocks. %package track-editor Summary: ManiaDrive track editor Group: Amusements/Games Requires: %{name} = %{version}-%{release} %description track-editor Track editor for ManiaDrive, an arcade car game on acrobatic tracks. # upstream only does raydium svn snapshots, the closest thing to a release # schedule are the snapshots included in maniadrive, so we package the included # raydium snapshot as raydium %package -n raydium Summary: Raydium is a game engine, best known for powering ManiaDrive Group: System Environment/Libraries URL: http://raydium.org/ %description -n raydium Raydium is a game engine. It provides a set of functions which allow quick and flexible games creation. There are a lot of other 3D/game engines (and some are very complete, such as Ogre, Crystal Space, etc). Raydium does not try to be as complex as these engines, but on the contrary is aiming at quick and simple development. %package -n raydium-devel Summary: Development files for raydium Group: Development/Libraries Requires: raydium = %{version}-%{release} Requires: php-devel glew-devel freealut-devel libjpeg-devel ode-devel Requires: libvorbis-devel %description -n raydium-devel The raydium-devel package contains libraries and header files for developing applications that use raydium. %prep %setup -q -n ManiaDrive-%{version}-src %patch0 -p1 %patch1 -p1 %patch2 -p1 %patch3 -p1 rm -r rayphp/r3s rayphp/README %build # note the Makefile builds raydium, not maniadrive ! make %{?_smp_mflags} CFLAGS="$RPM_OPT_FLAGS -fPIC `php-config --includes`" \ LINKING_OPTIONS=-Wl,-soname,libraydium-%{version}.so # only one C-file and no makefile for maniadrive and the editor, so DIY gcc $RPM_OPT_FLAGS -o %{name} `php-config --includes` -DFORCE_LIBRAYDIUM \ mania_drive.c -L. -lraydium -lphp5 -lGL gcc $RPM_OPT_FLAGS -o %{name}-track-editor `php-config --includes` \ -DFORCE_LIBRAYDIUM mania2.c -L. -lraydium -lphp5 -lGL -lm %install rm -rf $RPM_BUILD_ROOT mkdir -p $RPM_BUILD_ROOT%{_bindir} mkdir -p $RPM_BUILD_ROOT%{_libdir} mkdir -p $RPM_BUILD_ROOT%{_includedir}/raydium/headers mkdir -p $RPM_BUILD_ROOT%{_datadir}/raydium install -m 755 %{name} $RPM_BUILD_ROOT%{_bindir} ln -s opengl-game-wrapper.sh $RPM_BUILD_ROOT%{_bindir}/%{name}-wrapper install -m 755 %{name}-track-editor $RPM_BUILD_ROOT%{_bindir} ln -s opengl-game-wrapper.sh \ $RPM_BUILD_ROOT%{_bindir}/%{name}-track-editor-wrapper install -m 755 libraydium.so.0.0 \ $RPM_BUILD_ROOT%{_libdir}/libraydium-%{version}.so ln -s libraydium-%{version}.so $RPM_BUILD_ROOT%{_libdir}/libraydium.so install -p -m 644 raydium/*.h $RPM_BUILD_ROOT%{_includedir}/raydium install -p -m 644 raydium/headers/*.h \ $RPM_BUILD_ROOT%{_includedir}/raydium/headers cp -a rayphp $RPM_BUILD_ROOT%{_datadir}/raydium # below is the desktop file and icon stuff. mkdir -p $RPM_BUILD_ROOT%{_datadir}/applications desktop-file-install --vendor fedora \ --dir $RPM_BUILD_ROOT%{_datadir}/applications \ %{SOURCE2} desktop-file-install --vendor fedora \ --dir $RPM_BUILD_ROOT%{_datadir}/applications \ %{SOURCE3} mkdir -p $RPM_BUILD_ROOT%{_datadir}/icons/hicolor/64x64/apps install -p -m 644 %{SOURCE1} \ $RPM_BUILD_ROOT%{_datadir}/icons/hicolor/64x64/apps %clean rm -rf $RPM_BUILD_ROOT %post touch --no-create %{_datadir}/icons/hicolor || : if [ -x %{_bindir}/gtk-update-icon-cache ]; then %{_bindir}/gtk-update-icon-cache --quiet %{_datadir}/icons/hicolor || : fi %postun touch --no-create %{_datadir}/icons/hicolor || : if [ -x %{_bindir}/gtk-update-icon-cache ]; then %{_bindir}/gtk-update-icon-cache --quiet %{_datadir}/icons/hicolor || : fi %post -n raydium -p /sbin/ldconfig %postun -n raydium -p /sbin/ldconfig %files %defattr(-,root,root,-) # no docs these are all in the -data package %{_bindir}/%{name} %{_bindir}/%{name}-wrapper %{_datadir}/applications/fedora-%{name}.desktop %{_datadir}/icons/hicolor/64x64/apps/%{name}.png %files track-editor %defattr(-,root,root,-) %{_bindir}/%{name}-track-editor* %{_datadir}/applications/fedora-%{name}-track-editor.desktop %files -n raydium %defattr(-,root,root,-) %{_libdir}/libraydium-%{version}.so %{_datadir}/raydium %files -n raydium-devel %defattr(-,root,root,-) %{_libdir}/libraydium.so %{_includedir}/raydium %changelog * Thu Mar 17 2011 Remi Collet <Fedora@famillecollet.com> 1.2-27 - Rebuild for new php 5.3.6 * Tue Jan 11 2011 Remi Collet <Fedora@famillecollet.com> 1.2-26.1 - rebuild * Tue Jan 11 2011 Hans de Goede <hdegoede@redhat.com> 1.2-26 - Fix story mode not working with php >= 5.3.5 (rhbz#668657) * Sun Jan 09 2011 Hans de Goede <hdegoede@redhat.com> 1.2-25 - Fix a crash when pressing 't', which enables the drawing of ode wire frames (rhbz#657353) * Sat Jan 08 2011 Remi Collet <Fedora@famillecollet.com> 1.2-24 - Rebuild for new php 5.3.5 * Sun Dec 12 2010 Remi Collet <Fedora@famillecollet.com> 1.2-23 - Rebuild for new php 5.3.4 * Thu Jul 22 2010 Remi Collet <Fedora@famillecollet.com> 1.2-22 - Rebuild for new php 5.3.3 * Sat Mar 6 2010 Remi Collet <Fedora@famillecollet.com> 1.2-21 - Rebuild for new php 5.3.2 * Mon Feb 22 2010 Hans de Goede <hdegoede@redhat.com> 1.2-20 - Fix FTBFS (#564773) * Fri Nov 20 2009 Remi Collet <Fedora@famillecollet.com> 1.2-19 - Rebuild for new php 5.3.1 * Sun Aug 16 2009 Hans de Goede <hdegoede@redhat.com> 1.2-18 - Switch to openal-soft * Sat Jul 25 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.2-17 - Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild * Tue Jul 14 2009 Hans de Goede <hdegoede@redhat.com> 1.2-16 - Rebuild for new php 5.3.0 * Thu Jun 25 2009 Remi Collet <Fedora@famillecollet.com> 1.2-15 - Rebuild for new php 5.2.10 * Tue Mar 3 2009 Hans de Goede <hdegoede@redhat.com> 1.2-14 - Rebuild for new php * Wed Feb 25 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.2-13 - Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild * Sun Feb 15 2009 Hans de Goede <hdegoede@redhat.com> 1.2-12 - Fix maniadrive crashing with php 5.2.8 (and later) - Fix maniadrive triggering an assert in the latest ode * Wed Dec 17 2008 Hans de Goede <hdegoede@redhat.com> 1.2-11 - Rebuild for new php version * Mon Sep 15 2008 Hans de Goede <j.w.r.degoede@hhs.nl> 1.2-10 - Rebuild for new ode * Sat Jun 21 2008 Hans de Goede <j.w.r.degoede@hhs.nl> 1.2-9 - Rebuild for new php version * Tue Feb 19 2008 Fedora Release Engineering <rel-eng@fedoraproject.org> - 1.2-8 - Autorebuild for GCC 4.3 * Tue Jan 22 2008 Hans de Goede <j.w.r.degoede@hhs.nl> 1.2-7 - Rebuild for new glew * Thu Dec 6 2007 Hans de Goede <j.w.r.degoede@hhs.nl> 1.2-6 - Rebuild for new php version * Thu Nov 22 2007 Hans de Goede <j.w.r.degoede@hhs.nl> 1.2-5 - Fix raydium subpackage description (bz 395261) * Mon Sep 24 2007 Hans de Goede <j.w.r.degoede@hhs.nl> 1.2-4 - Use opengl-games-utils wrapper to show error dialog when DRI is missing * Thu Sep 20 2007 Hans de Goede <j.w.r.degoede@hhs.nl> 1.2-3 - Rebuild for new php version * Fri Aug 31 2007 Hans de Goede <j.w.r.degoede@hhs.nl> 1.2-2 - Improved and spell-fixed raydium description - Fix a number of unused direct shlib dependencies in libraydium-1.2.so - Add Requires on various -devel packages to the raydium-devel subpackage so that all headers included by the raydium headers will be present * Fri Aug 10 2007 Hans de Goede <j.w.r.degoede@hhs.nl> 1.2-1 - Initial Fedora package