Summary: Reference GTK+ greeter for LightDM
Name: lightdm-gtk
Version: 1.8.5
Release: 3%{?_dist_release}
License: GPL3
Group: User Interface/X
URL: https://launchpad.net/lightdm-gtk-greeter/

Source: https://launchpad.net/%{name}-greeter/1.8/%{version}/+download/%{name}-greeter-%{version}.tar.gz

# for Vine Linux
Patch1000: lightdm-gtk-greeter-1.8.5-vine.patch
Patch1001: lightdm-gtk-greeter-1.8.5-ja.po.patch
Patch1002: lightdm-gtk-greeter-1.8.5-background.patch

Requires: lightdm
Requires: gnome-icon-theme
Requires: gtk2-engines

BuildRequires: gtk2-devel
BuildRequires: lightdm-gobject-devel
BuildRequires: libX11-devel

Provides: lightdm-greeter

Vendor: Project Vine
Distribution: Vine Linux
Packager: Takemikaduchi


%description
%{summary}


%prep
%setup -q -n %{name}-greeter-%{version}
%patch1000 -p1 -b .vine
%patch1001 -p1 -b .vine
%patch1002 -p1 -b .vine

%build
%configure \
		--with-gtk2=yes

make %{?_smp_mflags}

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

pushd $RPM_BUILD_ROOT%{_datadir}/xgreeters/
	ln -s lightdm-gtk-greeter.desktop lightdm-greeter.desktop
popd

find $RPM_BUILD_ROOT -name '*.a' -delete
find $RPM_BUILD_ROOT -name '*.la' -delete

%find_lang %{name}-greeter


%post -p /sbin/ldconfig

%postun -p /sbin/ldconfig


%files -f %{name}-greeter.lang
%defattr(-, root, root, -)
%doc AUTHORS COPYING ChangeLog NEWS README
%{_sysconfdir}/lightdm/lightdm-gtk-greeter.conf
%{_sbindir}/lightdm-gtk-greeter
%{_docdir}/lightdm-gtk-greeter/sample-lightdm-gtk-greeter.css
%{_datadir}/icons/hicolor/scalable/places/*
%{_datadir}/xgreeters/lightdm-greeter.desktop
%{_datadir}/xgreeters/lightdm-gtk-greeter.desktop


%changelog
* Sat May 09 2015 Yoji TOYODA <bsyamato@sea.plala.or.jp> 1.8.5-3
- add Requires: gnome-icon-theme, gtk2-engines

* Sun Aug 24 2014 Yoji TOYODA <bsyamato@sea.plala.or.jp> 1.8.5-2
- add Patch1002 (lightdm-gtk-greeter-1.8.5-background.patch)

* Sun Jun 01 2014 Yoji TOYODA <bsyamato@sea.plala.or.jp> 1.8.5-1
- initial build

