]>
Commit | Line | Data |
---|---|---|
1 | Summary: The Waf build system | |
2 | Summary(pl.UTF-8): System budowania Waf | |
3 | Name: waf | |
4 | Version: 2.0.27 | |
5 | Release: 1 | |
6 | # note: waf book is on CC-BY-NC-ND (not included in binary package) | |
7 | License: BSD | |
8 | Group: Development/Building | |
9 | Source0: https://waf.io/%{name}-%{version}.tar.bz2 | |
10 | # Source0-md5: c0ab0a79eef9cfff32884f49580516c6 | |
11 | Patch0: %{name}-path.patch | |
12 | URL: https://waf.io/ | |
13 | BuildRequires: python3 >= 1:3 | |
14 | BuildRequires: python3-modules >= 1:3 | |
15 | BuildRequires: rpm-pythonprov | |
16 | BuildRequires: rpmbuild(macros) >= 1.507 | |
17 | Requires: python(abi) = %{py3_ver} | |
18 | BuildArch: noarch | |
19 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) | |
20 | ||
21 | %description | |
22 | Waf is a general-purpose build system which was modelled from Scons. | |
23 | Though it comes last in the arena of the build systems, we believe | |
24 | that Waf is a vastly superior alternative to its competitors | |
25 | (Autotools, Scons, Cmake, Ant, etc) for building software, | |
26 | ||
27 | %description -l pl.UTF-8 | |
28 | Waf to system budowania ogólnego przeznaczenia opracowany na podstawie | |
29 | Scons. Mimo że pojawił się jako ostatni na arenie systemów budowania, | |
30 | autorzy wierzą, że przewyższa alternatywne narzędzia (Autotools, | |
31 | Scons, Cmake, Ant itp.). | |
32 | ||
33 | %prep | |
34 | %setup -q | |
35 | %patch0 -p1 | |
36 | ||
37 | %{__sed} -i -e '1s,/usr/bin/.*python,%{__python3},' waf-light waflib/Context.py waflib/processor.py waflib/extras/javatest.py | |
38 | ||
39 | %build | |
40 | # check waf-light | |
41 | extras= | |
42 | for f in waflib/extras/*.py ; do | |
43 | tool=$(basename "$f" .py) | |
44 | if [ "$tool" != "__init__" ]; then | |
45 | extras="${extras:+$extras,}$tool" | |
46 | fi | |
47 | done | |
48 | ./waf-light --make-waf --strip --tools="$extras" | |
49 | ||
50 | %install | |
51 | rm -rf $RPM_BUILD_ROOT | |
52 | install -d $RPM_BUILD_ROOT%{_datadir}/waf3/waflib/{Tools,extras} | |
53 | ||
54 | cp -p waflib/*.py $RPM_BUILD_ROOT%{_datadir}/waf3/waflib | |
55 | cp -p waflib/Tools/*.py $RPM_BUILD_ROOT%{_datadir}/waf3/waflib/Tools | |
56 | cp -p waflib/extras/*.py $RPM_BUILD_ROOT%{_datadir}/waf3/waflib/extras | |
57 | ||
58 | install -D -p waf-light $RPM_BUILD_ROOT%{_bindir}/waf | |
59 | ||
60 | %py3_comp $RPM_BUILD_ROOT%{_datadir}/waf3/waflib | |
61 | %py3_ocomp $RPM_BUILD_ROOT%{_datadir}/waf3/waflib | |
62 | ||
63 | %clean | |
64 | rm -rf $RPM_BUILD_ROOT | |
65 | ||
66 | %files | |
67 | %defattr(644,root,root,755) | |
68 | %doc ChangeLog README.md | |
69 | %attr(755,root,root) %{_bindir}/waf | |
70 | %{_datadir}/waf3 |