]> git.pld-linux.org Git - packages/wesnoth.git/blame - wesnoth.spec
- 1.3.8
[packages/wesnoth.git] / wesnoth.spec
CommitLineData
4f6ef9bb 1# TODO
2# - package rest of developement tools
dad9a32e 3#
4# Conditional build
5%bcond_without server # without server
b18d78c0 6%bcond_without tools # without tools
dad9a32e 7#
8Summary: Strategy game with a fantasy theme
157e8e1f 9Summary(pl.UTF-8): Strategiczna gra z motywem fantasy
dad9a32e 10Name: wesnoth
cbd482f6 11Version: 1.3.8
46ecb3d5 12Release: 1
482a922c 13License: GPL v2+
dad9a32e 14Group: X11/Applications/Games/Strategy
01b16924 15Source0: http://www.wesnoth.org/files/%{name}-%{version}.tar.bz2
cbd482f6 16# Source0-md5: e8132115dd5810df71ee14b9a40200ca
dad9a32e 17Source1: %{name}.desktop
3fdd0ea2 18Source2: %{name}d.init
6734084f 19Patch0: %{name}-Makefile.patch
1c7a318b 20Patch1: %{name}-locale_dir.patch
4d5620e7 21URL: http://www.wesnoth.org/
ae1834b0 22BuildRequires: SDL-devel >= 1.2.7
dad9a32e 23BuildRequires: SDL_image-devel >= 1.2
24BuildRequires: SDL_mixer-devel >= 1.2
dad9a32e 25BuildRequires: SDL_net-devel >= 1.2
8418f9f0 26BuildRequires: SDL_ttf-devel >= 2.0
126856ae 27BuildRequires: autoconf >= 2.59
9d16f83e
JB
28BuildRequires: automake >= 1:1.9
29BuildRequires: gettext-devel
6ac5e90b 30BuildRequires: libstdc++-devel
9d16f83e 31BuildRequires: libtool >= 2:1.5
56da1b20 32BuildRequires: python-devel
c12ea96c 33BuildRequires: rpmbuild(macros) >= 1.268
56da1b20 34BuildRequires: rpm-pythonprov
516c4760 35BuildRequires: zipios++-devel
dad9a32e 36BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
37
38%description
39Battle for Wesnoth is a fantasy strategy game. Battle for control of
40villages, using variety of units which have advantages and
41disadvantages in different types of terrains and against different
42types of attacks. Units gain experience and advance levels, and are
43carried over from one scenario to the next campaign.
44
7840b0fd
JR
45%description -l pl.UTF-8
46Battle for Wesnoth jest strategiczną grą fantasy. Batalia o kontrolę
47nad wsiami przy pomocy różnego rodzaju oddziałów, które mają przewagę
48lub jej brak w odmiennym ukształtowaniu terenu i przeciwko różnym
49sposobom ataku. Oddziały zdobywają doświadczenie i poziomy
50zaawansowania i są przenoszone z jednej scenerii do następnej
24e1b6fa 51kampanii.
dad9a32e 52
dad9a32e 53%package server
54Summary: Network server for Wesnoth
157e8e1f 55Summary(pl.UTF-8): Sieciowy serwer dla Wesnoth
dad9a32e 56Group: X11/Applications/Games/Strategy
68dfe0cd 57Requires: rc-scripts >= 0.4.0.17
392ee82f 58Requires(post,preun): /sbin/chkconfig
40b36f90
JK
59Requires(postun): /usr/sbin/groupdel
60Requires(postun): /usr/sbin/userdel
61Requires(pre): /usr/sbin/groupadd
62Requires(pre): /usr/sbin/useradd
dad9a32e 63
64%description server
65Server for playing networked games of Wesnoth.
66
7840b0fd 67%description server -l pl.UTF-8
dad9a32e 68Serwer do prowadzenia sieciowych gier Wesnoth.
dad9a32e 69
dad9a32e 70%package tools
71Summary: Tools for Wesnoth
157e8e1f 72Summary(pl.UTF-8): Narzędzia dla Wesnoth
dad9a32e 73Group: X11/Applications/Games/Strategy
6ac5e90b 74Requires: %{name} = %{version}-%{release}
dad9a32e 75
76%description tools
77Map editor and translations tools.
78
7840b0fd
JR
79%description tools -l pl.UTF-8
80Edytor map i narzędzia do tłumaczeń.
dad9a32e 81
82%prep
126856ae 83%setup -q
6734084f 84%patch0 -p1
1c7a318b 85%patch1 -p1
dad9a32e 86
87%build
629473ee 88%{__gettextize}
629473ee 89%{__aclocal}
90%{__autoconf}
91%{__autoheader}
92%{__automake}
dad9a32e 93%configure \
94 %{?with_server:--enable-server} \
95 %{?with_tools:--enable-editor} \
c12ea96c
MB
96 %{?with_tools:--enable-tools} \
97 --with-zipios
dad9a32e 98%{__make}
99
100%install
101rm -rf $RPM_BUILD_ROOT
1e98d246 102install -d $RPM_BUILD_ROOT{%{_desktopdir},%{_pixmapsdir},/var/run/wesnothd,/etc/rc.d/init.d}
dad9a32e 103
104%{__make} install \
105 DESTDIR=$RPM_BUILD_ROOT
106
0a0b6608 107install images/wesnoth-icon.png $RPM_BUILD_ROOT%{_pixmapsdir}
dad9a32e 108install %{SOURCE1} $RPM_BUILD_ROOT%{_desktopdir}
3fdd0ea2 109install %{SOURCE2} $RPM_BUILD_ROOT/etc/rc.d/init.d/wesnothd
dad9a32e 110
c12ea96c
MB
111mv -f $RPM_BUILD_ROOT%{_datadir}/locale/{gl_ES,gl}
112mv -f $RPM_BUILD_ROOT%{_datadir}/locale/{nb_NO,nb}
113
114rm -rf $RPM_BUILD_ROOT%{_datadir}/locale/ca_ES@valencia
115
116# unsupported(?)
117rm -rf $RPM_BUILD_ROOT%{_datadir}/locale/la
118
119# the same as manuals from %{_mandir}/man?
120rm -rf $RPM_BUILD_ROOT%{_mandir}/en_GB
121
5105ea28 122%find_lang %{name} --all-name
123
dad9a32e 124%clean
125rm -rf $RPM_BUILD_ROOT
126
40b36f90
JK
127%pre server
128%groupadd -P %{name}-server -g 178 wesnothd
129%useradd -P %{name}-server -u 178 -d /var/run/wesnothd -c "Wesnothd User" -g wesnothd wesnothd
130
3fdd0ea2 131%post server
132/sbin/chkconfig --add wesnothd
c12ea96c 133%service wesnothd restart
3fdd0ea2 134
135%preun server
136if [ "$1" = "0" ]; then
c12ea96c 137 %service wesnothd stop
24e1b6fa 138 /sbin/chkconfig --del wesnothd
40b36f90
JK
139 %userremove wesnothd
140 %groupremove wesnothd
3fdd0ea2 141fi
142
5105ea28 143%files -f %{name}.lang
dad9a32e 144%defattr(644,root,root,755)
145%doc changelog README MANUAL*
146%attr(755,root,root) %{_bindir}/wesnoth
0c6dc98e 147%{_mandir}/man6/wesnoth.6*
126856ae 148%lang(bg) %{_mandir}/bg/man6/wesnoth.6*
149%lang(da) %{_mandir}/da/man6/wesnoth.6*
1acfd818 150%lang(de) %{_mandir}/de/man6/wesnoth.6*
5105ea28 151%lang(cs) %{_mandir}/cs/man6/wesnoth.6*
5105ea28 152%lang(fr) %{_mandir}/fr/man6/wesnoth.6*
126856ae 153%lang(hu) %{_mandir}/hu/man6/wesnoth.6*
154%lang(it) %{_mandir}/it/man6/wesnoth.6*
5105ea28 155%lang(ja) %{_mandir}/ja/man6/wesnoth.6*
a6412a7b 156%lang(nl) %{_mandir}/nl/man6/wesnoth.6*
126856ae 157%lang(pl) %{_mandir}/pl/man6/wesnoth.6*
5105ea28 158%lang(pt_BR) %{_mandir}/pt_BR/man6/wesnoth.6*
126856ae 159%lang(ru) %{_mandir}/ru/man6/wesnoth.6*
5105ea28 160%lang(sk) %{_mandir}/sk/man6/wesnoth.6*
126856ae 161%lang(sr) %{_mandir}/sr/man6/wesnoth.6*
6734084f 162%lang(sv) %{_mandir}/sv/man6/wesnoth.6*
0c6dc98e 163%{_datadir}/%{name}
dad9a32e 164%{_desktopdir}/%{name}.desktop
0a0b6608 165%{_pixmapsdir}/*
dad9a32e 166
167%if %{with server}
168%files server
169%defattr(644,root,root,755)
170%attr(755,root,root) %{_bindir}/wesnothd
3fdd0ea2 171%attr(754,root,root) /etc/rc.d/init.d/wesnothd
0c6dc98e 172%{_mandir}/man6/wesnothd.6*
126856ae 173%lang(bg) %{_mandir}/bg/man6/wesnothd.6*
5105ea28 174%lang(cs) %{_mandir}/cs/man6/wesnothd.6*
126856ae 175%lang(da) %{_mandir}/da/man6/wesnothd.6*
1acfd818 176%lang(de) %{_mandir}/de/man6/wesnothd.6*
5105ea28 177%lang(fr) %{_mandir}/fr/man6/wesnothd.6*
126856ae 178%lang(hu) %{_mandir}/hu/man6/wesnothd.6*
179%lang(it) %{_mandir}/it/man6/wesnothd.6*
5105ea28 180%lang(ja) %{_mandir}/ja/man6/wesnothd.6*
a6412a7b 181%lang(nl) %{_mandir}/nl/man6/wesnothd.6*
126856ae 182%lang(pl) %{_mandir}/pl/man6/wesnothd.6*
5105ea28 183%lang(pt_BR) %{_mandir}/pt_BR/man6/wesnothd.6*
126856ae 184%lang(ru) %{_mandir}/ru/man6/wesnothd.6*
5105ea28 185%lang(sk) %{_mandir}/sk/man6/wesnothd.6*
126856ae 186%lang(sr) %{_mandir}/sr/man6/wesnothd.6*
6734084f 187%lang(sv) %{_mandir}/sv/man6/wesnothd.6*
40b36f90 188%attr(770,wesnothd,wesnothd) %dir /var/run/wesnothd
dad9a32e 189%endif
190
191%if %{with tools}
192%files tools
193%defattr(644,root,root,755)
027c8016 194%attr(755,root,root) %{_bindir}/cutter
195%attr(755,root,root) %{_bindir}/exploder
dad9a32e 196%attr(755,root,root) %{_bindir}/wesnoth_editor
4ff8d7ea 197%{_mandir}/man6/wesnoth_editor.6*
126856ae 198%lang(bg) %{_mandir}/bg/man6/wesnoth_editor.6*
5105ea28 199%lang(cs) %{_mandir}/cs/man6/wesnoth_editor.6*
126856ae 200%lang(da) %{_mandir}/da/man6/wesnoth_editor.6*
1acfd818 201%lang(de) %{_mandir}/de/man6/wesnoth_editor.6*
5105ea28 202%lang(fr) %{_mandir}/fr/man6/wesnoth_editor.6*
126856ae 203%lang(hu) %{_mandir}/hu/man6/wesnoth_editor.6*
5105ea28 204%lang(it) %{_mandir}/it/man6/wesnoth_editor.6*
205%lang(ja) %{_mandir}/ja/man6/wesnoth_editor.6*
a6412a7b 206%lang(nl) %{_mandir}/nl/man6/wesnoth_editor.6*
126856ae 207%lang(pl) %{_mandir}/pl/man6/wesnoth_editor.6*
5105ea28 208%lang(pt_BR) %{_mandir}/pt_BR/man6/wesnoth_editor.6*
126856ae 209%lang(ru) %{_mandir}/ru/man6/wesnoth_editor.6*
5105ea28 210%lang(sk) %{_mandir}/sk/man6/wesnoth_editor.6*
126856ae 211%lang(sr) %{_mandir}/sr/man6/wesnoth_editor.6*
6734084f 212%lang(sv) %{_mandir}/sv/man6/wesnoth_editor.6*
dad9a32e 213%endif
This page took 0.062119 seconds and 4 git commands to generate.