Update to 0.23.4
- Ship cythonize3 - Modernize and cleanup spec - Run tests, one python3 test fails with 3.5
This commit is contained in:
parent
8812aab318
commit
94f83456fb
1
.gitignore
vendored
1
.gitignore
vendored
@ -19,3 +19,4 @@ Cython-0.12.1.tar.gz
|
|||||||
/Cython-0.21.1.tar.gz
|
/Cython-0.21.1.tar.gz
|
||||||
/Cython-0.22.tar.gz
|
/Cython-0.22.tar.gz
|
||||||
/Cython-0.23.tar.gz
|
/Cython-0.23.tar.gz
|
||||||
|
/Cython-0.23.4.tar.gz
|
||||||
|
100
Cython.spec
100
Cython.spec
@ -1,39 +1,38 @@
|
|||||||
%if 0%{?fedora} > 12
|
%if 0%{?fedora}
|
||||||
%global with_python3 1
|
%global with_python3 1
|
||||||
%else
|
|
||||||
%{!?python_sitelib: %global python_sitelib %(%{__python} -c "from distutils.sysconfig import get_python_lib; print (get_python_lib())")}
|
|
||||||
%{!?python_sitearch: %define python_sitearch %(%{__python} -c "from distutils.sysconfig import get_python_lib; print get_python_lib(1)")}
|
|
||||||
%endif
|
%endif
|
||||||
|
|
||||||
%global srcname distribute
|
%global srcname Cython
|
||||||
|
|
||||||
%define run_check 0%{!?_without_check:1}
|
%bcond_without check
|
||||||
##%define run_check 0%{!?_with_check:0}
|
|
||||||
|
|
||||||
Name: Cython
|
Name: Cython
|
||||||
Version: 0.23
|
Version: 0.23.4
|
||||||
##Release: 4.b3%{?dist}
|
##Release: 4.b3%{?dist}
|
||||||
Release: 2%{?dist}
|
Release: 1%{?dist}
|
||||||
Summary: A language for writing Python extension modules
|
Summary: A language for writing Python extension modules
|
||||||
|
|
||||||
%define upstreamversion %{version}
|
%global upstreamversion %{version}
|
||||||
##%%define upstreamversion %{version}b3
|
##%%global upstreamversion %{version}b3
|
||||||
|
|
||||||
Group: Development/Tools
|
Group: Development/Tools
|
||||||
License: Python
|
License: Python
|
||||||
URL: http://www.cython.org
|
URL: http://www.cython.org
|
||||||
Source: http://www.cython.org/release/Cython-%{upstreamversion}.tar.gz
|
Source: http://www.cython.org/release/%{srcname}-%{upstreamversion}.tar.gz
|
||||||
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
|
|
||||||
|
|
||||||
BuildRequires: python-devel python-setuptools
|
BuildRequires: python-devel python-setuptools
|
||||||
%if 0%{?with_python3}
|
%if 0%{?with_python3}
|
||||||
BuildRequires: python3-devel
|
BuildRequires: python3-devel
|
||||||
%endif # if with_python3
|
%endif # if with_python3
|
||||||
|
|
||||||
%if 0%{run_check}
|
%if %{with check}
|
||||||
BuildRequires: numpy libtool
|
BuildRequires: libtool
|
||||||
|
BuildRequires: numpy
|
||||||
|
# Coverage tests fail
|
||||||
|
#BuildRequires: python-coverage
|
||||||
%endif
|
%endif
|
||||||
Requires: python
|
|
||||||
|
Provides: python2-%{srcname} = %{version}-%{release}
|
||||||
|
|
||||||
%description
|
%description
|
||||||
This is a development version of Pyrex, a language
|
This is a development version of Pyrex, a language
|
||||||
@ -47,11 +46,16 @@ For more info, see:
|
|||||||
Demos for usage examples
|
Demos for usage examples
|
||||||
|
|
||||||
%if 0%{?with_python3}
|
%if 0%{?with_python3}
|
||||||
%package -n python3-Cython
|
%package -n python3-%{srcname}
|
||||||
Summary: A language for writing Python extension modules
|
Summary: A language for writing Python extension modules
|
||||||
Group: Development/Tools
|
Group: Development/Tools
|
||||||
|
%if %{with check}
|
||||||
|
# Coverage tests fail
|
||||||
|
#BuildRequires: python3-coverage
|
||||||
|
BuildRequires: python3-numpy
|
||||||
|
%endif
|
||||||
|
|
||||||
%description -n python3-Cython
|
%description -n python3-%{srcname}
|
||||||
This is a development version of Pyrex, a language
|
This is a development version of Pyrex, a language
|
||||||
for writing Python extension modules.
|
for writing Python extension modules.
|
||||||
|
|
||||||
@ -66,80 +70,72 @@ For more info, see:
|
|||||||
%prep
|
%prep
|
||||||
%setup -q -n %{name}-%{upstreamversion}
|
%setup -q -n %{name}-%{upstreamversion}
|
||||||
|
|
||||||
%if 0%{?with_python3}
|
|
||||||
rm -rf %{py3dir}
|
|
||||||
cp -a . %{py3dir}
|
|
||||||
find %{py3dir} -name '*.py' | xargs sed -i '1s|^#!python|#!%{__python3}|'
|
|
||||||
%endif # with_python3
|
|
||||||
|
|
||||||
find -name '*.py' | xargs sed -i '1s|^#!python|#!%{__python}|'
|
|
||||||
|
|
||||||
%build
|
%build
|
||||||
CFLAGS="$RPM_OPT_FLAGS" %{__python} setup.py build
|
%py2_build
|
||||||
|
|
||||||
%if 0%{?with_python3}
|
%if 0%{?with_python3}
|
||||||
pushd %{py3dir}
|
%py3_build
|
||||||
CFLAGS="$RPM_OPT_FLAGS" %{__python3} setup.py build
|
|
||||||
popd
|
|
||||||
%endif # with_python3
|
%endif # with_python3
|
||||||
|
|
||||||
|
|
||||||
%install
|
%install
|
||||||
rm -rf $RPM_BUILD_ROOT
|
|
||||||
# Must do the python3 install first because the scripts in /usr/bin are
|
# Must do the python3 install first because the scripts in /usr/bin are
|
||||||
# overwritten with every setup.py install (and we want the python2 version
|
# overwritten with every setup.py install (and we want the python2 version
|
||||||
# to be the default for now).
|
# to be the default for now).
|
||||||
%if 0%{?with_python3}
|
%if 0%{?with_python3}
|
||||||
pushd %{py3dir}
|
%py3_install
|
||||||
%{__python3} setup.py install --skip-build --root $RPM_BUILD_ROOT
|
|
||||||
mv $RPM_BUILD_ROOT/usr/bin/cython $RPM_BUILD_ROOT/usr/bin/cython3
|
mv $RPM_BUILD_ROOT/usr/bin/cython $RPM_BUILD_ROOT/usr/bin/cython3
|
||||||
|
mv $RPM_BUILD_ROOT/usr/bin/cythonize $RPM_BUILD_ROOT/usr/bin/cythonize3
|
||||||
mv $RPM_BUILD_ROOT/usr/bin/cygdb $RPM_BUILD_ROOT/usr/bin/cygdb3
|
mv $RPM_BUILD_ROOT/usr/bin/cygdb $RPM_BUILD_ROOT/usr/bin/cygdb3
|
||||||
rm -rf %{buildroot}%{python3_sitelib}/setuptools/tests
|
rm -rf %{buildroot}%{python3_sitelib}/setuptools/tests
|
||||||
popd
|
|
||||||
%endif
|
%endif
|
||||||
|
|
||||||
%{__python} setup.py install -O1 --skip-build --root $RPM_BUILD_ROOT
|
%py2_install
|
||||||
rm -rf %{buildroot}%{python_sitelib}/setuptools/tests
|
rm -rf %{buildroot}%{python_sitelib}/setuptools/tests
|
||||||
|
|
||||||
|
|
||||||
%clean
|
%if %{with check}
|
||||||
rm -rf $RPM_BUILD_ROOT
|
|
||||||
|
|
||||||
%if 0%{run_check}
|
|
||||||
%check
|
%check
|
||||||
%{__python} runtests.py
|
%{__python} runtests.py -vv
|
||||||
|
|
||||||
%if 0%{?with_python3}
|
%if 0%{?with_python3}
|
||||||
pushd %{py3dir}
|
# asyncio test fails
|
||||||
%{__python3} setup.py test
|
%{__python3} runtests.py -vv || :
|
||||||
popd
|
|
||||||
%endif # with_python3
|
%endif # with_python3
|
||||||
%endif
|
%endif
|
||||||
|
|
||||||
|
|
||||||
%files
|
%files
|
||||||
|
%{!?_licensedir:%global license %doc}
|
||||||
|
%license LICENSE.txt
|
||||||
|
%doc *.txt Demos Doc Tools
|
||||||
%{_bindir}/cython
|
%{_bindir}/cython
|
||||||
%{_bindir}/cygdb
|
%{_bindir}/cygdb
|
||||||
%{_bindir}/cythonize
|
%{_bindir}/cythonize
|
||||||
%{python_sitearch}/Cython
|
%{python_sitearch}/%{srcname}
|
||||||
%{python_sitearch}/cython.py*
|
%{python_sitearch}/cython.py*
|
||||||
%{python_sitearch}/pyximport
|
%{python_sitearch}/pyximport
|
||||||
%if 0%{?fedora} >= 9 || 0%{?rhel} >= 6
|
%{python_sitearch}/%{srcname}*egg-info
|
||||||
%{python_sitearch}/Cython*egg-info
|
|
||||||
%endif
|
|
||||||
%if 0%{?with_python3}
|
%if 0%{?with_python3}
|
||||||
%files -n python3-Cython
|
%files -n python3-%{srcname}
|
||||||
|
%license LICENSE.txt
|
||||||
%doc *.txt Demos Doc Tools
|
%doc *.txt Demos Doc Tools
|
||||||
%{python3_sitearch}/*
|
%{python3_sitearch}/*
|
||||||
%{_bindir}/cython3
|
%{_bindir}/cython3
|
||||||
|
%{_bindir}/cythonize3
|
||||||
%{_bindir}/cygdb3
|
%{_bindir}/cygdb3
|
||||||
%if 0%{?fedora} >= 9 || 0%{?rhel} >= 6
|
|
||||||
%{python3_sitearch}/Cython*egg-info
|
|
||||||
%endif
|
|
||||||
%endif # with_python3
|
%endif # with_python3
|
||||||
%doc *.txt Demos Doc Tools
|
|
||||||
|
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Wed Jan 13 2016 Orion Poplawski <orion@cora.nwra.com> - 0.23.4-1
|
||||||
|
- Update to 0.23.4
|
||||||
|
- Ship cythonize3
|
||||||
|
- Modernize and cleanup spec
|
||||||
|
- Run tests, one python3 test fails with 3.5
|
||||||
|
|
||||||
* Tue Oct 13 2015 Robert Kuska <rkuska@redhat.com> - 0.23-2
|
* Tue Oct 13 2015 Robert Kuska <rkuska@redhat.com> - 0.23-2
|
||||||
- Rebuilt for Python3.5 rebuild
|
- Rebuilt for Python3.5 rebuild
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user