|
|
|
@ -1,10 +1,13 @@
|
|
|
|
|
%if 0%{?fedora}
|
|
|
|
|
%global with_python3 1
|
|
|
|
|
# Turn off the brp-python-bytecompile script
|
|
|
|
|
%global __os_install_post %(echo '%{__os_install_post}' | sed -e 's!/usr/lib[^[:space:]]*/brp-python-bytecompile[[:space:]].*$!!g')
|
|
|
|
|
%{!?python3_version: %global python3_version %(%{__python3} -c "import sys; sys.stdout.write(sys.version[:3])")}
|
|
|
|
|
%endif
|
|
|
|
|
|
|
|
|
|
%if 0%{?with_python3}
|
|
|
|
|
# Turn off the brp-python-bytecompile script
|
|
|
|
|
%global __os_install_post %(echo '%{__os_install_post}' | sed -e 's!/usr/lib[^[:space:]]*/brp-python-bytecompile[[:space:]].*$!!g')
|
|
|
|
|
%endif # with_python3
|
|
|
|
|
|
|
|
|
|
# Enable building without html docs (e.g. in case no recent sphinx is
|
|
|
|
|
# available)
|
|
|
|
|
%global with_docs 1
|
|
|
|
@ -13,8 +16,8 @@
|
|
|
|
|
%undefine prerel
|
|
|
|
|
|
|
|
|
|
Name: waf
|
|
|
|
|
Version: 1.8.22
|
|
|
|
|
Release: %{?prerel:0.}1%{?prerel:.%prerel}%{?dist}.1
|
|
|
|
|
Version: 1.9.1
|
|
|
|
|
Release: %{?prerel:0.}1%{?prerel:.%prerel}%{?dist}
|
|
|
|
|
Summary: A Python-based build system
|
|
|
|
|
Group: Development/Tools
|
|
|
|
|
# The entire source code is BSD apart from pproc.py (taken from Python 2.5)
|
|
|
|
@ -175,6 +178,16 @@ sed -i "1c#! %{__python3}" %{buildroot}%{_bindir}/waf-%{python3_version}
|
|
|
|
|
# remove x-bits from everything going to doc
|
|
|
|
|
find demos utils -type f -exec chmod 0644 {} \;
|
|
|
|
|
|
|
|
|
|
# fix shebang lines in the demos
|
|
|
|
|
mkdir demos_py2 ; cp -a demos demos_py2
|
|
|
|
|
find demos_py2 \( -name '*.py' -o -name 'wscript' -o -name 'wscript_build' \) \
|
|
|
|
|
-exec sed -e '1{/^#!/d}' -e '1i#!%{__python2}' -i {} \;
|
|
|
|
|
%if 0%{?with_python3}
|
|
|
|
|
mkdir demos_py3 ; cp -a demos demos_py3
|
|
|
|
|
find demos_py3 \( -name '*.py' -o -name 'wscript' -o -name 'wscript_build' \) \
|
|
|
|
|
-exec sed -e '1{/^#!/d}' -e '1i#!%{__python3}' -i {} \;
|
|
|
|
|
%endif # with_python3
|
|
|
|
|
|
|
|
|
|
# remove hidden file
|
|
|
|
|
rm -f docs/sphinx/build/html/.buildinfo
|
|
|
|
|
|
|
|
|
@ -186,7 +199,7 @@ rm -f docs/sphinx/build/html/.buildinfo
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
%files
|
|
|
|
|
%doc README ChangeLog demos
|
|
|
|
|
%doc README.md ChangeLog demos_py2/demos
|
|
|
|
|
%{_bindir}/waf
|
|
|
|
|
%{_bindir}/waf-%{python2_version}
|
|
|
|
|
%{_bindir}/waf-2
|
|
|
|
@ -195,7 +208,7 @@ rm -f docs/sphinx/build/html/.buildinfo
|
|
|
|
|
|
|
|
|
|
%if 0%{?with_python3}
|
|
|
|
|
%files -n %{name}-python3
|
|
|
|
|
%doc README ChangeLog demos
|
|
|
|
|
%doc README.md ChangeLog demos_py3/demos
|
|
|
|
|
%{_bindir}/waf-%{python3_version}
|
|
|
|
|
%{_bindir}/waf-3
|
|
|
|
|
%{_datadir}/waf3
|
|
|
|
@ -209,6 +222,10 @@ rm -f docs/sphinx/build/html/.buildinfo
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
%changelog
|
|
|
|
|
* Thu Aug 4 2016 Thomas Moschny <thomas.moschny@gmx.de> - 1.9.1-1
|
|
|
|
|
- Update to 1.9.1.
|
|
|
|
|
- Fix some rpmlint warnings.
|
|
|
|
|
|
|
|
|
|
* Tue Jul 19 2016 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.8.22-1.1
|
|
|
|
|
- https://fedoraproject.org/wiki/Changes/Automatic_Provides_for_Python_RPM_Packages
|
|
|
|
|
|
|
|
|
|