diff --git a/README.md b/README.md index d67cef6..c1726b9 100644 --- a/README.md +++ b/README.md @@ -1,2 +1,4 @@ # xmoto +xmoto is a nice 2D motocross game, where phisics rules are very strong + diff --git a/xmoto-0.5.10-gcc-4.8.patch b/xmoto-0.5.10-gcc-4.8.patch new file mode 100644 index 0000000..e95613e --- /dev/null +++ b/xmoto-0.5.10-gcc-4.8.patch @@ -0,0 +1,11 @@ +--- src/helpers/System.cpp.orig 2011-10-12 00:18:14.000000000 +0400 ++++ src/helpers/System.cpp 2013-09-13 22:36:38.029229232 +0400 +@@ -25,6 +25,8 @@ + #include "VExcept.h" + #include + ++#include // for getpid() ++ + std::vector* System::getDisplayModes(int windowed) { + std::vector* modes = new std::vector; + SDL_Rect **sdl_modes; diff --git a/xmoto-0.5.3-libpng14.patch b/xmoto-0.5.3-libpng14.patch new file mode 100644 index 0000000..0e69cf2 --- /dev/null +++ b/xmoto-0.5.3-libpng14.patch @@ -0,0 +1,12 @@ +diff -Nru xmoto-0.5.3.orig//src/image/tim_png.cpp xmoto-0.5.3/src/image/tim_png.cpp +--- xmoto-0.5.3.orig//src/image/tim_png.cpp 2007-12-03 11:33:24.000000000 +0100 ++++ xmoto-0.5.3/src/image/tim_png.cpp 2010-10-25 03:08:58.857513109 +0200 +@@ -166,7 +166,7 @@ + png_set_palette_to_rgb(PngPtr); + + if(nColorType==PNG_COLOR_TYPE_GRAY && nBitDepth<8) +- png_set_gray_1_2_4_to_8(PngPtr); ++ png_set_expand_gray_1_2_4_to_8(PngPtr); + + if(png_get_valid(PngPtr,InfoPtr,PNG_INFO_tRNS)) + png_set_tRNS_to_alpha(PngPtr); diff --git a/xmoto-icon.png b/xmoto-icon.png new file mode 100644 index 0000000..11fe242 Binary files /dev/null and b/xmoto-icon.png differ diff --git a/xmoto.desktop b/xmoto.desktop new file mode 100644 index 0000000..1a96e38 --- /dev/null +++ b/xmoto.desktop @@ -0,0 +1,10 @@ +[Desktop Entry] +Encoding=UTF-8 +Categories=Application;Game;ArcadeGame +Name=xmoto +GenericName=2D motocross race game +GenericName[it]=Gioco 2D di corse di motocross +Exec=/usr/bin/xmoto +Terminal=0 +Type=Application +Icon=/usr/share/pixmaps/xmoto.png diff --git a/xmoto.spec b/xmoto.spec new file mode 100644 index 0000000..9f1cbe5 --- /dev/null +++ b/xmoto.spec @@ -0,0 +1,99 @@ +Name: xmoto +Version: 0.5.10 +Release: 1mamba +Summary: A nice 2D motocross game +Group: Graphical Desktop/Applications/Games +Vendor: openmamba +Distribution: openmamba +Packager: Ercole 'ercolinux' Carpanetto +URL: http://xmoto.tuxfamily.org/index.php?page=news +Source: http://download.tuxfamily.org/xmoto/xmoto/%{version}/xmoto-%{version}-src.tar.gz +Source2: xmoto.desktop +Source3: xmoto-icon.png +Patch0: xmoto-0.5.3-libpng14.patch +Patch1: xmoto-0.5.10-gcc-4.8.patch +License: GPL +## AUTOBUILDREQ-BEGIN +BuildRequires: glibc-devel +BuildRequires: libbzip2-devel +BuildRequires: libcurl-devel +BuildRequires: libgcc +BuildRequires: libGL-devel +BuildRequires: libGLU-devel +BuildRequires: libjpeg-devel +BuildRequires: liblua-devel +BuildRequires: libode-devel +BuildRequires: libpng-devel +BuildRequires: libSDL-devel +BuildRequires: libSDL_mixer-devel +BuildRequires: libSDL_net-devel +BuildRequires: libSDL_ttf-devel +BuildRequires: libsqlite-devel +BuildRequires: libstdc++6-devel +BuildRequires: libxdg-basedir-devel +BuildRequires: libxml2-devel +BuildRequires: libz-devel +## AUTOBUILDREQ-END + +%description +xmoto is a nice 2D motocross game, where phisics rules are very strong + +%prep +%setup -q -n %{name}-%{version} +#%patch0 -p1 +%patch1 -p0 + +%build +%configure --with-enable-zoom=1 +# Workarounf +sed -i "s|llua|llua5.1|" Makefile src/Makefile +%make + +%install +[ "%{buildroot}" != / ] && rm -rf "%{buildroot}" +%makeinstall +install -D %{SOURCE2} %{buildroot}%{_datadir}/applications/xmoto.desktop +install -D %{SOURCE3} %{buildroot}%{_datadir}/pixmaps/xmoto.png +%find_lang %{name} + +%clean +[ "%{buildroot}" != / ] && rm -rf "%{buildroot}" + +%files -f %{name}.lang +%defattr(-,root,root) +%{_bindir}/xmoto +%{_datadir}/pixmaps/xmoto.png +%dir %{_datadir}/xmoto +%dir %{_datadir}/xmoto/Textures +%dir %{_datadir}/xmoto/Textures/Fonts +%{_datadir}/xmoto/Textures/Fonts/DejaVuSans.ttf +%{_datadir}/xmoto/Textures/Fonts/DejaVuSansMono.ttf +%dir %{_datadir}/xmoto/Textures/Musics +%{_datadir}/xmoto/Textures/Musics/*.ogg +%{_datadir}/xmoto/xmoto.bin +%{_datadir}/xmoto/xmoto_icone_x.ico +%{_datadir}/applications/xmoto.desktop +%{_mandir}/man6/xmoto.6* +%doc AUTHORS COPYING +#ChangeLog NEWS README TODO + +%changelog +* Sun Oct 20 2013 Silvan Calarco 0.5.10-1mamba +- update to 0.5.10 + +* Fri Mar 18 2011 Ercole 'ercolinux' Carpanetto 0.5.5-1mamba +- update to 0.5.5 + +* Mon Oct 25 2010 Silvan Calarco 0.5.3-1mamba +- update to 0.5.3 + +* Fri Nov 20 2009 Ercole 'ercolinux' Carpanetto 0.5.2-1mamba +- update to 0.5.2 +- added build requirements for libSDL_net-devel + +* Mon Jul 07 2008 Silvan Calarco 0.4.2-2mamba +- added desktop menu icon +- move build requirements to correct position + +* Sat Jul 05 2008 Ercole 'ercolinux' Carpanetto 0.4.2-1mamba +- package created by autospec