source: projects/specs/trunk/w/wesnoth/wesnoth-vl.spec @ 1578

Revision 1578, 15.2 KB checked in by iwaim, 14 years ago (diff)

fix changelog for wesnoth 1.8.4-1

Line 
1%define with_editor 0
2%define with_tools 0
3%define with_campaignd 0
4%define with_wesnothd 0
5
6%define ver 1.8.4
7%define src_ver %{ver}
8%define rel 1
9
10%define with_svn 0
11%if %{with_svn}
12%define svn_rev 41885
13%endif
14
15%define with_unofficial_po 0
16%define po_date            20100710
17
18Summary: Fantasy Turn-Based Strategy Game
19Summary(ja):  ターンベースのファンタジー戦略シミュレーションゲーム
20Name: wesnoth
21Version: %{ver}
22%if %{with_svn}
23Release: %{rel}.svn%{svn_rev}%{?_dist_release}
24Source0: %{name}-%{version}-svn%{svn_rev}.tar.bz2
25%else
26Release: %{rel}%{?_dist_release}
27Source0: %{name}-%{src_ver}.tar.bz2
28%endif
29Source1: wesnothd.init
30Source2: %{name}.sysconfig
31%if %{with_unofficial_po}
32#Source12: wesnoth-branches1.8_ja-%{po_date}.tar.gz
33%endif
34
35%{?nosrc:NoSource: 0}
36
37License: GPLv2+
38Group: Applications/Games
39URL: http://www.wesnoth.org/
40
41Distribution: Vine Linux
42Vendor:       Project Vine
43Packager:     munepi, iwaim
44
45Requires: xorg-x11-libs SDL SDL_image SDL_mixer SDL_net SDL_ttf
46Requires: freetype2 libpng zlib pango fontconfig
47Requires: libboost-iostreams libboost-regex
48%if %{?_dist_release} == "vl5" || %{?_dist_release} == "vl6"
49Requires: TrueType-vlgothic
50%endif
51%if %{?_dist_release} == "vl4"
52Requires: TrueType-sazanami
53%endif
54BuildRequires: desktop-file-utils
55BuildRequires: ImageMagick
56BuildRequires: xorg-x11-devel SDL-devel SDL_image-devel SDL_mixer-devel
57BuildRequires: SDL_net-devel SDL_ttf-devel
58BuildRequires: freetype2-devel libpng-devel zlib-devel pango-devel
59BuildRequires: fontconfig-devel
60BuildRequires: libboost-devel >= 1.35
61BuildRequires: libboost-iostreams libboost-regex
62BuildRequires: lua-devel
63#BuildRequires: fribidi-devel
64#BuildRequires: python-devel
65BuildRoot: %{_tmppath}/%{name}-%{version}-root
66
67Conflicts: wesnoth165
68
69%description
70Battle for Wesnoth is a fantasy turn-based strategy game. Battle for
71control of villages, using variety of units which have advantages and
72disadvantages in different types of terrains and against different
73types of attacks. Units gain experience and advance levels, and are
74carried over from one scenario to the next campaign.
75
76%description -l ja
77Battle for Wesnoth はターンベースの戦略シミュレーションゲームです.
78異なる地形や攻撃のタイプに対して,長所と短所をもつ多種のユニットを使用
79しながら,村々の支配のために戦います.ユニットは経験を得てレベルアップ
80して,シナリオから次のキャンペーンまで連れて行かれます.
81
82%if %{with_editor}
83%package editor
84Group: Applications/Games
85Summary: The Battle of Wesnoth map editor.
86Summary(ja): The Battle of Wesnoth マップエディタ
87Requires: wesnoth = %{version}-%{release}
88
89%description editor
90Battle for Wesnoth is a fantasy turn-based strategy game.
91This package contains the map editor for it.
92
93%description editor -l ja
94Battle for Wesnoth はターンベースの戦略シミュレーションゲームです.
95このパッケージには,そのマップエディタが入っています.
96%endif
97
98%if %{with_tools}
99%package tools
100Group: Applications/Games
101Summary: The Battle of Wesnoth tools.
102Summary(ja): The Battle of Wesnoth ツール
103Requires: wesnoth = %{version}-%{release}
104
105%description tools
106Battle for Wesnoth is a fantasy turn-based strategy game.
107This package includes tools for translators and artists working on
108Battle for Wesnoth.
109
110%description tools -l ja
111Battle for Wesnoth はターンベースの戦略シミュレーションゲームです.
112このパッケージには,Battle for Wesnoth で作業されている
113翻訳者やアーティストへのツールが含まれています.
114%endif
115
116%if %{with_campaignd}
117%package campaign-server
118Summary: The Battle of Wesnoth campaign server.
119Summary(ja): The Battle of Wesnoth キャンペーンサーバ
120Requires: wesnoth = %{version}-%{release}
121
122%description campaign-server
123Battle for Wesnoth is a fantasy turn-based strategy game.
124The campaign server acts as a simple download server, much like ftp, to
125provide a collection of Wesnoth campaigns to players.
126
127%description campaign-server -l ja
128Battle for Wesnoth はターンベースの戦略シミュレーションゲームです.
129このキャンペーンサーバーは,プレーヤーたちに Wesnoth キャンペーンの
130コレクションを提供するために,FTP のような簡易なダウンロードサーバとして
131動作します.
132%endif
133
134%if %{with_wesnothd}
135%package server
136Group: Applications/Games
137Summary: The Battle of Wesnoth game server.
138Summary(ja): The Battle of Wesnoth ゲームサーバ
139Requires: wesnoth = %{version}-%{release}
140Requires(post): /sbin/chkconfig
141Requires(preun): /sbin/chkconfig
142Requires(pre): /usr/sbin/useradd
143
144%description server
145Battle for Wesnoth is a fantasy turn-based strategy game.
146This package contains the wesnothd server needed to play networked games.
147
148%description server -l ja
149Battle for Wesnoth はターンベースの戦略シミュレーションゲームです.
150このパッケージには,ネットワークゲームのプレイに必要とされるwesnothdサー
151バが入っています.
152%endif
153
154
155%prep
156%__rm -rf ${RPM_BUILD_ROOT}
157
158%if %{with_svn}
159%setup -q -n %{name}-%{version}-svn%{svn_rev}
160%else
161%setup -q -n %{name}-%{src_ver}
162%endif
163
164%if %{with_unofficial_po}
165%define japo_dir wesnoth-branches1.8_ja-%{po_date}/po
166pushd %{japo_dir}
167target=(
168        wesnoth
169        wesnoth-aoi
170        wesnoth-dm
171        wesnoth-trow
172        wesnoth-utbs
173)
174for n in "${target[@]}"
175do
176%{__cp} -f $n/ja.po ../../po/$n/ja.po
177done
178popd
179%endif
180
181%build
182export CFLAGS="%{optflags}" CXXFLAGS="%{optflags}"
183%if %{with_svn}
184./autogen.sh
185%endif
186## for 1.8: missing configure script
187./autogen.sh
188%configure \
189    --disable-dependency-tracking \
190%if %{with_editor}
191    --enable-editor \
192%endif
193%if %{with_tools}
194    --enable-tools \
195%endif
196%if %{with_campaignd}
197    --enable-campaign-server \
198%endif
199%if %{with_wesnothd}
200    --enable-server=yes \
201    --with-fifodir=/var/run/wesnothd \
202    --with-server-gid=root \
203    --with-server-uid=root \
204%else
205    --enable-server=no \
206%endif
207    --with-localedir=%{_datadir}/locale \
208        ;
209   
210%{__make}
211
212
213%install
214%{__rm} -rf ${RPM_BUILD_ROOT}
215%{__make} DESTDIR=${RPM_BUILD_ROOT} install
216
217### link sazanami-gothic.ttf
218pushd ${RPM_BUILD_ROOT}%{_datadir}/%{name}/fonts/
219## for 1.2.7 or higher (contains sazanami-gothic.ttf)
220#%{__rm} -f sazanami-gothic.ttf
221## for 1.6a or higher (NOT contains sazanami-gothic.ttf)
222%{__rm} -f wqy-zenhei.ttc
223
224%if %{?_dist_release} == "vl5" || %{?_dist_release} == "vl6"
225#ln -s /usr/share/fonts/TrueType-sazanami-gothic/sazanami-gothic.ttf .
226ln -s /usr/share/fonts/TrueType-vlgothic/VL-PGothic-Regular.ttf sazanami-gothic.ttf
227ln -s /usr/share/fonts/TrueType-vlgothic/VL-Gothic-Regular.ttf wqy-zenhei.ttc
228%endif
229%if %{?_dist_release} == "vl4"
230ln -s /usr/X11R6/lib/X11/fonts/TrueType/sazanami-gothic.ttf .
231%endif
232popd
233
234### for Gnome menu
235%__mkdir_p $RPM_BUILD_ROOT/%{_datadir}/pixmaps
236%__sed -i -e 's/^Version=.*$//' \
237       -e 's/^Icon=wesnoth-icon\.png/Icon=wesnoth-icon/' \
238    icons/%{name}.desktop
239desktop-file-install \
240    --dir $RPM_BUILD_ROOT/%{_datadir}/applications \
241    --mode="0644" --vendor vine \
242    icons/%{name}.desktop
243#%__install -m 644 icons/%{name}-icon.png $RPM_BUILD_ROOT/%{_datadir}/pixmaps
244for size in 16x16 20x20 22x22 24x24 32x32 36x36 64x64 48x48 64x64 72x72 96x96 128x128 192x192 ; do
245    %__mkdir_p $RPM_BUILD_ROOT%{_datadir}/icons/hicolor/${size}/apps
246    convert icons/%{name}-icon.png -size ${size} \
247        $RPM_BUILD_ROOT%{_datadir}/icons/hicolor/${size}/apps/%{name}-icon.png
248done
249%if %{with_editor}
250desktop-file-install \
251    --dir $RPM_BUILD_ROOT/%{_datadir}/applications \
252    --mode="0644" --vendor vine \
253    icons/%{name}_editor.desktop
254%__install -m 644 icons/%{name}_editor-icon.png $RPM_BUILD_ROOT/%{_datadir}/pixmaps
255%endif
256
257### rename for tools
258%if %{with_tools}
259pushd ${RPM_BUILD_ROOT}%{_bindir}/
260mv cutter %{name}_cutter
261mv exploder %{name}_exploder
262popd
263%endif
264
265### for wesnothd server
266%if %{with_wesnothd}
267mkdir -p ${RPM_BUILD_ROOT}%{_sbindir}
268mv ${RPM_BUILD_ROOT}%{_bindir}/wesnothd ${RPM_BUILD_ROOT}%{_sbindir}
269mkdir -p ${RPM_BUILD_ROOT}/var/run/wesnothd
270touch ${RPM_BUILD_ROOT}/var/run/wesnothd/socket
271install -Dpm 755 %{SOURCE1} ${RPM_BUILD_ROOT}%{_initrddir}/wesnothd
272install -Dpm 644 %{SOURCE2} ${RPM_BUILD_ROOT}/%{_sysconfdir}/sysconfig/wesnoth
273%endif
274
275
276### remove unpackage files
277%if !%{with_editor}
278%{__rm} -f ${RPM_BUILD_ROOT}%{_datadir}/wesnoth/translations/*/LC_MESSAGES/wesnoth-editor.mo
279%endif
280
281find $RPM_BUILD_ROOT -name ".cvs*" | xargs rm -f
282find $RPM_BUILD_ROOT -name "CVS" | xargs rm -rf
283
284%{__rm} -rf $RPM_BUILD_ROOT/usr/share/doc/wesnoth/
285%{__rm} -f $RPM_BUILD_ROOT/usr/share/icons/wesnoth-icon.png \
286    $RPM_BUILD_ROOT/usr/share/pixmaps/wesnoth-icon.png \
287    $RPM_BUILD_ROOT/usr/share/icons/wesnoth_editor-icon.png
288%{__rm} -f $RPM_BUILD_ROOT/usr/share/applications/wesnoth*.desktop
289%if !%{with_wesnothd}
290%{__rm} -f $RPM_BUILD_ROOT/%{_mandir}/man6/wesnothd.*
291%{__rm} -f $RPM_BUILD_ROOT/%{_mandir}/*/man6/wesnothd.*
292%endif
293
294%find_lang %{name} --all-name
295
296%clean
297%{__rm} -rf ${RPM_BUILD_ROOT}
298
299
300%post
301touch --no-create %{_datadir}/icons/hicolor || :
302if [ -x %{_bindir}/gtk-update-icon-cache ]; then
303   %{_bindir}/gtk-update-icon-cache --quiet %{_datadir}/icons/hicolor || :
304fi
305%{_bindir}/update-desktop-database %{_datadir}/applications || :
306
307%postun
308%{_bindir}/update-desktop-database %{_datadir}/applications || :
309touch --no-create %{_datadir}/icons/hicolor || :
310if [ -x %{_bindir}/gtk-update-icon-cache ]; then
311  %{_bindir}/gtk-update-icon-cache --quiet %{_datadir}/icons/hicolor || :
312fi
313
314%if %{with_wesnothd}
315%pre server
316/usr/sbin/useradd -c "Wesnoth server" -s /sbin/nologin \
317        -r -d /var/run/wesnothd wesnothd 2> /dev/null || :
318
319%post server
320/sbin/chkconfig --add wesnothd
321if [ $1 -gt 1 ]; then
322    %{_initrddir}/wesnothd try-restart >/dev/null || :
323fi
324
325%preun server
326if [ $1 -eq 0 ]; then
327    %{_initrddir}/wesnothd stop >/dev/null 2>&1 || :
328    /sbin/chkconfig --del wesnothd
329fi
330%endif
331
332
333%files -f %{name}.lang
334%defattr(-,root,root)
335%doc COPYING INSTALL README changelog copyright doc/manual/
336%{_bindir}/%{name}
337%{_mandir}/man6/wesnoth.*
338%{_mandir}/*/man6/wesnoth.*
339%{_datadir}/%{name}
340%{_datadir}/applications/vine-wesnoth.desktop
341#%{_datadir}/pixmaps/wesnoth-icon.png
342%{_datadir}/icons/hicolor/*/apps/*.png
343
344%if %{with_editor}
345%files editor
346%defattr(-,root,root)
347%{_bindir}/wesnoth_editor
348%{_mandir}/man6/wesnoth_editor.*
349%{_mandir}/*/man6/wesnoth_editor.*
350%{_datadir}/wesnoth/translations/*/LC_MESSAGES/wesnoth-editor.mo
351%{_datadir}/applications/vine-wesnoth_editor.desktop
352%endif
353
354%if %{with_tools}
355%files tools
356%defattr(-,root,root)
357#%{_bindir}/cutter
358#%{_bindir}/exploder
359%{_bindir}/wesnoth_cutter
360%{_bindir}/wesnoth_exploder
361%endif
362
363%if %{with_campaignd}
364%files campaign-server
365%defattr(-,root,root)
366%{_bindir}/campaignd
367%endif
368
369%if %{with_wesnothd}
370%files server
371%defattr(-,root,root)
372%config %{_initrddir}/wesnothd
373%config(noreplace) %{_sysconfdir}/sysconfig/wesnoth
374#%{_bindir}/wesnothd
375%{_sbindir}/wesnothd
376%{_mandir}/man6/wesnothd.*
377%{_mandir}/*/man6/wesnothd.*
378%attr(0700,wesnothd,wesnothd) %dir /var/run/wesnothd/
379%ghost /var/run/wesnothd/socket
380%endif
381
382
383%changelog
384* Thu Aug 12 2010 IWAI, Masaharu <iwai@alib.jp> 1.8.4-1
385- new upstream release
386- drop Japanese po files version 20100710 (Source12)
387
388* Sat Jul 10 2010 IWAI, Masaharu <iwai@alib.jp> 1.8.3-1
389- new upstream release
390- add Japanese po files version 20100710 (Source12)
391
392* Thu Jun  3 2010 IWAI, Masaharu <iwai@alib.jp> 1.8.2-1
393- new upstream release
394- add required Boost Library version
395
396* Mon May  3 2010 IWAI, Masaharu <iwai@alib.jp> 1.8.1-1
397- new upstream release
398- fix typo for Conflicts tag: wesnoth165
399
400* Fri Apr  2 2010 IWAI, Masaharu <iwai@alib.jp> 1.8.0-2
401- new upstream release
402- running autogen.sh: missing configure script in 1.8 tarball
403
404* Tue Mar 30 2010 IWAI, Masaharu <iwai@alib.jp> 1.8.0-1.svn41885
405- update to 1.8.0+svn41885
406- add Conflicts: wesnoth165
407- without unofficial po files (Source10): unstream merged
408- symbolic link: VL-Gothic-Regular.ttf to wqy-zenhei.ttc
409- add BuildRequires: lua-devel
410- fix changelog: 1.6.5-3
411
412* Mon Mar 29 2010 IWAI, Masaharu <iwai@alib.jp> 1.6.5-3
413- add unofficial Japanese po files
414  - add wesnoth-1.6.5-japanese-po.tar.gz (Source10)
415  - add wesnoth-1.6.5-sotbe-ja.po (Source11)
416  - add Japanese translators patch (Patch10)
417- update Packager: assign iwaim
418
419* Mon Feb 08 2010 Shu KONNO <owa@bg.wakwak.com> 1.6.5-2vl6
420- rebuilt with new toolchain and libboost-1.42.0
421
422* Fri Sep 11 2009 Munehiro Yamamoto <munepi@vinelinux.org> 1.6.5-1
423- new upstream release
424- added BuildRequires:
425  - desktop-file-utils
426  - ImageMagick
427
428* Wed Jul 22 2009 Munehiro Yamamoto <munepi@vinelinux.org> 1.6.4-1
429- new upstream release
430
431* Wed Jul  8 2009 MATSUBAYASHI Kohji <shaolin@vinelinux.org> - 1.6.3-2
432- fix enable-server bits
433  - specify --enable-server=no when with_wesnothd is NOT set)
434  - fix install section
435
436* Fri Jul 03 2009 Munehiro Yamamoto <munepi@cg8.so-net.ne.jp> 1.6.3-1
437- new upstream release
438
439* Sun May 17 2009 Munehiro Yamamoto <munepi@cg8.so-net.ne.jp> 1.6.2-1
440- new upstream release
441
442* Fri May 08 2009 Munehiro Yamamoto <munepi@cg8.so-net.ne.jp> 1.6.1-1
443- new upstream release
444
445* Mon Mar 23 2009 Munehiro Yamamoto <munepi@cg8.so-net.ne.jp> 1.6a-1
446- new upstream release
447- added BuildRequires: libboost-regex
448- added Requires:
449  - libboost-regex
450  - TrueType-vlgothic for vl5
451- dropped BuildRequires: TrueType-sazanami
452- dropped wesnoth-1.2.8-gcc43.patch
453- added configure options:
454  - --disable-dependency-tracking
455  - --with-localedir=%%{_datadir}/locale
456- removed wqy-zenhei.ttc
457  because wqy-zenhei.ttc affected sazanami-gothic.ttf badly
458- added update-desktop-database process in %%post and %%postun
459
460* Sat Jan 10 2009 Munehiro Yamamoto <munepi@cg8.so-net.ne.jp> 1.4.7-1
461- new upstream release
462
463* Sun Nov 16 2008 Munehiro Yamamoto <munepi@cg8.so-net.ne.jp> 1.4.6-1
464- new upstream release
465
466* Sun Nov 02 2008 Munehiro Yamamoto <munepi@cg8.so-net.ne.jp> 1.4.5-1
467- new upstream release
468- fixed License to GPLv2+
469- added BuildRequires: libboost-devel
470- added Requires: libboost-iostreams
471- dropped wesnoth.desktop, wesnoth.png, wesnoth-editor.desktop
472
473- apply wesnoth-1.2.8-gcc43.patch (from Fedora package)
474
475* Tue Oct 14 2008 Shu KONNO <owa@bg.wakwak.com> 1.2.7-1vl5
476- applied new versioning policy, spec in utf-8
477
478* Wed Jan 02 2008 Shu KONNO <owa@bg.wakwak.com> 1.2.7-0vl2
479- rebuilt for VineSeed
480
481* Mon Oct 23 2007 Munehiro Yamamoto <myamamoto@g.math.s.chiba-u.ac.jp> 1.2.7-0vl1
482- new upstream
483 - define with_editor 0, with_tools 0, with_campaignd 0, with_wesnothd 0
484 - drop wesnoth-server package
485 - arrange wesnothd server package files
486   [HELP] please test wesnoth-server, which change with_wesnothd to TRUE
487
488# * Tue Sep 4 2007 Munehiro Yamamoto <myamamoto@g.math.s.chiba-u.ac.jp> 1.2.6-0vl3
489# - provide wesnoth-tools package
490# - drop wesnoth-server package
491# - arrange wesnothd server package files
492#   [HELP] please test wesnoth-server and wesnoth-campaign-server,
493#   which change with_wesnothd and with_campaignd to TRUE
494
495* Mon Sep 3 2007 Munehiro Yamamoto <myamamoto@g.math.s.chiba-u.ac.jp> 1.2.6-0vl2
496- rebuild for VineSeed
497
498* Mon Sep 3 2007 Munehiro Yamamoto <myamamoto@g.math.s.chiba-u.ac.jp> 1.2.6-0vl1
499- initial build for Vine Linux 4.1
500
501* Sun Apr 15 2007 Munehiro Yamamoto <myamamoto@g.math.s.chiba-u.ac.jp> 1.2.3-0vlmp1
502- new upstream for Vine Linux 4.1
503
504* Fri Jun 10 2005 Munehiro Yamamoto <myamamoto@g.math.s.chiba-u.ac.jp> 0.9.2-0vlmp1
505- initial build for Vine Linux 3.2
506
507
508
509# end of file
Note: See TracBrowser for help on using the repository browser.