Subpackage python2-vigra has been removed

This commit is contained in:
Miro Hrončok 2019-01-15 20:13:45 +01:00
parent e771848e2a
commit 6ea9ef1321
1 changed files with 23 additions and 44 deletions

View File

@ -1,16 +1,7 @@
%if 0%{?fedora} > 28
%global boostpy2 boost-python2 boost-python2-devel
%else
%if 0%{?fedora} > 27
%global boostpy2 boost-python2
%else
%global boostpy2 boost-python
%endif
%endif
Summary: Generic Programming for Computer Vision
Name: vigra
Version: 1.11.1
Release: 10%{?dist}
Release: 11%{?dist}
License: MIT
Group: Development/Libraries
# The "Lenna" files are non-free, we need to remove them from the source tarball.
@ -29,12 +20,23 @@ Patch2: vigra-1.11.1.docdir.patch
# https://bugzilla.redhat.com/show_bug.cgi?id=1597394
Patch3: vigra-1.11.1.py37.patch
URL: http://ukoethe.github.io/vigra/
BuildRequires: gcc-c++ zlib-devel libjpeg-devel libpng-devel libtiff-devel fftw-devel >= 3
BuildRequires: cmake boost-devel doxygen
BuildRequires: gcc-c++
BuildRequires: zlib-devel
BuildRequires: libjpeg-devel
BuildRequires: libpng-devel
BuildRequires: libtiff-devel
BuildRequires: fftw-devel >= 3
BuildRequires: cmake
BuildRequires: boost-devel
BuildRequires: doxygen
%if ! 0%{?rhel}
Requires: python3
BuildRequires: hdf5-devel python2-sphinx python2-numpy-f2py %{boostpy2} OpenEXR-devel
BuildRequires: python3-numpy-f2py boost-python3 boost-python3-devel
BuildRequires: hdf5-devel
BuildRequires: python3-sphinx
BuildRequires: OpenEXR-devel
BuildRequires: python3-numpy-f2py
BuildRequires: boost-python3
BuildRequires: boost-python3-devel
%else
Requires: python
%endif
@ -55,7 +57,8 @@ Requires: %{name}%{?_isa} = %{version}-%{release}
Requires: libjpeg-devel libtiff-devel libpng-devel zlib-devel fftw-devel >= 3
Requires: boost-devel
%if ! 0%{?rhel}
Requires: hdf5-devel python2-numpy-f2py %{boostpy2} OpenEXR-devel
Requires: hdf5-devel
Requires: OpenEXR-devel
Requires: python3-numpy-f2py boost-python3 boost-python3-devel
%endif
@ -64,19 +67,6 @@ The vigra-devel package includes the header files necessary for developing
programs that use the vigra library.
%if ! 0%{?rhel}
%package -n python2-vigra
%{?python_provide:%python_provide python2-vigra}
# Remove before F30
Provides: %{name}-python = %{version}-%{release}
Provides: %{name}-python%{?_isa} = %{version}-%{release}
Obsoletes: %{name}-python < %{version}-%{release}
Summary: Python interface for the vigra computer vision library
Requires: %{name}%{?_isa} = %{version}-%{release}
Requires: python2-numpy python2-numpy-f2py
%description -n python2-vigra
The python2-vigra package provides python 2 bindings for vigra
%package -n python3-vigra
%{?python_provide:%python_provide python3-vigra}
Summary: Python 3 interface for the vigra computer vision library
@ -97,16 +87,11 @@ The python3-vigra package provides python 3 bindings for vigra
sed -i '1s=^#!/usr/bin/\(python\|env python\)[0-9.]*=#!%{__python3}=' \
config/vigra-config.in
mkdir buildpy2
pushd buildpy2
%cmake .. -DWITH_OPENEXR=1 -DWITH_HDF5=1 -DWITH_VALGRIND=0 -DWITH_LEMON=0\
-DWITH_VIGRANUMPY=1 -DPYTHON_VERSION=%{python2_version}
make VERBOSE=1 %{?_smp_mflags}
popd
mkdir buildpy3
pushd buildpy3
%cmake .. -DWITH_OPENEXR=1 -DWITH_HDF5=1 -DWITH_VALGRIND=0 -DWITH_LEMON=0 \
-DWITH_VIGRANUMPY=1 -DPYTHON_VERSION=%{python3_version}
make VERBOSE=1 %{?_smp_mflags}
popd
%else
sed -i '1s=^#!/usr/bin/\(python\|env python\)[0-9.]*=#!%{__python}=' \
@ -126,10 +111,6 @@ find ./doc/ -type f | xargs chmod -x
rm -rf %{buildroot}
%if ! 0%{?rhel}
make -C buildpy2 install DESTDIR=%{buildroot}
mv %{buildroot}/%{_libdir}/vigranumpy/VigranumpyConfig.cmake \
%{buildroot}/%{_libdir}/vigranumpy/Vigranumpy2Config.cmake
make -C buildpy3 install DESTDIR=%{buildroot}
mv %{buildroot}/%{_libdir}/vigranumpy/VigranumpyConfig.cmake \
%{buildroot}/%{_libdir}/vigranumpy/Vigranumpy3Config.cmake
@ -164,18 +145,16 @@ install -p -m755 -D %{SOURCE1} $RPM_BUILD_ROOT%{_bindir}/vigra-config
%doc doc/vigra doc/vigranumpy
%if ! 0%{?rhel}
%files -n python2-vigra
%{python2_sitearch}/vigra
%{_libdir}/vigranumpy
%exclude %{_libdir}/vigranumpy/Vigranumpy3Config.cmake
%files -n python3-vigra
%{python3_sitearch}/vigra
%{_libdir}/vigranumpy
%exclude %{_libdir}/vigranumpy/Vigranumpy2Config.cmake
%endif
%changelog
* Tue Jan 15 2019 Miro Hrončok <mhroncok@redhat.com> - 1.11.1-11
- Subpackage python2-vigra has been removed
See https://fedoraproject.org/wiki/Changes/Mass_Python_2_Package_Removal
* Wed Aug 22 2018 Bruno Postle <bruno@postle.net> - 1.11.1-10
- Patched for python 3.7