File libxfce4util.spec of Package libxfce4util

#
# spec file for package libxfce4util
#
# Copyright (c) 2015 SUSE LINUX 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 libname libxfce4util7
Name:           libxfce4util
Version:        4.12.1
Release:        0
Summary:        Utility Library for the Xfce Desktop Environment
License:        LGPL-2.1+
Group:          System/Libraries
Url:            http://www.xfce.org/
Source:         http://archive.xfce.org/src/xfce/libxfce4util/4.12/%{name}-%{version}.tar.bz2
Source100:      %{name}-rpmlintrc
# PATCH-FEATURE-OPENSUSE libxfce4util-xfce-rc-i18n.patch bnc#829113 gber@opensuse.org -- Translate Name, GenericName, and Comment entries of desktop files via gettext when read via the xfce_rc_* API
Patch0:         libxfce4util-xfce-rc-i18n.patch
BuildRequires:  intltool
BuildRequires:  perl
BuildRequires:  pkgconfig(glib-2.0)
BuildRequires:  pkgconfig(gtk-doc)
BuildRoot:      %{_tmppath}/%{name}-%{version}-build

%description
libxfce4util is a general-purpose utility library with core application support
for the Xfce Desktop Environment.

%package tools
Summary:        Tools for libxfce4util
Group:          System/Libraries
Provides:       libxfce4util:%{_sbindir}/xfce4-kiosk-query

%description tools
This package contains tools for libxfce4util.

%package -n %{libname}
Summary:        Utility Library for the Xfce Desktop Environment
Group:          System/Libraries
Recommends:     %{name}-lang = %{version}
Provides:       libxfce4util = %{version}
Obsoletes:      libxfce4util <= 4.8.2

%description -n %{libname}
libxfce4util is a general-purpose utility library with core application support
for the Xfce Desktop Environment.

%package devel
Summary:        Development Files for libxfce4util
Group:          Development/Libraries/C and C++
Requires:       %{libname} = %{version}
Requires:       %{name}-tools = %{version}

%description devel
This package contains the API documentation and development files needed for
developing applications based on libxfce4util.

# this should be replaced by %%lang_package once bnc#513786 is resolved
%package lang
Summary:        Languages for package %{name}
Group:          System/Localization
Requires:       %{libname} = %{version}
Provides:       %{name}-lang-all = %{version}
Supplements:    packageand(bundle-lang-other:%{libname})
BuildArch:      noarch

%description lang
Provides translations to the package %{name}

%prep
%setup -q
%patch0 -p1

%build
%configure \
    --disable-static \
    --enable-gtk-doc
make %{?_smp_mflags} V=1

%install
%make_install

find %{buildroot} -type f -name "*.la" -delete -print

rm -rf %{buildroot}%{_datadir}/locale/{ast,kk,ur_PK,tl_PH}

%find_lang %{name} %{?no_lang_C}

%post -n %{libname} -p /sbin/ldconfig

%postun -n %{libname} -p /sbin/ldconfig

%files tools
%defattr(-,root,root)
%{_sbindir}/xfce4-kiosk-query

%files lang -f %{name}.lang
%defattr(-,root,root)

%files -n %{libname}
%defattr(-,root,root)
%doc AUTHORS COPYING ChangeLog NEWS TODO README README.Kiosk
%{_libdir}/libxfce4util.so.*

%files devel
%defattr(-, root, root)
%{_libdir}/pkgconfig/libxfce4util-*.pc
%{_libdir}/libxfce4util.so
%dir %{_includedir}/xfce4
%{_includedir}/xfce4/libxfce4util/
%dir %{_datadir}/gtk-doc
%dir %{_datadir}/gtk-doc/html
%{_datadir}/gtk-doc/html/libxfce4util

%changelog
openSUSE Build Service is sponsored by