2022-11-29 01:31:14 +00:00
|
|
|
%global __python3 /usr/bin/python3.11
|
|
|
|
%global python3_pkgversion 3.11
|
|
|
|
|
|
|
|
Name: python%{python3_pkgversion}-lxml
|
2022-11-29 01:27:51 +00:00
|
|
|
Version: 4.9.2
|
2023-07-14 10:34:08 +00:00
|
|
|
Release: 4%{?dist}
|
2022-11-29 01:27:51 +00:00
|
|
|
Summary: XML processing library combining libxml2/libxslt with the ElementTree API
|
|
|
|
|
|
|
|
# The lxml project is licensed under BSD-3-Clause
|
|
|
|
# Some code is derived from ElementTree and cElementTree
|
|
|
|
# thus using the MIT-CMU elementtree license
|
|
|
|
# .xsl schematron files are under the MIT license
|
2022-11-29 01:31:14 +00:00
|
|
|
License: BSD and MIT
|
2022-11-29 01:27:51 +00:00
|
|
|
URL: https://github.com/lxml/lxml
|
2023-07-14 10:34:08 +00:00
|
|
|
|
2023-02-16 04:24:25 +00:00
|
|
|
# We use the get-lxml-source.sh script to generate the tarball
|
2023-07-14 10:34:08 +00:00
|
|
|
# without the isoschematron RNG validation file under a problematic license.
|
2023-02-16 04:24:25 +00:00
|
|
|
# See: https://gitlab.com/fedora/legal/fedora-license-data/-/issues/154
|
2023-08-22 10:56:59 +00:00
|
|
|
Source0: lxml-%{version}-no-isoschematron-rng.tar.gz
|
|
|
|
Source1: get-lxml-source.sh
|
2022-11-29 01:27:51 +00:00
|
|
|
|
2023-07-14 10:34:08 +00:00
|
|
|
# Make the validation of ISO-Schematron files optional in lxml,
|
|
|
|
# depending on the availability of the RNG validation file
|
|
|
|
# Rebased from https://github.com/lxml/lxml/commit/4bfab2c821961fb4c5ed8a04e329778c9b09a1df
|
|
|
|
# Will be included in lxml 5.0
|
|
|
|
Patch: Make-the-validation-of-ISO-Schematron-files-optional.patch
|
|
|
|
# Skip test_isoschematron.test_schematron_invalid_schema_empty without the RNG file
|
|
|
|
Patch: https://github.com/lxml/lxml/pull/380.patch
|
|
|
|
|
2022-11-29 01:27:51 +00:00
|
|
|
BuildRequires: gcc
|
|
|
|
BuildRequires: libxml2-devel
|
|
|
|
BuildRequires: libxslt-devel
|
|
|
|
|
2022-11-29 01:31:14 +00:00
|
|
|
BuildRequires: python%{python3_pkgversion}-devel
|
|
|
|
BuildRequires: python%{python3_pkgversion}-rpm-macros
|
|
|
|
BuildRequires: python%{python3_pkgversion}-setuptools
|
|
|
|
BuildRequires: python%{python3_pkgversion}-Cython
|
|
|
|
|
2022-11-29 01:27:51 +00:00
|
|
|
%global _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 It\
|
|
|
|
extends the ElementTree API significantly to offer support for XPath, RelaxNG,\
|
|
|
|
XML Schema, XSLT, C14N and much more.
|
|
|
|
|
|
|
|
%description %{_description}
|
|
|
|
|
|
|
|
%prep
|
|
|
|
%autosetup -n lxml-%{version} -p1
|
|
|
|
|
|
|
|
# Remove pregenerated Cython C sources
|
|
|
|
# We need to do this after %%pyproject_buildrequires because setup.py errors
|
|
|
|
# without Cython and without the .c files.
|
|
|
|
find -type f -name '*.c' -print -delete >&2
|
|
|
|
|
|
|
|
%build
|
2022-11-29 01:31:14 +00:00
|
|
|
env WITH_CYTHON=true %py3_build
|
2022-11-29 01:27:51 +00:00
|
|
|
|
|
|
|
%install
|
2022-11-29 01:31:14 +00:00
|
|
|
%py3_install
|
2022-11-29 01:27:51 +00:00
|
|
|
|
|
|
|
%check
|
|
|
|
# The tests assume inplace build, so we copy the built library to source-dir.
|
|
|
|
# If not done that, Python can either import the tests or the extension modules, but not both.
|
|
|
|
cp -a build/lib.%{python3_platform}-*/* src/
|
|
|
|
# The options are: verbose, unit, functional
|
|
|
|
%{python3} test.py -vuf
|
|
|
|
|
2022-11-29 01:31:14 +00:00
|
|
|
%files -n python%{python3_pkgversion}-lxml
|
2022-11-29 01:27:51 +00:00
|
|
|
%license doc/licenses/BSD.txt doc/licenses/elementtree.txt
|
2023-02-16 04:24:25 +00:00
|
|
|
%doc README.rst
|
2022-11-29 01:31:14 +00:00
|
|
|
%{python3_sitearch}/lxml/
|
|
|
|
%{python3_sitearch}/lxml-*.egg-info/
|
2022-11-29 01:27:51 +00:00
|
|
|
|
|
|
|
%changelog
|
2023-07-14 10:34:08 +00:00
|
|
|
* Tue Aug 15 2023 Tomas Orsava <torsava@redhat.com> - 4.9.2-4
|
|
|
|
- Bring back the isoschematron submodule,
|
|
|
|
but without the validation of the schema file itself
|
|
|
|
- Resolves: RHEL-5570
|
|
|
|
|
2023-02-16 04:24:25 +00:00
|
|
|
* Thu Feb 16 2023 Charalampos Stratakis <cstratak@redhat.com> - 4.9.2-3
|
|
|
|
- Remove the isoschematron submodule
|
|
|
|
|
2023-02-11 12:30:57 +00:00
|
|
|
* Fri Feb 10 2023 Charalampos Stratakis <cstratak@redhat.com> - 4.9.2-2
|
|
|
|
- Remove the extras subpackages
|
|
|
|
|
2022-11-29 01:31:14 +00:00
|
|
|
* Mon Nov 14 2022 Charalampos Stratakis <cstratak@redhat.com> - 4.9.2-1
|
2022-11-29 01:27:51 +00:00
|
|
|
- Initial package
|
2022-11-29 01:31:14 +00:00
|
|
|
- Fedora contributions by:
|
|
|
|
Alexander Todorov <atodorov@redhat.com>
|
|
|
|
Bill Nottingham <notting@fedoraproject.org>
|
|
|
|
Charalampos Stratakis <cstratak@redhat.com>
|
|
|
|
Dan Horák <dan@danny.cz>
|
|
|
|
David Malcolm <dmalcolm@redhat.com>
|
|
|
|
Dennis Gilmore <dennis@ausil.us>
|
|
|
|
Fabio Alessandro Locati <fale@redhat.com>
|
|
|
|
Igor Raits <ignatenkobrain@fedoraproject.org>
|
|
|
|
Jason ティビツ <tibbs@fedoraproject.org>
|
|
|
|
Jeffrey C. Ollie <jcollie@fedoraproject.org>
|
|
|
|
Jesse Keating <jkeating@fedoraproject.org>
|
|
|
|
Kevin Fenzi <kevin@scrye.com>
|
|
|
|
Lumir Balhar <lbalhar@redhat.com>
|
|
|
|
Mikolaj Izdebski <mizdebsk@redhat.com>
|
|
|
|
Miro Hrončok <miro@hroncok.cz>
|
|
|
|
Peter Robinson <pbrobinson@gmail.com>
|
|
|
|
Robert Kuska <rkuska@redhat.com>
|
|
|
|
Shahms King <shahms@fedoraproject.org>
|
|
|
|
Slavek Kabrda <bkabrda@redhat.com>
|
|
|
|
tomspur <tomspur@fedoraproject.org>
|
|
|
|
Ville Skyttä <scop@fedoraproject.org>
|