[874] | 1 | # Note: this .spec is borrowed from http://pkgs.fedoraproject.org/cgit/rpms/python-lxml.git/tree/python-lxml.spec
|
---|
| 2 | # and adapted to our needs
|
---|
[613] | 3 |
|
---|
[874] | 4 | %global pypi_name lxml
|
---|
[613] | 5 |
|
---|
[874] | 6 | # remove the comment below, when we have python3 support
|
---|
| 7 | #global with_python3 1
|
---|
[613] | 8 |
|
---|
[874] | 9 |
|
---|
[613] | 10 | %{!?python_sitearch: %global python_sitearch %(%{__python} -c "from distutils.sysconfig import get_python_lib; print get_python_lib(1)")}
|
---|
| 11 |
|
---|
[874] | 12 | Name: python-%{pypi_name}
|
---|
| 13 | Version: 3.6.4
|
---|
[910] | 14 | Release: 2%{?dist}
|
---|
[874] | 15 | Summary: Powerful and Pythonic XML processing library combining libxml2/libxslt with the ElementTree API
|
---|
[613] | 16 |
|
---|
| 17 | Group: Development/Libraries
|
---|
| 18 | License: BSD
|
---|
| 19 | URL: http://lxml.de
|
---|
[874] | 20 | Vendor: bww bitwise works GmbH
|
---|
| 21 | Source0: https://files.pythonhosted.org/packages/source/l/%{pypi_name}/%{pypi_name}-%{version}.tar.gz
|
---|
[613] | 22 |
|
---|
[874] | 23 | BuildRequires: libxml2-devel
|
---|
[613] | 24 | BuildRequires: libxslt-devel
|
---|
| 25 |
|
---|
[874] | 26 | BuildRequires: python2-devel
|
---|
[613] | 27 |
|
---|
| 28 | %if 0%{?with_python3}
|
---|
| 29 | BuildRequires: python3-devel
|
---|
| 30 | BuildRequires: python3-setuptools
|
---|
| 31 | %endif
|
---|
| 32 |
|
---|
| 33 | %description
|
---|
[874] | 34 | lxml is a Pythonic, mature binding for the libxml2 and libxslt libraries. It
|
---|
| 35 | provides safe and convenient access to these libraries using the ElementTree It
|
---|
| 36 | extends the ElementTree API significantly to offer support for XPath, RelaxNG,
|
---|
| 37 | XML Schema, XSLT, C14N and much more.To contact the project, go to the project
|
---|
| 38 | home page < or see our bug tracker at case you want to use the current ...
|
---|
[613] | 39 |
|
---|
[874] | 40 | %package -n python2-%{pypi_name}
|
---|
| 41 | Summary: Powerful and Pythonic XML processing library combining libxml2/libxslt with the ElementTree API
|
---|
| 42 | #Requires: python-cssselect
|
---|
| 43 | #Requires: python-html5lib
|
---|
| 44 | #Requires: python-beautifulsoup4
|
---|
| 45 | Provides: python-%{pypi_name}
|
---|
[613] | 46 |
|
---|
[874] | 47 | %description -n python2-%{pypi_name}
|
---|
| 48 | lxml is a Pythonic, mature binding for the libxml2 and libxslt libraries. It
|
---|
| 49 | provides safe and convenient access to these libraries using the ElementTree It
|
---|
| 50 | extends the ElementTree API significantly to offer support for XPath, RelaxNG,
|
---|
| 51 | XML Schema, XSLT, C14N and much more.To contact the project, go to the project
|
---|
| 52 | home page < or see our bug tracker at case you want to use the current ...
|
---|
[613] | 53 |
|
---|
| 54 | %if 0%{?with_python3}
|
---|
[874] | 55 | %package -n python3-lxml
|
---|
| 56 | Summary: Powerful and Pythonic XML processing library combining libxml2/libxslt with the ElementTree API
|
---|
[613] | 57 | Requires: python3-cssselect
|
---|
[874] | 58 | Requires: python3-html5lib
|
---|
| 59 | Requires: python3-beautifulsoup4
|
---|
| 60 | %{?python_provide:%python_provide python3-%{pypi_name}}
|
---|
[613] | 61 |
|
---|
[874] | 62 | %description -n python3-%{pypi_name}
|
---|
| 63 | lxml is a Pythonic, mature binding for the libxml2 and libxslt libraries. It
|
---|
| 64 | provides safe and convenient access to these libraries using the ElementTree It
|
---|
| 65 | extends the ElementTree API significantly to offer support for XPath, RelaxNG,
|
---|
| 66 | XML Schema, XSLT, C14N and much more.To contact the project, go to the project
|
---|
| 67 | home page < or see our bug tracker at case you want to use the current ...
|
---|
[613] | 68 | %endif
|
---|
| 69 |
|
---|
| 70 | %prep
|
---|
| 71 | %setup -q -n lxml-%{version}
|
---|
| 72 |
|
---|
| 73 | %build
|
---|
| 74 | CFLAGS="%{optflags}" %{__python} setup.py build
|
---|
| 75 |
|
---|
| 76 | %if 0%{?with_python3}
|
---|
[874] | 77 | %py3_build
|
---|
[613] | 78 | %endif
|
---|
| 79 |
|
---|
| 80 | %install
|
---|
| 81 | %if 0%{?with_python3}
|
---|
[874] | 82 | %py3_install
|
---|
[613] | 83 | %endif
|
---|
[910] | 84 | %{__python} setup.py install --skip-build --no-compile --root %{buildroot}
|
---|
[613] | 85 |
|
---|
[910] | 86 |
|
---|
[613] | 87 | %check
|
---|
| 88 | # @todo enable once we got python-unittest
|
---|
[874] | 89 | #{__python2} setup.py test
|
---|
[613] | 90 |
|
---|
| 91 | %if 0%{?with_python3}
|
---|
[874] | 92 | %{__python3} setup.py test
|
---|
[613] | 93 | %endif
|
---|
| 94 |
|
---|
| 95 |
|
---|
[874] | 96 | %files -n python2-%{pypi_name}
|
---|
[613] | 97 | %{!?_licensedir:%global license %%doc}
|
---|
[874] | 98 | %license doc/licenses/ZopePublicLicense.txt LICENSES.txt
|
---|
| 99 | %doc README.rst src/lxml/isoschematron/resources/xsl/iso-schematron-xslt1/readme.txt
|
---|
| 100 | %{python_sitearch}/%{pypi_name}
|
---|
| 101 | %{python_sitearch}/%{pypi_name}-%{version}-py?.?.egg-info
|
---|
[613] | 102 |
|
---|
| 103 | %if 0%{?with_python3}
|
---|
[874] | 104 | %files -n python3-%{pypi_name}
|
---|
| 105 | %license doc/licenses/ZopePublicLicense.txt LICENSES.txt
|
---|
| 106 | %doc README.rst src/lxml/isoschematron/resources/xsl/iso-schematron-xslt1/readme.txt
|
---|
| 107 | %{python3_sitearch}/%{pypi_name}
|
---|
| 108 | %{python3_sitearch}/%{pypi_name}-%{version}-py?.?.egg-info
|
---|
[613] | 109 | %endif
|
---|
| 110 |
|
---|
| 111 | %changelog
|
---|
[910] | 112 | * Fri Nov 25 2016 Silvan Scherrer <silvan.scherrer@aroa.ch> 3.6.4-2
|
---|
| 113 | - small spec cleanup
|
---|
| 114 | - rebuilt with latest libxslt and libxml2
|
---|
| 115 |
|
---|
[874] | 116 | * Wed Oct 26 2016 Silvan Scherrer <silvan.scherrer@aroa.ch> 3.6.4-1
|
---|
| 117 | - Update package to version 3.6.4.
|
---|
| 118 |
|
---|
| 119 | * Sat Dec 12 2015 Dmitriy Kuminov <coding@dmik.org> 3.5.0-1
|
---|
[613] | 120 | - Initial package for version 3.5.0.
|
---|