From be48c5d7b08c55a7a21458e9452ae5fa7d44e445 Mon Sep 17 00:00:00 2001 From: James Antill Date: Mon, 8 Aug 2022 14:04:01 -0400 Subject: [PATCH] Import rpm: 861708155a06d3d41346eb51a773fe766b957fda --- .gitignore | 1 + gating.yaml | 7 ++ python-cffi.spec | 307 +++++++++++++++++++++++++++++++++++++++++++++++ sources | 1 + tests/tests.yml | 23 ++++ 5 files changed, 339 insertions(+) create mode 100644 .gitignore create mode 100644 gating.yaml create mode 100644 python-cffi.spec create mode 100644 sources create mode 100644 tests/tests.yml diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..e885ba4 --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +SOURCES/cffi-1.14.3.tar.gz diff --git a/gating.yaml b/gating.yaml new file mode 100644 index 0000000..6f49862 --- /dev/null +++ b/gating.yaml @@ -0,0 +1,7 @@ +# recipients: abokovoy, frenaud, kaleem, ftrivino, cheimes +--- !Policy +product_versions: + - rhel-9 +decision_context: osci_compose_gate +rules: + - !PassingTestCaseRule {test_case_name: osci.brew-build.tier0.functional} diff --git a/python-cffi.spec b/python-cffi.spec new file mode 100644 index 0000000..08c77c6 --- /dev/null +++ b/python-cffi.spec @@ -0,0 +1,307 @@ +# RHEL: Docs disabled due to python3-sphinx not being installable during build of the python39 module +%bcond_with docs + +%bcond_without tests + +Name: python-cffi +Version: 1.14.3 +Release: 2%{?dist} +Summary: Foreign Function Interface for Python to call C code +License: MIT +URL: https://cffi.readthedocs.org/ +Source0: %{pypi_source cffi} + +# Exclude i686 arch. Due to a modularity issue it's being added to the +# x86_64 compose of CRB, but we don't want to ship it at all. +# See: https://projects.engineering.redhat.com/browse/RCM-72605 +ExcludeArch: i686 + +BuildRequires: make +BuildRequires: libffi-devel +BuildRequires: gcc + +%if %{with tests} +# For tests: +BuildRequires: gcc-c++ +%endif + +%?python_enable_dependency_generator + +%description +Foreign Function Interface for Python, providing a convenient and +reliable way of calling existing C code from Python. The interface is +based on LuaJIT’s FFI. + +%package -n python%{python3_pkgversion}-cffi +Summary: Foreign Function Interface for Python 3 to call C code +%if %{with docs} +BuildRequires: python3-sphinx +%endif +%if %{with tests} +BuildRequires: python%{python3_pkgversion}-pytest +%endif +BuildRequires: python%{python3_pkgversion}-devel +BuildRequires: python%{python3_pkgversion}-rpm-macros +BuildRequires: python%{python3_pkgversion}-setuptools +BuildRequires: python%{python3_pkgversion}-pycparser +%{?python_provide:%python_provide python%{python3_pkgversion}-cffi} + +%description -n python%{python3_pkgversion}-cffi +Foreign Function Interface for Python, providing a convenient and +reliable way of calling existing C code from Python. The interface is +based on LuaJIT’s FFI. + +%if %{with docs} +%package doc +Summary: Documentation for CFFI +BuildArch: noarch + +%description doc +Documentation for CFFI, the Foreign Function Interface for Python. + +%endif + + +%prep +%autosetup -p1 -n cffi-%{version} + +%build +%py3_build + +%if %{with docs} +cd doc +make SPHINXBUILD=sphinx-build-3 html +rm build/html/.buildinfo +%endif + +%install +%py3_install + +%if %{with tests} +%check +PYTHONPATH=%{buildroot}%{python3_sitearch} %{__python3} -m pytest c/ testing/ +%endif + +%files -n python%{python3_pkgversion}-cffi +%doc PKG-INFO +%license LICENSE +%{python3_sitearch}/cffi/ +%{python3_sitearch}/_cffi_backend.*.so +%{python3_sitearch}/cffi-%{version}-py%{python3_version}.egg-info/ + +%if %{with docs} +%files doc +%doc doc/build/html +%endif + +%changelog +* Mon Jan 18 2021 Tomas Orsava - 1.14.3-2 +- Convert from Fedora to the python39 module in RHEL8 +- Resolves: rhbz#1877430 + +* Thu Nov 19 2020 Joel Capitao - 1.14.3-1 +- Update to 1.14.3 + +* Tue Sep 08 2020 Lumír Balhar - 1.14.2-1 +- Update to 1.14.2 (#1869032) + +* Fri Aug 14 2020 Miro Hrončok - 1.14.1-1 +- Update to 1.14.1 +- Fixes: rhbz#1860698 +- Fixes: rhbz#1865276 + +* Sat May 23 2020 Miro Hrončok - 1.14.0-2 +- Rebuilt for Python 3.9 + +* Mon Feb 10 2020 Lumír Balhar - 1.14.0 +- Update to 1.14.0 (#1800646) + +* Thu Jan 30 2020 Fedora Release Engineering - 1.13.2-2 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_32_Mass_Rebuild + +* Mon Nov 18 2019 Lumír Balhar - 1.13.2-1 +- Update to 1.13.2 (#1768219) + +* Mon Oct 21 2019 Miro Hrončok - 1.13.1-1 +- Update to 1.13.1 (#1763767) + +* Tue Oct 15 2019 Miro Hrončok - 1.13.0-1 +- Update to 1.13.0 (#1761757) + +* Sun Oct 13 2019 Miro Hrončok - 1.12.3-5 +- Subpackage python2-cffi has been removed + See https://fedoraproject.org/wiki/Changes/Mass_Python_2_Package_Removal + +* Thu Oct 03 2019 Miro Hrončok - 1.12.3-4 +- Rebuilt for Python 3.8.0rc1 (#1748018) + +* Mon Aug 26 2019 Miro Hrončok - 1.12.3-3 +- Reduce Python 2 build dependencies + +* Fri Aug 16 2019 Miro Hrončok - 1.12.3-2 +- Rebuilt for Python 3.8 + +* Thu Jul 25 2019 Miro Hrončok - 1.12.3-1 +- Update to 1.12.3 (#1701577) +- https://cffi.readthedocs.io/en/latest/whatsnew.html#v1-12-3 + +* Mon Jul 15 2019 Petr Viktorin - 1.12.2-2 +- Remove unused build dependency on Cython +- Remove duplicate build dependency on pytest + +* Wed Mar 27 2019 Miro Hrončok - 1.12.2-1 +- Update to 1.12.2 (#1677888) + +* Sat Feb 02 2019 Fedora Release Engineering - 1.11.5-7 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_30_Mass_Rebuild + +* Wed Aug 22 2018 Miro Hrončok - 1.11.5-6 +- Fix FTBFS (#1605627) + +* Fri Jul 13 2018 Fedora Release Engineering - 1.11.5-5 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_29_Mass_Rebuild + +* Fri Jun 15 2018 Miro Hrončok - 1.11.5-4 +- Rebuilt for Python 3.7 + +* Fri May 25 2018 Gwyn Ciesla - 1.11.5-3 +- Disable tests to fix mock-only FTBFS. + +* Fri Mar 09 2018 Iryna Shcherbina - 1.11.5-2 +- Update Python 2 dependency declarations to new packaging standards + (See https://fedoraproject.org/wiki/FinalizingFedoraSwitchtoPython3) + +* Fri Mar 02 2018 John Dulaney - 1.11.2-1 +- New release 1.11.5 + +* Fri Feb 09 2018 Igor Gnatenko - 1.11.2-3 +- Escape macros in %%changelog + +* Fri Feb 09 2018 Fedora Release Engineering - 1.11.2-2 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild + +* Thu Oct 19 2017 John Dulaney - 1.11.2-1 +- New release 1.11.0 +- Fix %%check + +* Wed Sep 27 2017 Troy Dawson - 1.11.0-2 +- Cleanup spec file conditionals + +* Sat Sep 23 2017 John Dulaney - 1.11.0-1 +- New release 1.11.0 + +* Thu Aug 03 2017 Fedora Release Engineering - 1.10.0-3 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Binutils_Mass_Rebuild + +* Thu Jul 27 2017 Fedora Release Engineering - 1.10.0-2 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Mass_Rebuild + +* Tue Apr 04 2017 John Dulaney - 1.10.0-1 +- New release 1.10.0 + +* Sat Feb 11 2017 Fedora Release Engineering - 1.9.1-2 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_26_Mass_Rebuild + +* Sat Jan 07 2017 John Dulaney - 1.9.1-1 +- Update to latest upstream 1.9.1 + +* Fri Jan 6 2017 Orion Poplawski - 1.8.3-4 +- Modernize spec + +* Mon Dec 12 2016 Charalampos Stratakis - 1.8.3-3 +- Rebuild for Python 3.6 +- Disable test dependencies + +* Thu Nov 03 2016 John Dulaney - 1.8.3-2 +- Re-disable check + +* Sun Sep 18 2016 John Dulaney - 1.8.3-1 +- Update to 1.8.3 +- Reenable check + +* Wed Sep 07 2016 John Dulaney - 1.8.2-1 +- Update to 1.8.2 + +* Tue Aug 09 2016 Nathaniel McCallum - 1.7.0-3 +- Record installed files + +* Tue Jul 19 2016 Fedora Release Engineering - 1.7.0-2 +- https://fedoraproject.org/wiki/Changes/Automatic_Provides_for_Python_RPM_Packages + +* Thu Jun 23 2016 John Dulaney - 1.7.0-1 +- Update to 1.7.0 + +* Thu Apr 28 2016 John Dulaney - 1.6.0-3 +- Switch Source0 to using pypi.io + +* Thu Apr 28 2016 John Dulaney - 1.6.0-2 +- Update Source0 URL to account for pypi change + +* Thu Apr 21 2016 John Dulaney - 1.6.0-1 +- Update to 1.6.0 (#1329203) + +* Mon Feb 15 2016 John Dulaney - 1.5.2-1 +- Update to 1.5.2 (#1299272) + +* Thu Feb 04 2016 Fedora Release Engineering - 1.5.0-2 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_24_Mass_Rebuild + +* Mon Jan 18 2016 Nathaniel McCallum - 1.5.0-1 +- Update to 1.5.0 (#1299272) + +* Mon Jan 11 2016 Nathaniel McCallum - 1.4.2-2 +- Move python-cffi => python2-cffi + +* Tue Dec 22 2015 John Dulaney - 1.4.2-1 +- Update to 1.4.2 (#1293504) + +* Thu Dec 17 2015 John Dulaney - 1.4.1-1 +- Update to latest upstream release + +* Fri Dec 11 2015 John Dulaney - 1.3.1-1 +- Update to latest upstream release + +* Tue Oct 13 2015 Robert Kuska - 1.1.2-4 +- Rebuilt for Python3.5 rebuild + +* Wed Jul 15 2015 Parag Nemade - 1.1.2-3 +- Modernize spec file +- add missing source + +* Thu Jun 18 2015 Fedora Release Engineering - 1.1.2-2 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_23_Mass_Rebuild + +* Tue Jun 16 2015 Nathaniel McCallum - 1.1.2-2 +- Update to 1.1.2 +- Fix license + +* Tue Aug 19 2014 Eric Smith 0.8.6-1 +- Update to latest upstream. +- No python3 in el7. + +* Sun Aug 17 2014 Fedora Release Engineering - 0.8.1-4 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_22_Mass_Rebuild + +* Sat Jun 07 2014 Fedora Release Engineering - 0.8.1-3 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_Mass_Rebuild + +* Mon May 12 2014 Bohuslav Kabrda - 0.8.1-2 +- Rebuilt for https://fedoraproject.org/wiki/Changes/Python_3.4 + +* Wed Feb 26 2014 Eric Smith 0.8.1-1 +- Update to latest upstream. + +* Tue Aug 13 2013 Eric Smith 0.6-5 +- Add Requires of python{,3}-pycparser. + +* Thu Jul 25 2013 Eric Smith 0.6-4 +- Fix broken conditionals in spec (missing question marks), needed for el6. + +* Tue Jul 23 2013 Eric Smith 0.6-3 +- Add Python3 support. + +* Mon Jul 22 2013 Eric Smith 0.6-2 +- Better URL, and use version macro in Source0. + +* Sun Jul 21 2013 Eric Smith 0.6-1 +- initial version diff --git a/sources b/sources new file mode 100644 index 0000000..13ec4df --- /dev/null +++ b/sources @@ -0,0 +1 @@ +SHA1 (cffi-1.14.3.tar.gz) = 7199374653c1927e8d3c523b6498b149acdb6f7e diff --git a/tests/tests.yml b/tests/tests.yml new file mode 100644 index 0000000..91aaa83 --- /dev/null +++ b/tests/tests.yml @@ -0,0 +1,23 @@ +--- + +# 1minutetip --buildroot + +- hosts: localhost + tags: + - classic + roles: + - role: standard-test-source + + - role: standard-test-basic + required_packages: + - python3-cffi + - python3-pytest + - python3-devel + - gcc + tests: + - unittests: + dir: "source" + # cffi1 and test_version depend on files that are not packaged + run: >- + rm -rf cffi* testing/cffi0/test_version.py && + pytest-3 testing/cffi0