%define oname gearhead-1 %define asciidir %{_builddir}/%{oname}-%{version}-ascii Name: gearhead Version: 1.310 Release: %mkrel 3 Summary: GearHead: Arena, the first game in the roguelike mecha RPG series Group: Games/Adventure License: LGPLv2+ URL: http://gearheadrpg.com Source0: https://github.com/jwvhewitt/gearhead-1/archive/v%{version}/%{oname}-%{version}.tar.gz # Config file based off doc/Config.txt Source1: %{name}.conf # Manpage from Debian package Source2: %{name}.6 Source3: %{name}128.png Patch0: gearhead-1.300-deb-mga-unixpaths.patch Patch1: gearhead-1.300-mga-unbundle-fonts.patch BuildRequires: fpc BuildRequires: pkgconfig(sdl) BuildRequires: pkgconfig(SDL_image) BuildRequires: pkgconfig(SDL_ttf) BuildRequires: pkgconfig(x11) %description A century and a half ago the Earth was nearly destroyed by nuclear war. Now, a federation of free city-states has begun to restore civilization. However, there are forces operating in the darkness which will unleash the horrors of the past age in a bid to determine the future of the human race. This is a virtual to trigger the installation of either %{name}-sdl or %{name}-ascii. #---------------------------------------------------------------------- %package sdl Summary: GearHead: Arena, the first game in the roguelike mecha RPG series (SDL graphics) Requires: %{name}-data >= %{version} Requires: fonts-ttf-bitstream-vera Provides: %{name} = %{version}-%{release} %description sdl A century and a half ago the Earth was nearly destroyed by nuclear war. Now, a federation of free city-states has begun to restore civilization. However, there are forces operating in the darkness which will unleash the horrors of the past age in a bid to determine the future of the human race. Features of the game include random storyline generation, richly detailed character generation, complex NPC interaction, and of course over 150 different mechanical designs ranging from jet fighters to giant robots to city-smashing tanks. This is the graphical SDL version. For the ascii version, use gearhead-ascii. %files sdl %{_gamesbindir}/%{name}-sdl %{_datadir}/applications/%{name}-sdl.desktop #---------------------------------------------------------------------- %package ascii Summary: GearHead: Arena, the first game in the roguelike mecha RPG series (ascii) Requires: %{name}-data >= %{version} Provides: %{name} = %{version}-%{release} %description ascii A century and a half ago the Earth was nearly destroyed by nuclear war. Now, a federation of free city-states has begun to restore civilization. However, there are forces operating in the darkness which will unleash the horrors of the past age in a bid to determine the future of the human race. Features of the game include random storyline generation, richly detailed character generation, complex NPC interaction, and of course over 150 different mechanical designs ranging from jet fighters to giant robots to city-smashing tanks. This is the ascii version. For the graphical SDL version, use gearhead-sdl. %files ascii %{_gamesbindir}/%{name}-ascii %{_datadir}/applications/%{name}-ascii.desktop #---------------------------------------------------------------------- %package data Summary: Data files for GearHead: Arena BuildArch: noarch %description data This package contains arch-independent data files for the GearHead: Arena game. %files data %doc history.txt readme.md doc/* %{_gamesdatadir}/%{name}/ %{_iconsdir}/hicolor/128x128/apps/%{name}.png %{_mandir}/man6/%{name}.6* %config(noreplace) %{_sysconfdir}/%{name}.conf #---------------------------------------------------------------------- %prep %setup -q -n %{oname}-%{version} %autopatch -p1 rm -f Image/Vera*.ttf mkdir -p %{asciidir} cp -a * %{asciidir} %build # Build SDL flavour fpc -g -O2 -XD -dSDLMODE gharena # Build ascii flavour pushd %{asciidir} fpc -g -O2 -XD gharena popd %install install -d %{buildroot}%{_gamesbindir} install -m755 gharena %{buildroot}%{_gamesbindir}/%{name}-sdl install -m755 %{asciidir}/gharena %{buildroot}%{_gamesbindir}/%{name}-ascii install -d %{buildroot}%{_gamesdatadir}/%{name} cp -a Image Design GameData Series %{buildroot}%{_gamesdatadir}/%{name} install -D %{_sourcedir}/%{name}.conf %{buildroot}%{_sysconfdir}/%{name}.conf install -D %{_sourcedir}/%{name}.6 %{buildroot}%{_mandir}/man6/%{name}.6 install -D %{_sourcedir}/%{name}128.png %{buildroot}%{_iconsdir}/hicolor/128x128/apps/%{name}.png install -d %{buildroot}%{_datadir}/applications cat << EOF > %{buildroot}%{_datadir}/applications/%{name}-sdl.desktop [Desktop Entry] Name=Gearhead: Arena (SDL) GenericName=Roguelike mecha game Comment=GearHead: Arena, the first game in the roguelike mecha RPG series (SDL graphics) Exec=%{name}-sdl Icon=%{name} Type=Application Terminal=false Categories=Game;RolePlaying; EOF cat << EOF > %{buildroot}%{_datadir}/applications/%{name}-ascii.desktop [Desktop Entry] Name=Gearhead: Arena (ascii) GenericName=Roguelike mecha game) Comment=GearHead: Arena, the first game in the roguelike mecha RPG series (ascii) Exec=%{name}-ascii Icon=%{name} Type=Application Terminal=true Categories=Game;RolePlaying; EOF %changelog * Fri Apr 01 2022 umeabot <umeabot> 1.310-3.mga9 + Revision: 1839433 - Mageia 9 Mass Rebuild * Sat Feb 15 2020 umeabot <umeabot> 1.310-2.mga8 + Revision: 1526062 - Mageia 8 Mass Rebuild * Thu Apr 25 2019 akien <akien> 1.310-1.mga7 + Revision: 1395280 - Version 1.310 * Sun Sep 23 2018 umeabot <umeabot> 1.302-2.mga7 + Revision: 1297849 - Mageia 7 Mass Rebuild * Mon Jun 27 2016 akien <akien> 1.302-1.mga6 + Revision: 1037722 - Version 1.302 * Tue Apr 19 2016 akien <akien> 1.301-1.mga6 + Revision: 1003619 - Version 1.301 * Mon Apr 04 2016 akien <akien> 1.300-1.mga6 + Revision: 998411 - Unbundle fonts - import gearhead, based off the Debian package by Kari Pahula