%define scl rh-python36 %{?scl:%scl_package %{name}} %{!?scl:%global pkg_name %{name}} %define name lxml %define version 4.4.2 %define unmangled_version 4.4.2 %define unmangled_version 4.4.2 %define release 1 Summary: Powerful and Pythonic XML processing library combining libxml2/libxslt with the ElementTree API. %{?scl:Requires: %{scl}-runtime} %{?scl:BuildRequires: %{scl}-runtime} Name: %{?scl_prefix}lxml Version: %{version} Release: %{release} Source0: lxml-%{unmangled_version}.tar.gz License: BSD Group: Development/Libraries BuildRoot: %{_tmppath}/lxml-%{version}-%{release}-buildroot Prefix: %{_prefix} Vendor: lxml dev team Packager: Martin Juhl Url: http://lxml.de/ %description lxml is a Pythonic, mature binding for the libxml2 and libxslt libraries. It provides safe and convenient access to these libraries using the ElementTree API. It extends the ElementTree API significantly to offer support for XPath, RelaxNG, XML Schema, XSLT, C14N and much more. To contact the project, go to the `project home page `_ or see our bug tracker at https://launchpad.net/lxml In case you want to use the current in-development version of lxml, you can get it from the github repository at https://github.com/lxml/lxml . Note that this requires Cython to build the sources, see the build instructions on the project home page. To the same end, running ``easy_install lxml==dev`` will install lxml from https://github.com/lxml/lxml/tarball/master#egg=lxml-dev if you have an appropriate version of Cython installed. After an official release of a new stable series, bug fixes may become available at https://github.com/lxml/lxml/tree/lxml-4.1 . Running ``easy_install lxml==4.1bugfix`` will install the unreleased branch state from https://github.com/lxml/lxml/tarball/lxml-4.1#egg=lxml-4.1bugfix as soon as a maintenance branch has been established. Note that this requires Cython to be installed at an appropriate version for the build. 4.1.1 (2017-11-04) ================== * Rebuild with Cython 0.27.3 to improve support for Py3.7. %prep %{?scl:scl enable %{scl} - << \EOF} set -ex %setup -n lxml-%{unmangled_version} -n lxml-%{unmangled_version} %{?scl:EOF} %build %{?scl:scl enable %{scl} - << \EOF} set -ex env CFLAGS="$RPM_OPT_FLAGS" python3 setup.py build %{?scl:EOF} %install %{?scl:scl enable %{scl} - << \EOF} set -ex python3 setup.py install --single-version-externally-managed -O1 --root=$RPM_BUILD_ROOT --record=INSTALLED_FILES %{?scl:EOF} %clean %{?scl:scl enable %{scl} - << \EOF} set -ex rm -rf $RPM_BUILD_ROOT %{?scl:EOF} %files -f INSTALLED_FILES %defattr(-,root,root)