]>
Commit | Line | Data |
---|---|---|
7b21aad0 | 1 | # |
2 | # TODO: - use arch dependend compilers | |
3 | # - check licenses | |
d49dee95 | 4 | # - try to make it runnable by non-privileged users (sth wrong with boost?) |
5 | # - fix problem with font finding | |
7b21aad0 | 6 | # |
6e4e3b12 | 7 | %define svn_ver r10803 |
7b21aad0 | 8 | Summary: Free, Open-Source, cross-platform RTS game of ancient warfare |
9 | Name: 0ad | |
10 | Version: %{svn_ver} | |
0cf93a9e | 11 | Release: 0.alpha.1 |
7b21aad0 | 12 | License: GPL v2+ |
13 | Group: X11/Applications/Games | |
7245afcd | 14 | Source0: http://releases.wildfiregames.com/%{name}-%{version}-alpha-unix-build.tar.xz |
6e4e3b12 | 15 | # Source0-md5: 92ac750c433a8aea4db602019b27a274 |
7b21aad0 | 16 | URL: http://wildfiregames.com/0ad/ |
bfedb3d9 | 17 | BuildRequires: DevIL-devel |
18 | BuildRequires: OpenAL-devel | |
19 | BuildRequires: OpenGL-devel | |
20 | BuildRequires: SDL-devel | |
7b21aad0 | 21 | BuildRequires: boost-devel |
bfedb3d9 | 22 | BuildRequires: cmake |
7d822f0e | 23 | BuildRequires: curl-devel |
1cae58d8 | 24 | BuildRequires: enet-devel >= 1.2.0 |
7d822f0e | 25 | BuildRequires: fam-devel |
bfedb3d9 | 26 | BuildRequires: libogg-devel |
27 | BuildRequires: libpng-devel | |
28 | BuildRequires: libvorbis-devel | |
29 | BuildRequires: libxml2-devel | |
7d822f0e | 30 | BuildRequires: nasm |
ef4556af | 31 | BuildRequires: nvidia-texture-tools-devel |
7245afcd | 32 | BuildRequires: perl-base |
33 | BuildRequires: pkgconfig | |
34 | BuildRequires: python | |
35 | BuildRequires: python-modules | |
7b21aad0 | 36 | BuildRequires: sed >= 4.0 |
2ef47886 | 37 | BuildRequires: wxGTK2-unicode-gl-devel |
7245afcd | 38 | BuildRequires: zip |
bfedb3d9 | 39 | BuildRequires: zlib-devel |
7b21aad0 | 40 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
41 | ||
42 | %description | |
43 | 0 A.D. (pronounced "zero ey-dee") is a free, open-source, | |
44 | cross-platform real-time strategy (RTS) game of ancient warfare. In | |
45 | short, it is a historically-based war/economy game that allows players | |
46 | to relive or rewrite the history of Western civilizations, focusing on | |
47 | the years between 500 B.C. and 500 A.D. The project is highly | |
48 | ambitious, involving state-of-the-art 3D graphics, detailed artwork, | |
49 | sound, and a flexible and powerful custom-built game engine. | |
50 | ||
51 | %prep | |
7245afcd | 52 | %setup -q -n %{name}-%{version}-alpha |
7b21aad0 | 53 | |
54 | # force link with libboost_*.so not libboost_*-mt.so | |
0e1a6fce | 55 | %{__sed} -i 's,-mt,,g' build/premake/extern_libs4.lua |
7b21aad0 | 56 | |
57 | # use wx-gtk2-unicode-config instead of wx-config | |
def565f8 | 58 | %{__sed} -i 's,wx-config,wx-gtk2-unicode-config,' build/premake/extern_libs4.lua |
7b21aad0 | 59 | |
60 | %build | |
61 | export CFLAGS="%{rpmcflags}" | |
62 | export CPPFLAGS="%{rpmcxxflags}" | |
63 | cd build/workspaces | |
64 | ./update-workspaces.sh \ | |
ba987ea4 | 65 | --with-system-enet \ |
66 | --with-system-nvtt \ | |
67 | --with-system-mozjs185 | |
df8c5c6d | 68 | # --verbose \ |
ba987ea4 | 69 | # --bindir %{_bindir} \ |
70 | # --datadir %{_datadir}/%{name} \ | |
71 | # --libdir %{_libdir}/%{name} | |
7b21aad0 | 72 | |
73 | cd gcc | |
74 | %{__make} \ | |
75 | CONFIG=Release | |
76 | ||
77 | %install | |
78 | rm -rf $RPM_BUILD_ROOT | |
79 | install -d $RPM_BUILD_ROOT{%{_bindir},%{_libdir}/%{name},%{_desktopdir},%{_pixmapsdir}} | |
80 | ||
81 | # binaries | |
82 | cp -a build/resources/0ad.sh $RPM_BUILD_ROOT%{_bindir}/0ad | |
83 | cp -a binaries/system/pyrogenesis $RPM_BUILD_ROOT%{_bindir} | |
84 | ||
85 | # libraries | |
86 | cp -a binaries/system/*.so $RPM_BUILD_ROOT%{_libdir}/%{name} | |
e36ec85e | 87 | cp -a binaries/system/*release.so.*.* $RPM_BUILD_ROOT%{_libdir}/%{name} |
7b21aad0 | 88 | |
89 | # menu icon | |
90 | cp -a build/resources/0ad.desktop $RPM_BUILD_ROOT%{_desktopdir} | |
91 | cp -a build/resources/0ad.png $RPM_BUILD_ROOT%{_pixmapsdir} | |
92 | ||
93 | %clean | |
94 | rm -rf $RPM_BUILD_ROOT | |
95 | ||
96 | %files | |
97 | %defattr(644,root,root,755) | |
98 | %doc README.txt | |
99 | %attr(755,root,root) %{_bindir}/0ad | |
100 | %attr(755,root,root) %{_bindir}/pyrogenesis | |
101 | %dir %{_libdir}/0ad | |
102 | %{_libdir}/0ad/*.so | |
e36ec85e | 103 | %{_libdir}/0ad/*.so.*.* |
7b21aad0 | 104 | %{_desktopdir}/0ad.desktop |
105 | %{_pixmapsdir}/0ad.png |