#2 Only have one /usr/bin/cython
Merged 5 years ago by ignatenkobrain. Opened 5 years ago by churchyard.
rpms/ churchyard/Cython py3exes  into  master

file modified
+12 -15
@@ -6,7 +6,7 @@ 

  

  Name:           Cython

  Version:        0.28.4

- Release:        1%{?dist}

+ Release:        2%{?dist}

  Summary:        Language for writing Python extension modules

  

  License:        ASL 2.0
@@ -45,6 +45,7 @@ 

  %package -n python3-%{srcname}

  Summary:        %{summary}

  %{?python_provide:%python_provide python3-%{srcname}}

+ Conflicts:      python2-%{srcname} < 0.28.4-2

  BuildRequires:  python3-devel

  BuildRequires:  python3-setuptools

  %if %{with tests}
@@ -65,17 +66,13 @@ 

  %py3_build

  

  %install

- # 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

- # to be the default for now).

+ %py2_install

+ rm -rf %{buildroot}%{python2_sitelib}/setuptools/tests

+ rm %{buildroot}%{_bindir}/*

no need for this, $py3_install should overwrite those binaries.

Explicit is better than implicit. Also, either this or a comment that says: Need to do py2_install first, so the py3_install overrides the files... - if you ar enot strongly against this, I'd rather keep it.

+ 

  %py3_install

- for bin in cython cythonize cygdb; do

-   mv %{buildroot}%{_bindir}/${bin} %{buildroot}%{_bindir}/${bin}3

- done

  rm -rf %{buildroot}%{python3_sitelib}/setuptools/tests

  

- %py2_install

- rm -rf %{buildroot}%{python2_sitelib}/setuptools/tests

  

  %if %{with tests}

  %check
@@ -86,9 +83,6 @@ 

  %files -n python2-%{srcname}

  %license LICENSE.txt

  %doc *.txt Demos Doc Tools

- %{_bindir}/cython

- %{_bindir}/cygdb

- %{_bindir}/cythonize

  %{python2_sitearch}/%{srcname}-*.egg-info/

  %{python2_sitearch}/%{srcname}/

  %{python2_sitearch}/pyximport/
@@ -97,9 +91,9 @@ 

  %files -n python3-%{srcname}

  %license LICENSE.txt

  %doc *.txt Demos Doc Tools

- %{_bindir}/cython3

- %{_bindir}/cythonize3

- %{_bindir}/cygdb3

+ %{_bindir}/cython

+ %{_bindir}/cygdb

+ %{_bindir}/cythonize

I've heard that some upstreams use cythonize3... Not sure if we want to keep compatibility.

Let's remove it now and if unpatched upstream packages will FTBFS, i'll add a compatibility symblink.

  %{python3_sitearch}/%{srcname}-*.egg-info/

  %{python3_sitearch}/%{srcname}/

  %{python3_sitearch}/pyximport/
@@ -107,6 +101,9 @@ 

  %{python3_sitearch}/__pycache__/%{upname}.*

  

  %changelog

+ * Sun Aug 05 2018 Miro Hrončok <mhroncok@redhat.com> - 0.28.4-2

+ - Only have one /usr/bin/cython

+ 

  * Sun Jul 15 2018 Igor Gnatenko <ignatenkobrain@fedoraproject.org> - 0.28.4-1

  - Update to 0.28.4

  

Only have one /usr/bin/cython.

According to the current packaging guidelines, if the functionality of the executable is the same regardless of the Python version, the executable should be shipped by Python 3 package only.

This is the case for Cython.

Also, don't disable tests everywhere when they should only fail on Big Endian (they fail on all arches).

The following packages BR pythonX-Cython:

  • autowrap
  • blueman
  • borgbackup
  • brltty
  • bzr
  • cassandra
  • ceph
  • compizconfig-python
  • dionaea
  • eclipse-pydev
  • espresso
  • git-fame
  • h5py
  • CheMPS2
  • ipython
  • libfreenect
  • libmacaroons
  • libplist
  • netcdf4-python
  • numpy
  • openfst
  • openms
  • petsc4py
  • pocketsphinx
  • printrun
  • pygame
  • pygrib
  • pyliblo
  • pymilia
  • pyproj
  • pystatgrab
  • python-admesh
  • python-afl
  • python-aiohttp
  • python-assimulo
  • python-astropy
  • python-astropy-healpix
  • python-astroscrappy
  • python-basemap
  • python-bintrees
  • python-cartopy
  • python-cassandra-driver
  • python-cffi
  • python-compreffor
  • python-cradox
  • python-cypari2
  • python-cysignals
  • python-djvulibre
  • python-falcon
  • python-fiona
  • python-fpylll
  • python-gensim
  • python-giacpy
  • python-gmpy2
  • python-gsd
  • python-gssapi
  • python-healpy
  • python-hidapi
  • python-httptools
  • python-hug
  • python-jnius
  • python-kmod
  • python-libdiscid
  • python-line_profiler
  • python-lupa
  • python-lxml
  • python-MDAnalysis
  • python-meliae
  • python-mistune
  • python-msgpack
  • python-multidict
  • python-nipy
  • python-numpy-stl
  • python-orderedset
  • python-pandas
  • python-peewee
  • python-photutils
  • python-plyvel
  • python-pybloomfiltermmap
  • python-pyclipper
  • python-pymssql
  • python-pyopengl
  • python-pytaglib
  • python-pywt
  • python-rasterio
  • python-rencode
  • python-scikit-image
  • python-scikit-learn
  • python-shapely
  • python-slixmpp
  • python-smartcols
  • python-ssh2-python
  • python-statsmodels
  • python-tables
  • python-theano
  • python-thriftpy
  • python-tinycss
  • python-uvloop
  • python-yarl
  • python-zmq
  • python2-astropy
  • python2-ipython
  • python3-cangjie
  • PyYAML
  • sagemath
  • sphinxbase
  • sphinxtrain
  • sympy
  • urh
  • xpra

When this is merged, I'll send a heads up e-mail to devel + their maintainers. Later, I'll try to build them all and analyze + fix FTBFS related to this change.

1 new commit added

  • Only have one /usr/bin/cython
5 years ago

no need for this, $py3_install should overwrite those binaries.

I've heard that some upstreams use cythonize3... Not sure if we want to keep compatibility.

Nothing else apart from my comments. So once those are fixed -- +1 from me.

Explicit is better than implicit. Also, either this or a comment that says: Need to do py2_install first, so the py3_install overrides the files... - if you ar enot strongly against this, I'd rather keep it.

Let's remove it now and if unpatched upstream packages will FTBFS, i'll add a compatibility symblink.

Pull-Request has been merged by ignatenkobrain

5 years ago