| 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
|
|---|
| 3 |
|
|---|
| 4 | %global pypi_name lxml
|
|---|
| 5 |
|
|---|
| 6 | # remove the comment below, when we have python3 support
|
|---|
| 7 | #global with_python3 1
|
|---|
| 8 |
|
|---|
| 9 |
|
|---|
| 10 | %{!?python_sitearch: %global python_sitearch %(%{__python} -c "from distutils.sysconfig import get_python_lib; print get_python_lib(1)")}
|
|---|
| 11 |
|
|---|
| 12 | Name: python-%{pypi_name}
|
|---|
| 13 | Version: 3.6.4
|
|---|
| 14 | Release: 2%{?dist}
|
|---|
| 15 | Summary: Powerful and Pythonic XML processing library combining libxml2/libxslt with the ElementTree API
|
|---|
| 16 |
|
|---|
| 17 | Group: Development/Libraries
|
|---|
| 18 | License: BSD
|
|---|
| 19 | URL: http://lxml.de
|
|---|
| 20 | Vendor: bww bitwise works GmbH
|
|---|
| 21 | Source0: https://files.pythonhosted.org/packages/source/l/%{pypi_name}/%{pypi_name}-%{version}.tar.gz
|
|---|
| 22 |
|
|---|
| 23 | BuildRequires: libxml2-devel
|
|---|
| 24 | BuildRequires: libxslt-devel
|
|---|
| 25 |
|
|---|
| 26 | BuildRequires: python2-devel
|
|---|
| 27 |
|
|---|
| 28 | %if 0%{?with_python3}
|
|---|
| 29 | BuildRequires: python3-devel
|
|---|
| 30 | BuildRequires: python3-setuptools
|
|---|
| 31 | %endif
|
|---|
| 32 |
|
|---|
| 33 | %description
|
|---|
| 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 ...
|
|---|
| 39 |
|
|---|
| 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}
|
|---|
| 46 |
|
|---|
| 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 ...
|
|---|
| 53 |
|
|---|
| 54 | %if 0%{?with_python3}
|
|---|
| 55 | %package -n python3-lxml
|
|---|
| 56 | Summary: Powerful and Pythonic XML processing library combining libxml2/libxslt with the ElementTree API
|
|---|
| 57 | Requires: python3-cssselect
|
|---|
| 58 | Requires: python3-html5lib
|
|---|
| 59 | Requires: python3-beautifulsoup4
|
|---|
| 60 | %{?python_provide:%python_provide python3-%{pypi_name}}
|
|---|
| 61 |
|
|---|
| 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 ...
|
|---|
| 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}
|
|---|
| 77 | %py3_build
|
|---|
| 78 | %endif
|
|---|
| 79 |
|
|---|
| 80 | %install
|
|---|
| 81 | %if 0%{?with_python3}
|
|---|
| 82 | %py3_install
|
|---|
| 83 | %endif
|
|---|
| 84 | %{__python} setup.py install --skip-build --no-compile --root %{buildroot}
|
|---|
| 85 |
|
|---|
| 86 |
|
|---|
| 87 | %check
|
|---|
| 88 | # @todo enable once we got python-unittest
|
|---|
| 89 | #{__python2} setup.py test
|
|---|
| 90 |
|
|---|
| 91 | %if 0%{?with_python3}
|
|---|
| 92 | %{__python3} setup.py test
|
|---|
| 93 | %endif
|
|---|
| 94 |
|
|---|
| 95 |
|
|---|
| 96 | %files -n python2-%{pypi_name}
|
|---|
| 97 | %{!?_licensedir:%global license %%doc}
|
|---|
| 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
|
|---|
| 102 |
|
|---|
| 103 | %if 0%{?with_python3}
|
|---|
| 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
|
|---|
| 109 | %endif
|
|---|
| 110 |
|
|---|
| 111 | %changelog
|
|---|
| 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 |
|
|---|
| 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
|
|---|
| 120 | - Initial package for version 3.5.0.
|
|---|