[caribou] Added python3 subpackage
Parag Nemade
pnemade at fedoraproject.org
Fri Feb 20 14:55:18 UTC 2015
commit cf4188431c8672e7b0b5079bef9de9cde426c6f7
Author: Parag Nemade <pnemade at redhat.com>
Date: Fri Feb 20 20:25:12 2015 +0530
Added python3 subpackage
caribou.spec | 41 ++++++++++++++++++++++++++++++++++++++---
1 file changed, 38 insertions(+), 3 deletions(-)
---
diff --git a/caribou.spec b/caribou.spec
index 760acbf..cb6f217 100644
--- a/caribou.spec
+++ b/caribou.spec
@@ -1,6 +1,8 @@
+%global with_python3 1
+
Name: caribou
Version: 0.4.17
-Release: 1%{?dist}
+Release: 2%{?dist}
Summary: A simplified in-place on-screen keyboard
License: LGPLv2+
URL: http://live.gnome.org/Caribou
@@ -24,6 +26,10 @@ BuildRequires: libgee-devel
BuildRequires: gobject-introspection-devel
BuildRequires: at-spi2-core-devel
+%if 0%{?with_python3}
+BuildRequires: python3-devel
+%endif # with_python3
+
Requires: python-%{name} = %{version}-%{release}
Requires: gobject-introspection
Requires: caribou-gtk2-module
@@ -59,6 +65,19 @@ BuildArch: noarch
%description -n python-caribou
This package contains caribou python GUI
+%if 0%{?with_python3}
+%package -n python3-caribou
+Summary: Keyboard UI for %{name}
+Requires: pygobject3
+Requires: pyatspi
+Requires: %{name} = %{version}-%{release}
+Obsoletes: caribou < 0.4.1-3
+BuildArch: noarch
+
+%description -n python3-caribou
+This package contains caribou python3 GUI
+%endif
+
%package gtk2-module
Summary: Gtk2 module for %{name}
Requires: %{name}%{?_isa} = %{version}-%{release}
@@ -94,8 +113,16 @@ non-gnome-shell sessions.
make V=1 %{?_smp_mflags}
%install
-make install DESTDIR=$RPM_BUILD_ROOT INSTALL="install -p"
-find $RPM_BUILD_ROOT -name '*.la' -exec rm -f {} ';'
+make install DESTDIR=%{buildroot} INSTALL="install -p"
+
+%if 0%{?with_python3}
+make clean
+%configure --disable-static PYTHON=python3
+2to3 -w caribou
+make install DESTDIR=%{buildroot}
+%endif
+
+find %{buildroot} -name '*.la' -exec rm -f {} ';'
desktop-file-validate $RPM_BUILD_ROOT%{_sysconfdir}/xdg/autostart/caribou-autostart.desktop || :
desktop-file-validate $RPM_BUILD_ROOT%{_libdir}/gnome-settings-daemon-3.0/gtk-modules/caribou-gtk-module.desktop || :
@@ -136,6 +163,11 @@ fi
%files -n python-caribou
%{python_sitelib}/caribou
+%if 0%{?with_python3}
+%files -n python3-caribou
+%{python3_sitelib}/caribou
+%endif
+
%files devel
%{_includedir}/*
%{_libdir}/*.so
@@ -157,6 +189,9 @@ fi
%changelog
+* Fri Feb 20 2015 Parag Nemade <pnemade AT redhat DOT com> - 0.4.17-2
+- Added python3 subpackage
+
* Tue Feb 17 2015 Parag Nemade <pnemade AT redhat DOT com> - 0.4.17-1
- Update to 0.4.17
More information about the scm-commits
mailing list