From c8a82fe62ff5b7d4fb8139ce4a35f6d8ea71c0ea Mon Sep 17 00:00:00 2001 From: Miro Hrončok Date: Dec 18 2019 06:35:55 +0000 Subject: Initial import (#1784439) --- diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..9d16a4f --- /dev/null +++ b/.gitignore @@ -0,0 +1,4 @@ +/xmlschema-*.tar.gz +/xmlschema-*/ +/results_*/ +*.rpm diff --git a/python-xmlschema.spec b/python-xmlschema.spec new file mode 100644 index 0000000..4249696 --- /dev/null +++ b/python-xmlschema.spec @@ -0,0 +1,65 @@ +%global pypi_name xmlschema +Name: python-%{pypi_name} +Version: 1.0.16 +Release: 1%{?dist} +Summary: A Python XML Schema validator and decoder + +License: MIT +URL: https://github.com/brunato/xmlschema +Source0: %{pypi_source} +BuildArch: noarch +BuildRequires: pyproject-rpm-macros + +%global _description %{expand: +The xmlschema library is an implementation of XML Schema for Python. + +This library arises from the needs of a solid Python layer for processing XML +Schema based files for MaX (Materials design at the Exascale) European project. +A significant problem is the encoding and the decoding of the XML data files +produced by different simulation software. Another important requirement is +the XML data validation, in order to put the produced data under control. +The lack of a suitable alternative for Python in the schema-based decoding +of XML data has led to build this library. Obviously this library can be +useful for other cases related to XML Schema based processing, not only for +the original scope.} + +%description %_description + + +%package -n python3-%{pypi_name} +Summary: %{summary} +%{?python_provide:%python_provide python3-%{pypi_name}} + +%description -n python3-%{pypi_name} %_description + + +%prep +%autosetup -n %{pypi_name}-%{version} +sed -i 's/~=/>=/' setup.py tox.ini # https://bugzilla.redhat.com/show_bug.cgi?id=1758141 +sed -i 's/==/>=/' tox.ini # too strict test deps +pathfix.py -pni %{python3} %{pypi_name} + +%generate_buildrequires +%pyproject_buildrequires -t + +%build +%pyproject_wheel + +%install +%pyproject_install + +%check +%tox + +%files -n python3-%{pypi_name} +%license LICENSE +%doc README.rst +%{python3_sitelib}/%{pypi_name}/ +%{python3_sitelib}/%{pypi_name}-%{version}.dist-info/ +# we exclude, not rm - used in %%check +%exclude %{python3_sitelib}/%{pypi_name}/tests + + +%changelog +* Tue Dec 17 2019 Miro Hrončok - 1.0.16-1 +- Initial package diff --git a/sources b/sources new file mode 100644 index 0000000..7726c43 --- /dev/null +++ b/sources @@ -0,0 +1 @@ +SHA512 (xmlschema-1.0.16.tar.gz) = 5dd79e608036995d70b4da627f89c86cd8e7a66f80c2cb87d701395229daa920759769bf7efad34c33dd28ca14971eb155a654f8fec12fb6ace8cb5ecf979650