]> git.pld-linux.org Git - packages/wesnoth.git/blob - wesnoth.spec
- fixed URL
[packages/wesnoth.git] / wesnoth.spec
1 #
2 # Conditional build
3 %bcond_without  server  # without server
4 %bcond_without  tools   # without tools
5 #
6 Summary:        Strategy game with a fantasy theme
7 Summary(pl):    Strategiczna gra z motywem fantasy
8 Name:           wesnoth
9 Version:        0.8.11
10 Release:        1
11 License:        GPL v2
12 Group:          X11/Applications/Games/Strategy
13 Icon:           wesnoth-icon.xpm
14 Source0:        http://www.wesnoth.org/files/%{name}-%{version}.tar.gz
15 # Source0-md5:  929c65818cc2fb47227929f253fb1f8c
16 Source1:        %{name}.desktop
17 Source2:        %{name}d.init
18 URL:            http://www.wesnoth.org/
19 BuildRequires:  SDL-devel >= 1.2.7
20 BuildRequires:  SDL_image-devel >= 1.2
21 BuildRequires:  SDL_mixer-devel >= 1.2
22 BuildRequires:  SDL_net-devel >= 1.2
23 BuildRequires:  SDL_ttf-devel >= 2.0
24 BuildRequires:  libstdc++-devel
25 Requires:       SDL_image >= 1.2
26 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
27
28 %description
29 Battle for Wesnoth is a fantasy strategy game. Battle for control of
30 villages, using variety of units which have advantages and
31 disadvantages in different types of terrains and against different
32 types of attacks. Units gain experience and advance levels, and are
33 carried over from one scenario to the next campaign.
34
35 %description -l pl
36 Battle for Wesnoth jest strategiczn± gr± fantasy. Batalia o kontrolê
37 nad wsiami przy pomocy ró¿nego rodzaju oddzia³ów, które maj± przewagê
38 lub jej brak w odmiennym ukszta³towaniu terenu i przeciwko ró¿nym
39 sposobom ataku. Oddzia³y zdobywaj± do¶wiadczenie i poziomy
40 zaawansowania i s± przenoszone z jednej scenerii do nastêpnej
41 kampanii.
42
43 %package server
44 Summary:        Network server for Wesnoth
45 Summary(pl):    Sieciowy serwer dla Wesnoth
46 Group:          X11/Applications/Games/Strategy
47 Requires(post,preun):   /sbin/chkconfig
48
49 %description server
50 Server for playing networked games of Wesnoth.
51
52 %description server -l pl
53 Serwer do prowadzenia sieciowych gier Wesnoth.
54
55 %package tools
56 Summary:        Tools for Wesnoth
57 Summary(pl):    Narzêdzia dla Wesnoth
58 Group:          X11/Applications/Games/Strategy
59 Requires:       %{name} = %{version}-%{release}
60
61 %description tools
62 Map editor and translations tools.
63
64 %description tools -l pl
65 Edytor map i narzêdzia do t³umaczeñ.
66
67 %prep
68 %setup -q
69
70 %build
71 %configure \
72         %{?with_server:--enable-server} \
73         %{?with_tools:--enable-editor} \
74         %{?with_tools:--enable-tools}
75 %{__make}
76
77 %install
78 rm -rf $RPM_BUILD_ROOT
79 install -d $RPM_BUILD_ROOT{%{_desktopdir},%{_pixmapsdir}}
80 install -d $RPM_BUILD_ROOT/etc/rc.d/init.d
81
82 %{__make} install \
83         DESTDIR=$RPM_BUILD_ROOT
84
85 install images/wesnoth-icon.png $RPM_BUILD_ROOT%{_pixmapsdir}
86 install %{SOURCE1} $RPM_BUILD_ROOT%{_desktopdir}
87 install %{SOURCE2} $RPM_BUILD_ROOT/etc/rc.d/init.d/wesnothd
88
89 %clean
90 rm -rf $RPM_BUILD_ROOT
91
92 %post server
93 /sbin/chkconfig --add wesnothd
94 if [ -f /var/lock/subsys/wesnothd ]; then
95         /etc/rc.d/init.d/wesnothd restart >&2
96 else
97         echo "Run \"/etc/rc.d/init.d/wesnothd start\" to start wesnothd." >&2
98 fi
99
100 %preun server
101 if [ "$1" = "0" ]; then
102         if [ -f /var/lock/subsys/wesnothd ]; then
103                 /etc/rc.d/init.d/wesnothd stop
104         fi
105         /sbin/chkconfig --del wesnothd
106 fi
107
108 %files
109 %defattr(644,root,root,755)
110 %doc changelog README MANUAL*
111 %attr(755,root,root) %{_bindir}/wesnoth
112 %attr(755,root,root) %{_bindir}/wmlxgettext
113 %{_mandir}/man6/wesnoth.6*
114 %lang(de) %{_mandir}/de/man6/wesnoth.6*
115 %{_datadir}/%{name}
116 %{_desktopdir}/%{name}.desktop
117 %{_pixmapsdir}/*
118
119 %if %{with server}
120 %files server
121 %defattr(644,root,root,755)
122 %attr(755,root,root) %{_bindir}/wesnothd
123 %attr(754,root,root) /etc/rc.d/init.d/wesnothd
124 %{_mandir}/man6/wesnothd.6*
125 %lang(de) %{_mandir}/de/man6/wesnothd.6*
126 %endif
127
128 %if %{with tools}
129 %files tools
130 %defattr(644,root,root,755)
131 %attr(755,root,root) %{_bindir}/cutter
132 %attr(755,root,root) %{_bindir}/exploder
133 %attr(755,root,root) %{_bindir}/wesnoth_editor
134 %{_mandir}/man6/wesnoth_editor.6*
135 %lang(de) %{_mandir}/de/man6/wesnoth_editor.6*
136 %endif
This page took 0.063734 seconds and 4 git commands to generate.