%global _release_date 2016-09-16 %global _commit0 49f91235b4754e6f6b8428b112acb5a03d963462 %global _shortcommit0 %(c=%{_commit0}; echo ${c:0:7}) Name: freeorion Version: 0.4.6 Release: 8%{?dist} Summary: Turn-based space empire and galactic conquest (4X) computer game Group: Amusements/Games License: GPLv2 and LGPLv2+ URL: http://freeorion.org Source0: https://github.com/freeorion/freeorion/releases/download/v%{version}/FreeOrion_v%{version}_%{_release_date}.%{_shortcommit0}_Source.tar.gz Source1: http://linkdupont.fedorapeople.org/sources/freeorion.appdata.xml # Fixed upstream https://github.com/freeorion/freeorion/commit/b93b93a07d8cffa08d1bb84d044f0e54d7a47472 Patch0: 1416197-Fix-bug-1272-MultiMeterStatusBar-crash-with-zero-val.patch BuildRequires: cmake BuildRequires: python2-devel >= 2.7 BuildRequires: boost-devel >= 1.47.0 BuildRequires: mesa-libGL-devel BuildRequires: freetype-devel BuildRequires: mesa-libGLU-devel BuildRequires: SDL2-devel BuildRequires: glew-devel BuildRequires: openal-soft-devel BuildRequires: libogg-devel BuildRequires: libvorbis-devel BuildRequires: desktop-file-utils BuildRequires: libappstream-glib Requires: hicolor-icon-theme Requires: dejavu-sans-fonts Requires: google-roboto-fonts Requires: %{name}-data = %{version}-%{release} %description FreeOrion, an open-source game inspired by Master of Orion, is a turn-based game of epic space strategy that builds on the classic '4X' model by incorporating the nation-building elements of games such as Europa Universalis 2 and a versatile tactical combat engine. While its modular, open-source design allows for a significant degree of customization of the game engine and the story elements by the community, the FreeOrion team is dedicated to the construction of a living, breathing universe in a 'grand campaign' model. %package data Summary: Game data for %{name} License: CC-BY-SA BuildArch: noarch %description data Images, sound and game data for %{name}. %prep %autosetup -n src-tarball -p1 %build %cmake -DCMAKE_INSTALL_LIBDIR=%{_lib} . # disable parallel builds on ppc64le %ifarch ppc64le %__make -j1 %else %make_build %endif %install %make_install install -m644 -D %SOURCE1 %{buildroot}%{_datadir}/appdata/%{name}.appdata.xml rm -rf %{buildroot}%{_datadir}/%{name}/default/python/tests rm -rf %{buildroot}%{_datadir}/%{name}/default/data/fonts/* ln -s %{_datadir}/fonts/google-roboto/Roboto-{Regular,Bold}.ttf %{buildroot}%{_datadir}/%{name}/default/data/fonts/ ln -s %{_datadir}/fonts/dejavu/DejaVuSans{,-Bold}.ttf %{buildroot}%{_datadir}/%{name}/default/data/fonts/ mv GG/COPYING GG/COPYING.libgigi %check ctest -V %{?_smp_mflags} . appstream-util validate-relax --nonet %{buildroot}%{_datadir}/appdata/%{name}.appdata.xml desktop-file-validate %{name}.desktop %post /bin/touch --no-create %{_datadir}/icons/hicolor &>/dev/null || : /sbin/ldconfig %postun if [ $1 -eq 0 ] ; then /bin/touch --no-create %{_datadir}/icons/hicolor &>/dev/null /usr/bin/gtk-update-icon-cache %{_datadir}/icons/hicolor &>/dev/null || : fi /sbin/ldconfig %posttrans /usr/bin/gtk-update-icon-cache %{_datadir}/icons/hicolor &>/dev/null || : %files %license default/COPYING GG/COPYING.libgigi %doc README.md ChangeLog.md %{_bindir}/%{name} %{_bindir}/%{name}{ca,d} %{_libdir}/%{name} %{_datadir}/applications/*.desktop %{_datadir}/appdata/%{name}.appdata.xml %{_datadir}/icons/hicolor/*/apps/%{name}.png %files data %license default/COPYING %{_datadir}/%{name} %changelog * Thu Feb 23 2017 josef radinger - 0.4.6-8 - rebuild for boost-update * Fri Feb 3 2017 Link Dupont - 0.4.6-7 - Use upstream's fix for #1416197 * Thu Feb 2 2017 Link Dupont - 0.4.6-6 - Patch to fix crash during MultiMeterStatusBar render (RHBZ#1416197) * Tue Jan 10 2017 Orion Poplawski - 0.4.6-6 - Rebuild for glew 2.0.0 * Mon Dec 5 2016 Link Dupont - 0.4.6-5 - Fix license naming conflict * Mon Nov 21 2016 Link Dupont - 0.4.6-4 - Replace fonts with symlinks to system font paths * Sun Nov 20 2016 Link Dupont - 0.4.6-3 - Unbundled fonts - Fixed license identifiers - Fixed dependencies * Thu Nov 3 2016 Link Dupont - 0.4.6-2 - Change build parameters for ppc64le architecture * Wed Oct 19 2016 Link Dupont - 0.4.6-1 - Initial package