# There is Gearhead 2 in development right now, # and upstream always refers to the first game as "Gearhead 1", # so let's stick with that and use "gearhead1" instead of just "gearhead" Name: gearhead1 %global reponame gearhead-1 %global prettyname GearHead: Arena Summary: Roguelike mecha role-playing game License: LGPLv2.1 Version: 1.310 Release: 1 URL: http://gearheadrpg.com Source0: https://github.com/jwvhewitt/%{reponame}/archive/v%{version}/%{reponame}-%{version}.tar.gz ExclusiveArch: %{fpc_arches} BuildRequires: SDL-devel BuildRequires: SDL_image-devel BuildRequires: SDL_ttf-devel BuildRequires: fpc BuildRequires: fpc-srpm-macros BuildRequires: glibc-devel Requires: bitstream-vera-sans-fonts Requires: bitstream-vera-sans-mono-fonts Requires: bitstream-vera-serif-fonts Requires: %{name}-data = %{version}-%{release} %description Set a century and a half after nuclear war, in this game you explore a world where various factions compete to determine the future of the human race. Features include random plot generation and over two hundred mecha designs. Pilot a giant robot, a city smashing tank, a living jet fighter, or anything else that can be built using the game's sophisticated design system. %package data Summary: Data files for %{name} BuildArch: noarch %description data Data files (graphics, sounds) required to play %{prettyname}. %prep %setup -q -n %{reponame}-%{version} %build fpc -gw -O2 -dSDLMODE gharena.pas # The game looks for the data files in the current working directory cat > wrapper.sh << EOF #!%{_bindir}/bash cd %{_datadir}/%{name} %{_libexecdir}/%{name} \$@ EOF %install install -m 755 -d %{buildroot}%{_bindir} install -m 755 wrapper.sh %{buildroot}%{_bindir}/%{name} install -m 755 -d %{buildroot}%{_libexecdir} install -m 755 gharena %{buildroot}%{_libexecdir}/%{name} install -m 755 -d %{buildroot}%{_datadir}/%{name} cp -a Design GameData Image Series %{buildroot}%{_datadir}/%{name} # Remove the bundled Bitstream Vera fonts and # replace them with symlinks to fonts provided by bitstream-vera-* packages for VERA_SANS in Vera VeraBd VeraBI VeraIt; do ln -sf \ "%{_datadir}/fonts/bitstream-vera-sans-fonts/${VERA_SANS}.ttf" \ "%{buildroot}%{_datadir}/%{name}/Image/${VERA_SANS}.ttf" done for VERA_MONO in VeraMo VeraMoBd VeraMoBI VeraMoIt; do ln -sf \ "%{_datadir}/fonts/bitstream-vera-sans-mono-fonts/${VERA_MONO}.ttf" \ "%{buildroot}%{_datadir}/%{name}/Image/${VERA_MONO}.ttf" done for VERA_SERIF in VeraSe VeraSeBd; do ln -sf \ "%{_datadir}/fonts/bitstream-vera-serif-fonts/${VERA_SERIF}.ttf" \ "%{buildroot}%{_datadir}/%{name}/Image/${VERA_SERIF}.ttf" done %files %doc doc/ %doc readme.md %license license.txt %{_bindir}/%{name} %{_libexecdir}/%{name} %files data %{_datadir}/%{name} %changelog * Sat Apr 11 2020 Artur Iwicki - 1.310-1 - Initial packaging