2014-08-19 21:32:03 +00:00
|
|
|
|
%if 0%{?fedora} > 12
|
2013-07-25 15:52:37 +00:00
|
|
|
|
%global with_python3 1
|
|
|
|
|
%else
|
|
|
|
|
%{!?python_sitelib: %global python_sitelib %(%{__python} -c "from distutils.sysconfig import get_python_lib; print (get_python_lib())")}
|
|
|
|
|
%endif
|
|
|
|
|
|
|
|
|
|
Name: python-cffi
|
2016-06-23 17:29:26 +00:00
|
|
|
|
Version: 1.7.0
|
2016-08-09 13:54:13 +00:00
|
|
|
|
Release: 3%{?dist}
|
2013-07-25 15:52:37 +00:00
|
|
|
|
Summary: Foreign Function Interface for Python to call C code
|
2015-06-16 14:52:34 +00:00
|
|
|
|
License: MIT
|
2013-07-25 15:52:37 +00:00
|
|
|
|
URL: http://cffi.readthedocs.org/
|
2016-04-28 17:06:02 +00:00
|
|
|
|
Source0: https://pypi.io/packages/source/c/cffi/cffi-%{version}.tar.gz
|
2013-07-25 15:52:37 +00:00
|
|
|
|
|
|
|
|
|
BuildRequires: libffi-devel python-sphinx
|
2016-01-11 19:51:29 +00:00
|
|
|
|
BuildRequires: python2-devel python2-setuptools Cython python-pycparser
|
2013-07-25 15:52:37 +00:00
|
|
|
|
%if 0%{?with_python3}
|
|
|
|
|
BuildRequires: python3-devel python3-setuptools python3-Cython python3-pycparser
|
|
|
|
|
%endif # if with_python3
|
|
|
|
|
|
|
|
|
|
# Do not check .so files in the python_sitelib directory
|
|
|
|
|
# or any files in the application's directory for provides
|
|
|
|
|
%global __provides_exclude_from ^(%{python_sitearch}|%{python3_sitearch})/.*\\.so$
|
|
|
|
|
|
|
|
|
|
%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.
|
|
|
|
|
|
2016-01-11 19:51:29 +00:00
|
|
|
|
%package -n python2-cffi
|
|
|
|
|
Summary: Foreign Function Interface for Python 3 to call C code
|
|
|
|
|
Requires: python-pycparser
|
|
|
|
|
Obsoletes: python-cffi <= 1.4.2-1
|
|
|
|
|
%{?python_provide:%python_provide python2-cffi}
|
|
|
|
|
|
|
|
|
|
%description -n python2-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.
|
|
|
|
|
|
2013-07-25 15:52:37 +00:00
|
|
|
|
%if 0%{?with_python3}
|
|
|
|
|
%package -n python3-cffi
|
|
|
|
|
Summary: Foreign Function Interface for Python 3 to call C code
|
2013-08-13 16:39:04 +00:00
|
|
|
|
Requires: python3-pycparser
|
2016-01-11 19:51:29 +00:00
|
|
|
|
%{?python_provide:%python_provide python3-cffi}
|
2013-07-25 15:52:37 +00:00
|
|
|
|
|
|
|
|
|
%description -n python3-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.
|
|
|
|
|
%endif # with_python3
|
|
|
|
|
|
|
|
|
|
%package doc
|
|
|
|
|
Summary: Documentation for CFFI
|
|
|
|
|
BuildArch: noarch
|
|
|
|
|
Requires: %{name} = %{version}-%{release}
|
|
|
|
|
|
|
|
|
|
%description doc
|
|
|
|
|
Documentation for CFFI, the Foreign Function Interface for Python.
|
|
|
|
|
|
|
|
|
|
%prep
|
|
|
|
|
%setup -q -n cffi-%{version}
|
|
|
|
|
|
2013-07-25 18:04:53 +00:00
|
|
|
|
%if 0%{?with_python3}
|
2013-07-25 15:52:37 +00:00
|
|
|
|
rm -rf %{py3dir}
|
|
|
|
|
cp -a . %{py3dir}
|
|
|
|
|
%endif # with_python3
|
|
|
|
|
|
|
|
|
|
%build
|
|
|
|
|
%if 0%{?with_python3}
|
|
|
|
|
pushd %{py3dir}
|
|
|
|
|
%{__python3} setup.py build
|
|
|
|
|
popd
|
|
|
|
|
%endif # with_python3
|
|
|
|
|
|
|
|
|
|
%{__python} setup.py build
|
|
|
|
|
cd doc
|
|
|
|
|
make html
|
|
|
|
|
rm build/html/.buildinfo
|
|
|
|
|
|
|
|
|
|
#%check
|
|
|
|
|
## The following test procedure works when I run it manually, but fails
|
|
|
|
|
## from rpmbuild, complaining that it can't import _cffi_backend, and I'm
|
|
|
|
|
## not sure how to make it work
|
|
|
|
|
#python setup_base.py build
|
|
|
|
|
#PYTHONPATH=build/lib.linux-* py.test c/ testing/
|
|
|
|
|
|
|
|
|
|
%install
|
|
|
|
|
%if 0%{?with_python3}
|
|
|
|
|
pushd %{py3dir}
|
2016-08-09 13:54:13 +00:00
|
|
|
|
%{__python3} setup.py install \
|
|
|
|
|
--skip-build --prefix=%{_prefix} --root %{buildroot} \
|
|
|
|
|
--record %{buildroot}%{python3_sitearch}/cffi-%{version}-py%{python3_version}.egg-info/installed-files.txt
|
2013-07-25 15:52:37 +00:00
|
|
|
|
popd
|
|
|
|
|
%endif # with_python3
|
2016-08-09 13:54:13 +00:00
|
|
|
|
%{__python} setup.py install \
|
|
|
|
|
--skip-build --prefix=%{_prefix} --root %{buildroot} \
|
|
|
|
|
--record %{buildroot}%{python2_sitearch}/cffi-%{version}-py%{python2_version}.egg-info/installed-files.txt
|
2013-07-25 15:52:37 +00:00
|
|
|
|
|
2016-01-11 19:51:29 +00:00
|
|
|
|
%files -n python2-cffi
|
2015-07-15 12:23:38 +00:00
|
|
|
|
%doc PKG-INFO
|
|
|
|
|
%license LICENSE
|
2013-07-25 15:52:37 +00:00
|
|
|
|
%{python_sitearch}/*
|
|
|
|
|
|
2013-07-25 18:04:53 +00:00
|
|
|
|
%if 0%{?with_python3}
|
2013-07-25 15:52:37 +00:00
|
|
|
|
%files -n python3-cffi
|
2015-07-15 12:23:38 +00:00
|
|
|
|
%doc PKG-INFO
|
|
|
|
|
%license LICENSE
|
2013-07-25 15:52:37 +00:00
|
|
|
|
%{python3_sitearch}/*
|
|
|
|
|
%endif # with_python3
|
|
|
|
|
|
|
|
|
|
%files doc
|
|
|
|
|
%doc doc/build/html
|
|
|
|
|
|
|
|
|
|
%changelog
|
2016-08-09 13:54:13 +00:00
|
|
|
|
* Tue Aug 09 2016 Nathaniel McCallum <npmccallum@redhat.com> - 1.7.0-3
|
|
|
|
|
- Record installed files
|
|
|
|
|
|
2016-07-19 09:12:08 +00:00
|
|
|
|
* Tue Jul 19 2016 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.7.0-2
|
|
|
|
|
- https://fedoraproject.org/wiki/Changes/Automatic_Provides_for_Python_RPM_Packages
|
|
|
|
|
|
2016-06-23 17:29:26 +00:00
|
|
|
|
* Thu Jun 23 2016 John Dulaney <jdulaney@fedoraproject.org> - 1.7.0-1
|
|
|
|
|
- Update to 1.7.0
|
|
|
|
|
|
2016-04-28 17:06:02 +00:00
|
|
|
|
* Thu Apr 28 2016 John Dulaney <jdulaney@fedoraproject.org> - 1.6.0-3
|
|
|
|
|
- Switch Source0 to using pypi.io
|
|
|
|
|
|
2016-04-28 16:31:06 +00:00
|
|
|
|
* Thu Apr 28 2016 John Dulaney <jdulaney@fedoraproject.org> - 1.6.0-2
|
|
|
|
|
- Update Source0 URL to account for pypi change
|
|
|
|
|
|
2016-04-21 16:47:01 +00:00
|
|
|
|
* Thu Apr 21 2016 John Dulaney <jdulaney@fedoraproject.org> - 1.6.0-1
|
|
|
|
|
- Update to 1.6.0 (#1329203)
|
|
|
|
|
|
2016-02-15 08:41:23 +00:00
|
|
|
|
* Mon Feb 15 2016 John Dulaney <jdulaney@fedoraproject.org> - 1.5.2-1
|
|
|
|
|
- Update to 1.5.2 (#1299272)
|
|
|
|
|
|
2016-02-04 19:11:11 +00:00
|
|
|
|
* Thu Feb 04 2016 Fedora Release Engineering <releng@fedoraproject.org> - 1.5.0-2
|
|
|
|
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_24_Mass_Rebuild
|
|
|
|
|
|
2016-01-18 14:33:54 +00:00
|
|
|
|
* Mon Jan 18 2016 Nathaniel McCallum <npmccallum@redhat.com> - 1.5.0-1
|
|
|
|
|
- Update to 1.5.0 (#1299272)
|
|
|
|
|
|
2016-01-11 19:51:29 +00:00
|
|
|
|
* Mon Jan 11 2016 Nathaniel McCallum <npmccallum@redhat.com> - 1.4.2-2
|
|
|
|
|
- Move python-cffi => python2-cffi
|
|
|
|
|
|
2015-12-22 04:07:49 +00:00
|
|
|
|
* Tue Dec 22 2015 John Dulaney <jdulaney@fedoraproject.org> - 1.4.2-1
|
|
|
|
|
- Update to 1.4.2 (#1293504)
|
|
|
|
|
|
2015-12-18 00:58:05 +00:00
|
|
|
|
* Thu Dec 17 2015 John Dulaney <jdulaney@fedoraproject.org> - 1.4.1-1
|
|
|
|
|
- Update to latest upstream release
|
|
|
|
|
|
2015-12-11 05:14:02 +00:00
|
|
|
|
* Fri Dec 11 2015 John Dulaney <jdulaney@fedoraproject.org> - 1.3.1-1
|
2015-12-11 05:04:55 +00:00
|
|
|
|
- Update to latest upstream release
|
|
|
|
|
|
2015-10-13 08:03:48 +00:00
|
|
|
|
* Tue Oct 13 2015 Robert Kuska <rkuska@redhat.com> - 1.1.2-4
|
|
|
|
|
- Rebuilt for Python3.5 rebuild
|
|
|
|
|
|
2015-07-15 12:23:38 +00:00
|
|
|
|
* Wed Jul 15 2015 Parag Nemade <pnemade AT redhat DOT com> - 1.1.2-3
|
|
|
|
|
- Modernize spec file
|
|
|
|
|
- add missing source
|
|
|
|
|
|
2015-06-18 18:43:41 +00:00
|
|
|
|
* Thu Jun 18 2015 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.1.2-2
|
|
|
|
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_23_Mass_Rebuild
|
|
|
|
|
|
2015-06-16 14:52:34 +00:00
|
|
|
|
* Tue Jun 16 2015 Nathaniel McCallum <npmccallum@redhat.com> - 1.1.2-2
|
|
|
|
|
- Update to 1.1.2
|
|
|
|
|
- Fix license
|
|
|
|
|
|
2014-08-19 21:32:03 +00:00
|
|
|
|
* Tue Aug 19 2014 Eric Smith <spacewar@gmail.com> 0.8.6-1
|
|
|
|
|
- Update to latest upstream.
|
|
|
|
|
- No python3 in el7.
|
|
|
|
|
|
2014-08-17 20:59:10 +00:00
|
|
|
|
* Sun Aug 17 2014 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.8.1-4
|
|
|
|
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_22_Mass_Rebuild
|
|
|
|
|
|
2014-06-07 19:02:32 +00:00
|
|
|
|
* Sat Jun 07 2014 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.8.1-3
|
|
|
|
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_Mass_Rebuild
|
|
|
|
|
|
2014-05-12 15:09:02 +00:00
|
|
|
|
* Mon May 12 2014 Bohuslav Kabrda <bkabrda@redhat.com> - 0.8.1-2
|
|
|
|
|
- Rebuilt for https://fedoraproject.org/wiki/Changes/Python_3.4
|
|
|
|
|
|
2014-02-27 04:00:16 +00:00
|
|
|
|
* Wed Feb 26 2014 Eric Smith <spacewar@gmail.com> 0.8.1-1
|
|
|
|
|
- Update to latest upstream.
|
|
|
|
|
|
|
|
|
|
* Tue Aug 13 2013 Eric Smith <spacewar@gmail.com> 0.6-5
|
2013-08-13 16:39:04 +00:00
|
|
|
|
- Add Requires of python{,3}-pycparser.
|
|
|
|
|
|
2014-02-27 04:00:16 +00:00
|
|
|
|
* Thu Jul 25 2013 Eric Smith <spacewar@gmail.com> 0.6-4
|
2013-07-25 18:04:53 +00:00
|
|
|
|
- Fix broken conditionals in spec (missing question marks), needed for el6.
|
|
|
|
|
|
2014-02-27 04:00:16 +00:00
|
|
|
|
* Tue Jul 23 2013 Eric Smith <spacewar@gmail.com> 0.6-3
|
2013-07-25 15:52:37 +00:00
|
|
|
|
- Add Python3 support.
|
|
|
|
|
|
2014-02-27 04:00:16 +00:00
|
|
|
|
* Mon Jul 22 2013 Eric Smith <spacewar@gmail.com> 0.6-2
|
2013-07-25 15:52:37 +00:00
|
|
|
|
- Better URL, and use version macro in Source0.
|
|
|
|
|
|
2014-02-27 04:00:16 +00:00
|
|
|
|
* Sun Jul 21 2013 Eric Smith <spacewar@gmail.com> 0.6-1
|
2013-07-25 15:52:37 +00:00
|
|
|
|
- initial version
|