File xfce4-dict.spec of Package xfce4-dict

#
# spec file for package xfce4-dict
#
# 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/
#


%define panel_version 4.7.0

Name:           xfce4-dict
Version:        0.6.0
Release:        13.<RELEASE3>
License:        GPLv2+
Summary:        Xfce4 Dictionary
Url:            http://goodies.xfce.org/projects/applications/xfce4-dict
Group:          Productivity/Office/Dictionary
Source:         http://goodies.xfce.org/releases/xfce4-dict/%{name}-%{version}.tar.bz2
Patch0:         xfce4-dict-0.6.0-use-correct-xfcepanelplugin-instance.patch
Patch1:         xfce4-dict-0.6.0-fix-wrong-callback-arg.patch
BuildRequires:  intltool
BuildRequires:  perl-XML-Parser
BuildRequires:  pkgconfig(libxfce4panel-1.0)
BuildRequires:  pkgconfig(libxfce4util-1.0)
BuildRequires:  pkgconfig(libxfcegui4-1.0)
BuildRequires:  update-desktop-files
BuildRoot:      %{_tmppath}/%{name}-%{version}-build
Recommends:     %{name}-lang = %{version}
Suggests:       xfce4-panel-plugin-dict

%description
xfce4-dict allows you to search different kinds of dictionary services for
words or phrases and shows you the result. Currently you can query a Dict
server(RFC 2229), any online dictionary service by opening a web browser or
search for words using the aspell/ispell program.

%package -n xfce4-panel-plugin-dict
License:        GPLv2+
Summary:        Dictionary Plugin for the Xfce Panel
Group:          Productivity/Office/Dictionary
Requires:       xfce4-panel >= %panel_version
Requires:       xfce4-dict = %version

%description -n xfce4-panel-plugin-dict
xfce4-dict allows you to search different kinds of dictionary services for
words or phrases and shows you the result. Currently you can query a Dict
server(RFC 2229), any online dictionary service by opening a web browser or
search for words using the aspell/ispell program.

This package contains the panel plugin for the Xfce panel.


%lang_package
%prep
%setup -q
%patch0 -p1
%patch1 -p1

%build
%configure
make %{?_smp_mflags} V=1

%install
%make_install
%suse_update_desktop_file -r %{name} Office Dictionary GTK
rm -rf %{buildroot}%{_datadir}/locale/{ast,kk,tl_PH,ur_PK}
%find_lang %{name}

%clean
rm -rf %{buildroot}

%if 0%{?suse_version} >= 1140

%post
%desktop_database_post
%icon_theme_cache_post

%postun
%desktop_database_postun
%icon_theme_cache_postun
%endif

%files
%defattr(-,root,root)
%doc AUTHORS COPYING ChangeLog README
%{_bindir}/xfce4-dict
%{_datadir}/applications/*.desktop
%{_datadir}/icons/hicolor/*/apps/*
%{_mandir}/man1/xfce4-dict.1*

%files -n xfce4-panel-plugin-dict
%defattr(-,root,root)
%{_libexecdir}/xfce4/panel-plugins/xfce4-dict-plugin
%{_datadir}/xfce4/panel-plugins/*.desktop

%files lang -f %{name}.lang

%changelog