From a5abdaf1b75af96dbec6cd512d64da5d7de0cd50 Mon Sep 17 00:00:00 2001 From: Nils Philippsen Date: Nov 26 2015 01:16:37 +0000 Subject: rename python subpackage to python2, add python3 subpackage --- diff --git a/aubio.spec b/aubio.spec index 33e229f..1595129 100644 --- a/aubio.spec +++ b/aubio.spec @@ -21,10 +21,10 @@ BuildRequires: fftw-devel BuildRequires: jack-audio-connection-kit-devel BuildRequires: libsamplerate-devel BuildRequires: libsndfile-devel -BuildRequires: numpy +BuildRequires: numpy python3-numpy BuildRequires: pkgconfig -BuildRequires: python2-devel -BuildRequires: python2-setuptools +BuildRequires: python2-devel python3-devel +BuildRequires: python2-setuptools python3-setuptools BuildRequires: txt2man %description @@ -49,18 +49,33 @@ Requires: pkgconfig The %{name}-devel package contains libraries and header files for developing applications that use %{name}. -%package python -Summary: Python language bindings for %{name} +%package python2 +Summary: Python 2 language bindings for %{name} Group: Development/Libraries Requires: %{name} = %{version}-%{release} -Requires: python +Requires: python2 +Obsoletes: %{name}-python < 0.4.0 -%description python -The %{name}-python package contains the Python language bindings for %{name}. +%description python2 +The %{name}-python2 package contains the Python 2 language bindings for +%{name}. + +%package python3 +Summary: Python 3 language bindings for %{name} +Group: Development/Libraries +Requires: %{name} = %{version}-%{release} +Requires: python3 + +%description python3 +The %{name}-python3 package contains the Python 3 language bindings for +%{name}. %prep %autosetup -p1 +# copy python directory for Python 2 support +rm -rf python2 +cp -r python python2 %build ./waf configure \ @@ -79,20 +94,27 @@ The %{name}-python package contains the Python language bindings for %{name}. ./waf build %{_verbose} %{?_smp_mflags} -pushd python +pushd python2 %py2_build popd +pushd python +%py3_build +popd + %install ./waf --destdir=%{buildroot} %{_verbose} install rm -rf libaubio-doc cp -r %{buildroot}%{_docdir}/libaubio-doc libaubio-doc rm -rf %{buildroot}%{_docdir}/libaubio-doc -pushd python +pushd python2 %py2_install popd +pushd python +%py3_install +popd %post -p /sbin/ldconfig @@ -112,10 +134,14 @@ popd %{_libdir}/*.so %{_includedir}/aubio -%files python +%files python2 %{python2_sitearch}/%{name} %{python2_sitearch}/%{name}*.egg-info +%files python3 +%{python3_sitearch}/%{name} +%{python3_sitearch}/%{name}*.egg-info + %changelog * Thu Nov 26 2015 Nils Philippsen - 0.4.2-1 - version 0.4.2 @@ -123,6 +149,7 @@ popd - use %%autosetup macro - remove some old cruft - waf: build verbosely +- rename python subpackage to python2, add python3 subpackage * Wed Jun 17 2015 Fedora Release Engineering - 0.3.2-17 - Rebuilt for https://fedoraproject.org/wiki/Fedora_23_Mass_Rebuild