File gtkspell.spec of Package gtkspell

#
# spec file for package gtkspell
#
# Copyright (c) 2011 SUSE LINUX Products GmbH, Nuernberg, Germany.
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.

# Please submit bugfixes or comments via http://bugs.opensuse.org/
#



Name:           gtkspell
Version:        2.0.16
Release:        5
# FIXME: Replace Obsoletes <= version with Obsoletes < version in libgtkspell0 subpackage on update (after 2.0.16)
License:        GPL-2.0+
Summary:        GTK2 Spell Checker Interface Library
Url:            http://gtkspell.sf.net/
Group:          System/Libraries
Source:         %{name}-%{version}.tar.gz
BuildRequires:  enchant-devel
BuildRequires:  fdupes
BuildRequires:  gnome-doc-utils-devel
BuildRequires:  gtk-doc
BuildRequires:  gtk2-devel
BuildRequires:  intltool
BuildRequires:  libstdc++-devel
BuildRequires:  translation-update-upstream
BuildRoot:      %{_tmppath}/%{name}-%{version}-build

%description
GtkSpell provides MSWord-style and MacOSX-style highlighting of
misspelled words in a GtkTextView widget. Right-clicking a misspelled
word opens a menu of suggested replacements.

%package -n libgtkspell0
License:        GPL-2.0+
Summary:        GTK2 Spell Checker Interface Library
Group:          System/Libraries
Recommends:     %{name}-lang
# Needed to make lang package installable
Provides:       gtkspell = %{version}
# SLPP applied during development of 12.1. gtkspell last shipped in 11.4
# Change <= to < on update to new version (> 2.0.16)
Obsoletes:      gtkspell <= %{version}

%description -n libgtkspell0
GtkSpell provides MSWord-style and MacOSX-style highlighting of
misspelled words in a GtkTextView widget. Right-clicking a misspelled
word opens a menu of suggested replacements.

%package      devel
License:        GPL-2.0+
Summary:        Static libraries and header files from gtkspell
Group:          Development/Libraries/X11
Requires:       libgtkspell0 = %{version}

%description devel
Static libraries and header files from gtkspell.

%package      doc
License:        GPL-2.0+
Summary:        GTK2 Spell Checker Interface Library
Group:          System/Libraries
Requires:       libgtkspell0 = %{version}

%description doc
GtkSpell provides MSWord-style and MacOSX-style highlighting of
misspelled words in a GtkTextView widget. Right-clicking a misspelled
word opens a menu of suggested replacements.

%lang_package
%prep
%setup -q %{name}-%{version}
translation-update-upstream

%build
%configure\
	--disable-static
make %{?_smp_mflags}

%install
%makeinstall
find %{buildroot}%{_libdir} -name '*.la' -type f -delete -print
%find_lang %{name}

%post -n libgtkspell0 -p /sbin/ldconfig

%postun -n libgtkspell0 -p /sbin/ldconfig

%clean
rm -rf %{buildroot}

%files -n libgtkspell0
%defattr(-, root, root)
%doc AUTHORS COPYING ChangeLog README
%{_libdir}/*.so.*

%files lang -f %{name}.lang

%files devel
%defattr(-, root, root)
%{_includedir}/gtkspell-2.0
%{_libdir}/*.so
%{_libdir}/pkgconfig/*.pc

%files doc
%defattr(-, root, root)
%{_datadir}/gtk-doc/html/*

%changelog