| 1 |
# Copyright (c) 2007 oc2pus <toni@links2linux.de>
|
| 2 |
# Copyright (c) 2007 Hans de Goede <j.w.r.degoede@hhs.nl>
|
| 3 |
# This file and all modifications and additions to the pristine
|
| 4 |
# package are under the same license as the package itself.
|
| 5 |
|
| 6 |
Name: 8Kingdoms
|
| 7 |
Version: 1.1.0
|
| 8 |
Release: 7%{?dist}
|
| 9 |
Summary: 8 Kingdoms is a 3D turn-based fantasy strategic game
|
| 10 |
Group: Amusements/Games
|
| 11 |
License: GPL+
|
| 12 |
URL: http://kralovstvi.sourceforge.net/
|
| 13 |
# This is:
|
| 14 |
# http://downloads.sourceforge.net/kralovstvi/%{name}-%{version}.tar.gz
|
| 15 |
# With external/extgl.h removed, as that contains parts of Windows gl.h and
|
| 16 |
# parts of a version of glext.h which falls under the "SGI Free Software
|
| 17 |
# License B", neither which are Free software.
|
| 18 |
Source0: %{name}-%{version}.tar.gz
|
| 19 |
# This is a Free replacement file with the troublesome parts replaced with
|
| 20 |
# parts from Mesa's gl.h and from The Kronos Group glext.h .
|
| 21 |
Source1: extgl.h
|
| 22 |
Source2: %{name}.desktop
|
| 23 |
Source3: %{name}.png
|
| 24 |
Patch0: 8Kingdoms-1.1.0-64bit.patch
|
| 25 |
Patch1: 8Kingdoms-1.1.0-locking.patch
|
| 26 |
Patch2: 8Kingdoms-1.1.0-crash.patch
|
| 27 |
Patch3: 8Kingdoms-1.1.0-gcc43.patch
|
| 28 |
Patch4: 8Kingdoms-1.1.0-divide-by-zero.patch
|
| 29 |
Patch5: 8Kingdoms-1.1.0-cvs-fixes.patch
|
| 30 |
Patch6: 8Kingdoms-1.1.0-tcl-threads.patch
|
| 31 |
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
|
| 32 |
BuildRequires: expat-devel SDL_mixer-devel tcl-devel desktop-file-utils
|
| 33 |
Requires: hicolor-icon-theme opengl-games-utils
|
| 34 |
|
| 35 |
%description
|
| 36 |
8 Kingdoms is a 3D turn-based fantasy strategic game in which
|
| 37 |
players become kings, build their empires and conquer enemy
|
| 38 |
kingdoms.
|
| 39 |
|
| 40 |
Theme of the game 8 Kingdoms is inspirated by the world of fantasy.
|
| 41 |
Players play on a fully 3D hex map. They construct buildings,
|
| 42 |
recruit units including infantry, mounted units, mages, catapults
|
| 43 |
and finally they attack enemy or help allies. Units gain experiences
|
| 44 |
during the battle, each unit can get some abilities upgraded to be
|
| 45 |
stronger. Data are stored in XML and freely accessible - from
|
| 46 |
language versions to units' attributes, moreover map editor with
|
| 47 |
random map generator is included for comfortable map editing.
|
| 48 |
|
| 49 |
|
| 50 |
%prep
|
| 51 |
%setup -q
|
| 52 |
%patch0 -p1
|
| 53 |
%patch1 -p1
|
| 54 |
%patch2 -p1
|
| 55 |
%patch3 -p1
|
| 56 |
%patch4 -p1
|
| 57 |
%patch5 -p1
|
| 58 |
%patch6 -p1
|
| 59 |
cp -a %{SOURCE1} external
|
| 60 |
chmod -x doc/gui/gui_img1.png
|
| 61 |
# configure won't recognize --datadir ...
|
| 62 |
sed -i 's|games/8Kingdoms|share/8Kingdoms|g' configure
|
| 63 |
|
| 64 |
|
| 65 |
%build
|
| 66 |
%configure
|
| 67 |
make %{?_smp_mflags}
|
| 68 |
|
| 69 |
|
| 70 |
%install
|
| 71 |
rm -rf $RPM_BUILD_ROOT
|
| 72 |
# And here we must explicitly set pkgdatadir despite our earlier sed!
|
| 73 |
make install DESTDIR=$RPM_BUILD_ROOT pkgdatadir=%{_datadir}/%{name}
|
| 74 |
ln -s opengl-game-wrapper.sh $RPM_BUILD_ROOT%{_bindir}/%{name}-wrapper
|
| 75 |
|
| 76 |
# below is the desktop file and icon stuff.
|
| 77 |
mkdir -p $RPM_BUILD_ROOT%{_datadir}/applications
|
| 78 |
desktop-file-install --vendor fedora \
|
| 79 |
--dir $RPM_BUILD_ROOT%{_datadir}/applications \
|
| 80 |
%{SOURCE2}
|
| 81 |
mkdir -p $RPM_BUILD_ROOT%{_datadir}/icons/hicolor/96x96/apps
|
| 82 |
install -p -m 644 %{SOURCE3} \
|
| 83 |
$RPM_BUILD_ROOT%{_datadir}/icons/hicolor/96x96/apps
|
| 84 |
|
| 85 |
|
| 86 |
%clean
|
| 87 |
rm -rf $RPM_BUILD_ROOT
|
| 88 |
|
| 89 |
|
| 90 |
%post
|
| 91 |
touch --no-create %{_datadir}/icons/hicolor || :
|
| 92 |
if [ -x %{_bindir}/gtk-update-icon-cache ]; then
|
| 93 |
%{_bindir}/gtk-update-icon-cache --quiet %{_datadir}/icons/hicolor || :
|
| 94 |
fi
|
| 95 |
|
| 96 |
%postun
|
| 97 |
touch --no-create %{_datadir}/icons/hicolor || :
|
| 98 |
if [ -x %{_bindir}/gtk-update-icon-cache ]; then
|
| 99 |
%{_bindir}/gtk-update-icon-cache --quiet %{_datadir}/icons/hicolor || :
|
| 100 |
fi
|
| 101 |
|
| 102 |
|
| 103 |
%files
|
| 104 |
%defattr(-,root,root,-)
|
| 105 |
%doc AUTHORS ChangeLog COPYING README doc/*
|
| 106 |
%{_bindir}/%{name}*
|
| 107 |
%{_datadir}/%{name}
|
| 108 |
%{_datadir}/applications/fedora-%{name}.desktop
|
| 109 |
%{_datadir}/icons/hicolor/96x96/apps/%{name}.png
|
| 110 |
|
| 111 |
|
| 112 |
%changelog
|
| 113 |
* Mon Feb 23 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.1.0-7
|
| 114 |
- Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild
|
| 115 |
|
| 116 |
* Wed Feb 13 2008 Hans de Goede <j.w.r.degoede@hhs.nl> 1.1.0-6
|
| 117 |
- Fix compiling with gcc 4.3 (again, newer version is even stricter)
|
| 118 |
|
| 119 |
* Tue Jan 8 2008 Hans de Goede <j.w.r.degoede@hhs.nl> 1.1.0-5
|
| 120 |
- Don't call a TclInterpreter from other threads then its created in, this
|
| 121 |
violates Tcl's thread model, this fixes running with Tcl-8.5
|
| 122 |
|
| 123 |
* Fri Jan 4 2008 Hans de Goede <j.w.r.degoede@hhs.nl> 1.1.0-4
|
| 124 |
- Fix divide by zero abort (bz 427485)
|
| 125 |
- Backport various fixes from CVS
|
| 126 |
- Note this still won't work with tcl 8.5, this release is just to keep
|
| 127 |
rawhide in sync with F-8 / F-7
|
| 128 |
|
| 129 |
* Thu Jan 3 2008 Hans de Goede <j.w.r.degoede@hhs.nl> 1.1.0-3
|
| 130 |
- Rebuild for new tcl, note: it builds but does not work with the new TCL!
|
| 131 |
help fixing this asked upstream. Any help much appreciated!
|
| 132 |
- Fix compiling with gcc 4.3
|
| 133 |
- Fix crash undercertain conditions (bz 425799)
|
| 134 |
|
| 135 |
* Sun Dec 2 2007 Hans de Goede <j.w.r.degoede@hhs.nl> 1.1.0-2
|
| 136 |
- Replace BuildRequires expat with expat-devel (oops)
|
| 137 |
- Add a patch which stops 8Kingdoms from hanging in certain cases
|
| 138 |
- Use opengl-games-utils wrapper to show error dialog when DRI is missing
|
| 139 |
|
| 140 |
* Sat Nov 24 2007 Hans de Goede <j.w.r.degoede@hhs.nl> 1.1.0-1
|
| 141 |
- Adapted Packman specfile for Fedora
|
| 142 |
|
| 143 |
* Fri Aug 10 2007 Toni Graffy <toni@links2linux.de> - 1.1.0-0.pm.1
|
| 144 |
- initial build 1.1.0
|