%define modname lxml %define pyver 2.4 %define py_platsitedir %{_libdir}/python%{pyver}/site-packages Name: python%{pyver}-%{modname} URL: http://codespeak.net/lxml/ Summary: A Pythonic binding for the libxml2 and libxslt libraries Version: 2.1.5 Release: %mkrel 1 License: BSD Group: Development/Python Source: http://codespeak.net/lxml/%{modname}-%{version}.tgz BuildRoot: %{_tmppath}/%{name}-%{version}-root Requires: python%{pyver} BuildRequires: libxml2-devel libxslt-devel python%{pyver}-devel %description lxml is a Pythonic binding for the libxml2 and libxslt libraries. It follows the ElementTree API as much as possible, building it on top of the native libxml2 tree. It also extends this API to expose libxml2 and libxslt specific functionality, such as XPath, Relax NG, XML Schema, XSLT, and c14n. %prep %setup -q -n %{modname}-%{version} %build export CFLAGS="$RPM_OPT_FLAGS" python%{pyver} setup.py build export PYTHONPATH="$RPM_BUILD_ROOT%{_libdir}/python%{pyver}/site-packages" %install [ -d %{buildroot} -a "%{buildroot}" != "" ] && rm -rf %{buildroot} python%{pyver} setup.py install --root=$RPM_BUILD_ROOT %clean [ -d %{buildroot} -a "%{buildroot}" != "" ] && rm -rf %{buildroot} %files %defattr(-,root,root) %doc doc CHANGES.txt CREDITS.txt LICENSES.txt README.txt TODO.txt %py_platsitedir/lxml* %changelog * Mon Jan 12 2009 Kazuhiko Shiozaki 2.1.5-1nxd2009.0 - new upstream release (bug fixes). * Fri Dec 26 2008 Kazuhiko Shiozaki 2.1.3-2nxd2009.0 - requires python2.4 instead of python * Mon Dec 8 2008 Kazuhiko Shiozaki 2.1.3-1nxd2009.0 - initial package