]>
Commit | Line | Data |
---|---|---|
f76541bb ER |
1 | %define _ver %(echo %{version} | tr . _) |
2 | Summary: Enemy Territory - ETpro | |
fe0eb62c | 3 | Summary(pl.UTF-8): Enemy Territory (Terytorium wroga) ETpro |
f76541bb | 4 | Name: etpro |
e609eca1 ER |
5 | Version: 3.2.6 |
6 | Release: 1 | |
f76541bb ER |
7 | License: as-is |
8 | Group: Applications/Games | |
9 | Source0: http://bani.anime.net/etpro/etpro-%{_ver}.zip | |
e609eca1 | 10 | # Source0-md5: 5c2c8f56731a9ad6774e624f4e793e22 |
f76541bb ER |
11 | Source1: %{name}.desktop |
12 | URL: http://bani.anime.net/etpro/ | |
fb0177fe | 13 | BuildRequires: unzip |
f76541bb ER |
14 | Requires: et |
15 | Requires: et-data | |
24e47a89 | 16 | ExclusiveArch: %{ix86} |
f76541bb ER |
17 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
18 | ||
19 | %define no_install_post_strip 1 | |
20 | %define no_install_post_chrpath 1 | |
21 | %define _gamelibdir %{_libdir}/games/et | |
22 | %define _gamedatadir %{_datadir}/games/et | |
23 | ||
24 | %description | |
24e47a89 JB |
25 | Enemy Territory - ETpro. |
26 | ||
6f249ac1 | 27 | %description -l pl.UTF-8 |
24e47a89 | 28 | Enemy Territory (Terytorium wroga) ETpro. |
f76541bb ER |
29 | |
30 | %prep | |
31 | %setup -q -n %{name} | |
32 | ||
f76541bb ER |
33 | %install |
34 | rm -rf $RPM_BUILD_ROOT | |
35 | install -d $RPM_BUILD_ROOT{%{_bindir},%{_desktopdir},{%{_gamelibdir},%{_gamedatadir}}/etpro} | |
36 | ||
0fc90b32 | 37 | cat << 'EOF' > $RPM_BUILD_ROOT%{_bindir}/%{name} |
f76541bb ER |
38 | #!/bin/sh |
39 | # Needed to make symlinks/shortcuts work. | |
40 | # the binaries must run with correct working directory | |
41 | cd %{_gamelibdir} | |
0fc90b32 | 42 | exec ./et +set fs_game etpro "$@" |
f76541bb ER |
43 | EOF |
44 | ||
45 | cp -a animations configs etpromapscripts maps $RPM_BUILD_ROOT%{_gamelibdir}/etpro | |
46 | ||
47 | install *.pk3 $RPM_BUILD_ROOT%{_gamedatadir}/etpro | |
48 | ln -s ../../../../share/games/et/etpro/etpro-%{_ver}.pk3 $RPM_BUILD_ROOT%{_gamelibdir}/etpro | |
49 | ||
50 | install etpro_cheats.dat example.cfg $RPM_BUILD_ROOT%{_gamelibdir}/etpro | |
51 | install *.so $RPM_BUILD_ROOT%{_gamelibdir}/etpro | |
52 | ||
53 | install %{SOURCE1} $RPM_BUILD_ROOT%{_desktopdir} | |
54 | ||
55 | %clean | |
56 | rm -rf $RPM_BUILD_ROOT | |
57 | ||
58 | %files | |
59 | %defattr(644,root,root,755) | |
60 | %attr(755,root,root) %{_bindir}/* | |
61 | %dir %{_gamelibdir}/etpro | |
62 | %attr(755,root,root) %{_gamelibdir}/etpro/*.so | |
63 | %{_gamelibdir}/etpro/etpro_cheats.dat | |
64 | %{_gamelibdir}/etpro/animations | |
65 | %{_gamelibdir}/etpro/configs | |
66 | %{_gamelibdir}/etpro/etpromapscripts | |
67 | %{_gamelibdir}/etpro/maps | |
68 | %{_gamelibdir}/etpro/*.cfg | |
69 | %{_gamelibdir}/etpro/*.pk3 | |
70 | %dir %{_gamedatadir}/etpro | |
71 | %{_gamedatadir}/etpro/*.pk3 | |
72 | %{_desktopdir}/%{name}.desktop |