[packages/gtkspell3] - updated to 3.0.9 - package also gtk2 variant

qboosh qboosh at pld-linux.org
Sat Dec 10 19:05:07 CET 2016


commit 6874cc5169c18f0ec6638418c833e15fea9e6dcb
Author: Jakub Bogusz <qboosh at pld-linux.org>
Date:   Sat Dec 10 19:05:42 2016 +0100

    - updated to 3.0.9
    - package also gtk2 variant

 gtkspell3.spec | 226 ++++++++++++++++++++++++++++++++++++++++++++++-----------
 1 file changed, 183 insertions(+), 43 deletions(-)
---
diff --git a/gtkspell3.spec b/gtkspell3.spec
index 744642a..d9e61e6 100644
--- a/gtkspell3.spec
+++ b/gtkspell3.spec
@@ -1,18 +1,18 @@
-# TODO
-# - gtk+2 bindings possible besides gtk+3 as well
 #
 # Conditional build:
-%bcond_without	vala		# do not build Vala API
+%bcond_without	gtk2	# GTK+ 2.x variant
+%bcond_without	gtk3	# GTK+ 3.x variant
+%bcond_without	vala	# Vala API
 
-Summary:	GTK+ Spell Checker Interface Library
-Summary(pl.UTF-8):	Biblioteka z interfejsem do narzędzia sprawdzającego pisownię dla GTK+
+Summary:	GTK+ 3 Spell Checker Interface Library
+Summary(pl.UTF-8):	Biblioteka z interfejsem do narzędzia sprawdzającego pisownię dla GTK+ 3
 Name:		gtkspell3
-Version:	3.0.7
-Release:	2
+Version:	3.0.9
+Release:	1
 License:	GPL
 Group:		X11/Libraries
-Source0:	http://gtkspell.sourceforge.net/download/%{name}-%{version}.tar.gz
-# Source0-md5:	f15a7c29b71d6ae343c783af3571c8d2
+Source0:	http://downloads.sourceforge.net/gtkspell/%{name}-%{version}.tar.xz
+# Source0-md5:	22c6c44c7cbebfc02e6255cc151a7967
 URL:		http://gtkspell.sourceforge.net/
 BuildRequires:	autoconf >= 2.62
 BuildRequires:	automake
@@ -20,7 +20,8 @@ BuildRequires:	docbook-dtd42-xml
 BuildRequires:	enchant-devel >= 0.4.0
 BuildRequires:	gettext-tools
 BuildRequires:	gobject-introspection-devel >= 1.30.0
-BuildRequires:	gtk+3-devel >= 3
+%{?with_gtk2:BuildRequires:	gtk+2-devel >= 1:2.0}
+%{?with_gtk3:BuildRequires:	gtk+3-devel >= 3.0}
 BuildRequires:	gtk-doc >= 1.14
 BuildRequires:	intltool >= 0.35.0
 BuildRequires:	iso-codes
@@ -28,6 +29,9 @@ BuildRequires:	libtool
 BuildRequires:	pango-devel >= 1:1.13.3
 BuildRequires:	pkgconfig
 %{?with_vala:BuildRequires:	vala >= 2:0.18.0}
+BuildRequires:	tar >= 1:1.22
+BuildRequires:	xz
+Requires:	%{name}-common = %{version}-%{release}
 BuildRoot:	%{tmpdir}/%{name}-%{version}-root-%(id -u -n)
 
 %description
@@ -35,36 +39,150 @@ GtkSpell provides MSWord/MacOSX-style highlighting of misspelled words
 in a GtkTextView widget. Right-clicking a misspelled word pops up a
 menu of suggested replacements.
 
+This package contains GtkSpell3 version for GTK+ 3.
+
 %description -l pl.UTF-8
 GtkSpell udostępnia podobne do MS Worda lub MacOSX podświetlanie
 błędnie napisanych słów w widgecie GtkTextView. Kliknięcie prawym
 przyciskiem na błędne słowo otwiera menu z sugerowanymi poprawkami.
 
+Ten pakiet zawiera wersję biblioteki GtkSpell3 dla GTK+ 3.
+
 %package devel
-Summary:	Header files for GtkSpell API version 3.0
-Summary(pl.UTF-8):	Pliki nagłówkowe dla gtkspella
+Summary:	Development files for GtkSpell3 for GTK+ 3
+Summary(pl.UTF-8):	Pliki programistyczne biblioteki GtkSpell3 dla GTK+ 3
 Group:		X11/Development/Libraries
 Requires:	%{name} = %{version}-%{release}
+Requires:	%{name}-common-devel = %{version}-%{release}
 Requires:	enchant-devel >= 0.4.0
-Requires:	gtk+3-devel >= 3
+Requires:	gtk+3-devel >= 3.0
 
 %description devel
-Header files for GtkSpell API version 3.0.
+Development files for GtkSpell3 for GTK+ 3.
 
 %description devel -l pl.UTF-8
-Pliki nagłówkowe dla gtkspella.
+Pliki programistyczne biblioteki GtkSpell3 dla GTK+ 3.
 
 %package static
-Summary:	Static libraries for GtkSpell
-Summary(pl.UTF-8):	Biblioteki statyczne dla gtkspella
+Summary:	Static GtkSpell3 library for GTK+ 3
+Summary(pl.UTF-8):	Biblioteka statyczna GtkSpell3 dla GTK+ 3
 Group:		X11/Development/Libraries
 Requires:	%{name}-devel = %{version}-%{release}
 
 %description static
-Static libraries for GtkSpell.
+Static GtkSpell3 library for GTK+ 3.
 
 %description static -l pl.UTF-8
-Biblioteki statyczne dla gtkspella.
+Biblioteka statyczna GtkSpell3 dla GTK+ 3.
+
+%package -n vala-%{name}
+Summary:	GtkSpell3 API for Vala language (GTK+ 3 variant)
+Summary(pl.UTF-8):	API GtkSpell3 dla języka Vala (wersja dla GTK+ 3)
+Group:		Development/Libraries
+Requires:	%{name}-devel = %{version}-%{release}
+Requires:	vala >= 2:0.18.0
+%if "%{_rpmversion}" >= "5"
+BuildArch:	noarch
+%endif
+
+%description -n vala-%{name}
+GtkSpell3 API for Vala language (GTK+ 3 variant).
+
+%description -n vala-%{name} -l pl.UTF-8
+API GtkSpell3 dla języka Vala (wersja dla GTK+ 3).
+
+%package gtk2
+Summary:	GTK+ 2 Spell Checker Interface Library
+Summary(pl.UTF-8):	Biblioteka z interfejsem do narzędzia sprawdzającego pisownię dla GTK+ 2
+Group:		X11/Libraries
+Requires:	%{name}-common = %{version}-%{release}
+
+%description gtk2
+GtkSpell provides MSWord/MacOSX-style highlighting of misspelled words
+in a GtkTextView widget. Right-clicking a misspelled word pops up a
+menu of suggested replacements.
+
+This package contains GtkSpell3 version for GTK+ 2.
+
+%description gtk2 -l pl.UTF-8
+GtkSpell udostępnia podobne do MS Worda lub MacOSX podświetlanie
+błędnie napisanych słów w widgecie GtkTextView. Kliknięcie prawym
+przyciskiem na błędne słowo otwiera menu z sugerowanymi poprawkami.
+
+Ten pakiet zawiera wersję biblioteki GtkSpell3 dla GTK+ 2.
+
+%package gtk2-devel
+Summary:	Development files for GtkSpell3 for GTK+ 2
+Summary(pl.UTF-8):	Pliki programistyczne biblioteki GtkSpell3 dla GTK+ 2
+Group:		X11/Development/Libraries
+Requires:	%{name}-common-devel = %{version}-%{release}
+Requires:	%{name}-gtk2 = %{version}-%{release}
+Requires:	enchant-devel >= 0.4.0
+Requires:	gtk+2-devel >= 1:2.0
+
+%description gtk2-devel
+Development files for GtkSpell3 for GTK+ 2.
+
+%description gtk2-devel -l pl.UTF-8
+Pliki programistyczne biblioteki GtkSpell3 dla GTK+ 2.
+
+%package gtk2-static
+Summary:	Static GtkSpell3 library for GTK+ 2
+Summary(pl.UTF-8):	Biblioteka statyczna GtkSpell3 dla GTK+ 2
+Group:		X11/Development/Libraries
+Requires:	%{name}-gtk2-devel = %{version}-%{release}
+
+%description gtk2-static
+Static GtkSpell3 library for GTK+ 2.
+
+%description gtk2-static -l pl.UTF-8
+Biblioteka statyczna GtkSpell3 dla GTK+ 2.
+
+%package -n vala-%{name}-gtk2
+Summary:	GtkSpell3 API for Vala language (GTK+ 2 variant)
+Summary(pl.UTF-8):	API GtkSpell3 dla języka Vala (wersja dla GTK+ 2)
+Group:		Development/Libraries
+Requires:	%{name}-gtk2-devel = %{version}-%{release}
+Requires:	vala >= 2:0.18.0
+%if "%{_rpmversion}" >= "5"
+BuildArch:	noarch
+%endif
+
+%description -n vala-%{name}-gtk2
+GtkSpell3 API for Vala language (GTK+ 2 variant).
+
+%description -n vala-%{name}-gtk2 -l pl.UTF-8
+API GtkSpell3 dla języka Vala (wersja dla GTK+ 2).
+
+%package common
+Summary:	Common files for GtkSpell3 libraries
+Summary(pl.UTF-8):	Pliki wspólne bibliotek GtkSpell3
+Group:		Libraries
+Conflicts:	gtkspell3 < 3.0.9
+%if "%{_rpmversion}" >= "5"
+BuildArch:	noarch
+%endif
+
+%description common
+Common files for GtkSpell3 libraries.
+
+%description common -l pl.UTF-8
+Pliki wspólne bibliotek GtkSpell3.
+
+%package common-devel
+Summary:	Common headers for GtkSpell3 libraries
+Summary(pl.UTF-8):	Wspólne pliki nagłówkowe bibliotek GtkSpell3
+Group:		Development/Libraries
+Requires:	%{name}-common = %{version}-%{release}
+%if "%{_rpmversion}" >= "5"
+BuildArch:	noarch
+%endif
+
+%description common-devel
+Common headers for GtkSpell3 libraries.
+
+%description common-devel -l pl.UTF-8
+Wspólne pliki nagłówkowe bibliotek GtkSpell3.
 
 %package apidocs
 Summary:	GtkSpell API documentation
@@ -81,22 +199,6 @@ GtkSpell API documentation.
 %description apidocs -l pl.UTF-8
 Dokumentacja API gtkspell.
 
-%package -n vala-%{name}
-Summary:	GtkSpell API for Vala language
-Summary(pl.UTF-8):	API GtkSpell dla języka Vala
-Group:		Development/Libraries
-Requires:	%{name}-devel = %{version}-%{release}
-Requires:	vala >= 2:0.18.0
-%if "%{_rpmversion}" >= "5"
-BuildArch:	noarch
-%endif
-
-%description -n vala-%{name}
-GtkSpell API for Vala language.
-
-%description -n vala-%{name} -l pl.UTF-8
-API GtkSpell dla języka Vala.
-
 %prep
 %setup -q
 
@@ -110,6 +212,8 @@ API GtkSpell dla języka Vala.
 %configure \
 	--disable-silent-rules \
 	--enable-gtk-doc \
+	%{?with_gtk2:--enable-gtk2} \
+	%{!?with_gtk3:--disable-gtk2} \
 	--with-html-dir=%{_gtkdocdir}
 %{__make}
 
@@ -119,7 +223,7 @@ rm -rf $RPM_BUILD_ROOT
 	DESTDIR=$RPM_BUILD_ROOT \
 	pkgconfigdir=%{_pkgconfigdir}
 
-%{__rm} $RPM_BUILD_ROOT%{_libdir}/libgtkspell3-3.la
+%{__rm} $RPM_BUILD_ROOT%{_libdir}/libgtkspell3-*.la
 
 %{__rm} -r $RPM_BUILD_ROOT%{_localedir}/son
 
@@ -131,9 +235,12 @@ rm -rf $RPM_BUILD_ROOT
 %post   -p /sbin/ldconfig
 %postun -p /sbin/ldconfig
 
-%files -f %{name}.lang
+%post   gtk2 -p /sbin/ldconfig
+%postun gtk2 -p /sbin/ldconfig
+
+%if %{with gtk3}
+%files
 %defattr(644,root,root,755)
-%doc AUTHORS ChangeLog README
 %attr(755,root,root) %{_libdir}/libgtkspell3-3.so.*.*.*
 %attr(755,root,root) %ghost %{_libdir}/libgtkspell3-3.so.0
 %{_libdir}/girepository-1.0/GtkSpell-3.0.typelib
@@ -141,7 +248,6 @@ rm -rf $RPM_BUILD_ROOT
 %files devel
 %defattr(644,root,root,755)
 %attr(755,root,root) %{_libdir}/libgtkspell3-3.so
-%{_includedir}/gtkspell-3.0
 %{_pkgconfigdir}/gtkspell3-3.0.pc
 %{_datadir}/gir-1.0/GtkSpell-3.0.gir
 
@@ -149,13 +255,47 @@ rm -rf $RPM_BUILD_ROOT
 %defattr(644,root,root,755)
 %{_libdir}/libgtkspell3-3.a
 
-%files apidocs
-%defattr(644,root,root,755)
-%{_gtkdocdir}/gtkspell3
-
 %if %{with vala}
 %files -n vala-%{name}
 %defattr(644,root,root,755)
 %{_datadir}/vala/vapi/gtkspell3-3.0.deps
 %{_datadir}/vala/vapi/gtkspell3-3.0.vapi
 %endif
+%endif
+
+%if %{with gtk2}
+%files gtk2
+%defattr(644,root,root,755)
+%attr(755,root,root) %{_libdir}/libgtkspell3-2.so.*.*.*
+%attr(755,root,root) %ghost %{_libdir}/libgtkspell3-2.so.0
+%{_libdir}/girepository-1.0/GtkSpell-2.0.typelib
+
+%files gtk2-devel
+%defattr(644,root,root,755)
+%attr(755,root,root) %{_libdir}/libgtkspell3-2.so
+%{_pkgconfigdir}/gtkspell3-2.0.pc
+%{_datadir}/gir-1.0/GtkSpell-2.0.gir
+
+%files gtk2-static
+%defattr(644,root,root,755)
+%{_libdir}/libgtkspell3-2.a
+
+%if %{with vala}
+%files -n vala-%{name}-gtk2
+%defattr(644,root,root,755)
+%{_datadir}/vala/vapi/gtkspell3-2.0.deps
+%{_datadir}/vala/vapi/gtkspell3-2.0.vapi
+%endif
+%endif
+
+%files common -f %{name}.lang
+%defattr(644,root,root,755)
+%doc AUTHORS ChangeLog README
+
+%files common-devel
+%defattr(644,root,root,755)
+%{_includedir}/gtkspell-3.0
+
+%files apidocs
+%defattr(644,root,root,755)
+%{_gtkdocdir}/gtkspell3
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/packages/gtkspell3.git/commitdiff/6874cc5169c18f0ec6638418c833e15fea9e6dcb



More information about the pld-cvs-commit mailing list