Name:           xfce4-notifyd
Summary:        Notification daemon for Xfce
Summary(ja):    Xfce 用 notification daemon
Version:        0.2.2
Release:        1%{?_dist_release}

License:        GPLv2+
Group:          User Interface/Desktops
URL:            http://goodies.xfce.org/projects/applications/%{name}

Source0:        http://archive.xfce.org/src/apps/%{name}/0.2/%{name}-%{version}.tar.bz2

BuildRoot:     %{_tmppath}/%{name}-%{version}-root

BuildRequires: desktop-file-utils
BuildRequires: libxfce4util-devel >= 4.4.0
BuildRequires: libxfce4ui-devel >= 4.7.0
BuildRequires: xfconf-devel >= 0.1
BuildRequires: gtk2-devel >= 2.14.0
BuildRequires: dbus-glib-devel >= 0.72
BuildRequires: libnotify-devel >= 0.4.4

Requires(post,postun):	desktop-file-utils

Vendor:		Project Vine
Distribution:	Vine Linux
Packager:	Takemikaduchi


%description
The Xfce Notify Daemon (xfce4-notifyd for short) is a smallish program that
implements the "server-side" portion of the Freedesktop desktop notifications
specification.  Applications that wish to pop up a notification bubble in
a standard way can implicitly make use of xfce4-notifyd to do so by
sending standard messages over D-Bus using the org.freedesktop.Notifications
interface.


%prep
%setup -q

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


%install
rm -rf $RPM_BUILD_ROOT
make install DESTDIR=$RPM_BUILD_ROOT

find $RPM_BUILD_ROOT -name '*.la' -exec rm -f {} \;

desktop-file-install \
	--add-category="X-XFCE" \
	--delete-original \
	--dir=%{buildroot}%{_datadir}/applications \
        ${RPM_BUILD_ROOT}%{_datadir}/applications/xfce4-notifyd-config.desktop

%find_lang %{name}

%clean
rm -rf $RPM_BUILD_ROOT


%post
touch --no-create %{_datadir}/icons/hicolor &> /dev/null || :
gtk-update-icon-cache %{_datadir}/icons/hicolor &> /dev/null || :
update-desktop-database %{_datadir}/applications &> /dev/null || :

%postun
if [ $1 -eq 0 ]; then
    touch --no-create %{_datadir}/icons/hicolor &> /dev/null || :
    gtk-update-icon-cache %{_datadir}/icons/hicolor &> /dev/null || :
fi
update-desktop-database %{_datadir}/applications &> /dev/null || :


%files -f %{name}.lang
%defattr(-,root,root,-)
%doc AUTHORS ChangeLog NEWS TODO COPYING
%{_bindir}/%{name}-config
%{_libdir}/xfce4/notifyd/%{name}
%{_datadir}/applications/%{name}-config.desktop
%{_datadir}/dbus-1/services/org.xfce.xfce4-notifyd.Notifications.service
%{_datadir}/icons/hicolor/*/apps/*
%{_datadir}/themes/Default/xfce-notify-4.0
%{_datadir}/themes/Smoke/xfce-notify-4.0
%{_datadir}/themes/ZOMG-PONIES!/xfce-notify-4.0
%{_mandir}/man1/xfce4-notifyd-config.1.gz

%changelog
* Sat Jun 09 2012 Yoji TOYODA <bsyamato@sea.plala.or.jp> 0.2.2-1
- initial build for Vine Linux