You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
waf/waf.spec

118 lines
3.4 KiB

Name: waf
Version: 1.4.2
Release: 2%{?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)
License: BSD and Python
URL: http://code.google.com/p/waf/
Source0: http://waf.googlecode.com/files/waf-%{version}.tar.bz2
# use _datadir instead of /usr/lib
Patch0: waf-1.4.2-libdir.patch
Patch1: waf-1.4.2-fcntl.patch
BuildRoot: %(mktemp -ud %{_tmppath}/%{name}-%{version}-%{release}-XXXXXX)
BuildArch: noarch
BuildRequires: python-devel
# Seems like automatic ABI dependency is not detected since the files are
# going to a non-standard location
Requires: python-abi %(%{__python} -c "import sys ; print \"=\", sys.version[:3]")
# the demo suite contains a perl module, which draws in unwanted
# provides and requires
%define __perl_provides %{nil}
%define __perl_requires %{nil}
%description
Waf is a Python-based framework for configuring, compiling and
installing applications. It is a replacement for other tools such as
Autotools, Scons, CMake or Ant.
%prep
%setup -q
%patch0 -p1 -b .libdir
%patch1 -p1 -b .fcntl
%build
./waf-light --make-waf --strip
%install
rm -rf $RPM_BUILD_ROOT
# the install target wants an acknowledgement
echo y | ./waf install --prefix=%{_prefix} --destdir=$RPM_BUILD_ROOT
# remove shebangs from all scripts in wafadmin
find $RPM_BUILD_ROOT%{_datadir}/waf/wafadmin -name '*.py' \
-exec sed -i '1{/^#!/d}' {} \;
# fix waf script shebang line
sed -i "1c#! /usr/bin/python" $RPM_BUILD_ROOT%{_bindir}/waf
# fix EOL
sed -i 's|\r$||g' utils/amtool.py
# remove x-bits from everything going to doc
find demos utils -type f -exec chmod 0644 {} \;
# remove zero-length files
rm demos/gnome/src/hello.h
rm demos/simple_scenarios/local_tool/uh.coin
%clean
rm -rf $RPM_BUILD_ROOT
%files
%defattr(-,root,root,-)
%doc README TODO ChangeLog demos doc/waf.pdf utils
%{_bindir}/waf
%{_datadir}/waf
%changelog
* Mon May 26 2008 Thomas Moschny <thomas.moschny@gmx.de> - 1.4.2-2
- Patch: stdout might not be a terminal.
* Sat May 17 2008 Thomas Moschny <thomas.moschny@gmx.de> - 1.4.2-1
- Update to 1.4.2.
- Remove shebang lines from files in wafadmin after installation, not
before, otherwise install will re-add them.
* Sun May 4 2008 Thomas Moschny <thomas.moschny@gmx.de> - 1.4.1-1
- Update to upstream version 1.4.1.
* Sat Apr 19 2008 Thomas Moschny <thomas.moschny@gmx.de> - 1.4.0-1
- Update to upstream version 1.4.0.
* Wed Apr 9 2008 Thomas Moschny <thomas.moschny@gmx.de> - 1.3.2-6
- Upstream patch to fix latex dependency scanning: trunk rev 2340.
* Sun Feb 10 2008 Thomas Moschny <thomas.moschny@gmx.de> - 1.3.2-5
- Update to 1.3.2.
- Remove version and revision information from path to waf cache.
* Fri Feb 1 2008 Michel Salim <michel.sylvan@gmail.com> - 1.3.1-4
- Upstream patch to fix check_tool('gnome'): trunk rev 2219
* Mon Jan 28 2008 Michel Salim <michel.sylvan@gmail.com> - 1.3.1-3
- Fix python-abi requirement so it can be parsed before python is installed
- rpmlint tidying-up
* Fri Jan 25 2008 Michel Salim <michel.sylvan@gmail.com> - 1.3.1-2
- Merge in changes from Thomas Mochny <thomas.moschny@gmx.de>:
* WAF cache moved from /usr/lib to /usr/share
* Remove shebangs from scripts not meant from users, rather than
making them executable
* Include tools and demos
* Sun Jan 20 2008 Michel Salim <michel.sylvan@gmail.com> - 1.3.1-1
- Initial Fedora package