Summary:        A keyboard configuration library
Summary(ja):	キーボード設定ライブラリ
Name:           libgnomekbd
Version:       	3.6.0
Release:        2%{?_dist_release}
Group:          System Environment/Libraries
License:        LGPL
URL:            http://gswitchit.sourceforce.net
Source0:        http://ftp.gnome.org/pub/gnome/sources/libgnomekbd/3.6/libgnomekbd-%{version}.tar.xz

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

BuildRequires:  gtk3-devel >= 2.91.7
BuildRequires:  libxklavier-devel >= 5.0
BuildRequires:  libSM-devel
BuildRequires:  desktop-file-utils
BuildRequires:  perl(XML::Parser)
BuildRequires:  gettext
BuildRequires:  intltool

Requires(pre): glib2
Requires(post): glib2
Requires(preun): glib2

Vendor: Project Vine
Distribution: Vine Linux
Packager: Takemikaduchi

%description
The libgnomekbd package contains a GNOME library which manages
keyboard configuration and offers various widgets related to 
keyboard configuration.


%package        devel
Summary:        Development files for %{name}
Group:          Development/Libraries
Requires:       %{name} = %{version}-%{release}
Requires:       libxklavier-devel >= 5.0
Requires:       pkgconfig

%description    devel
The libgnomekbd-devel package contains libraries and header files for
developing applications that use libgnomekbd.


%prep
%setup -q

%build
%configure --disable-static --enable-compile-warnings=no
%__make %{?_smp_mflags}


%install
rm -rf $RPM_BUILD_ROOT
make install DESTDIR=$RPM_BUILD_ROOT
find $RPM_BUILD_ROOT -name '*.la' -exec rm -f {} ';'

%find_lang %{name}


%clean
rm -rf $RPM_BUILD_ROOT

%post 
/sbin/ldconfig
touch --no-create %{_datadir}/icons/hicolor || :
if [ -x %{_bindir}/gtk-update-icon-cache ]; then
  %{_bindir}/gtk-update-icon-cache --quiet %{_datadir}/icons/hicolor || :
fi
update-desktop-database &> /dev/null ||:

%posttrans
gtk-update-icon-cache --quiet %{_datadir}/icons/hicolor || :
%{_bindir}/glib-compile-schemas %{_datadir}/glib-2.0/schemas || :


%postun 
/sbin/ldconfig
touch --no-create %{_datadir}/icons/hicolor || :
if [ -x %{_bindir}/gtk-update-icon-cache ]; then
  %{_bindir}/gtk-update-icon-cache --quiet %{_datadir}/icons/hicolor || :
fi
%{_bindir}/glib-compile-schemas %{_datadir}/glib-2.0/schemas || :


%files -f %{name}.lang
%defattr(-,root,root,-)
%doc AUTHORS COPYING.LIB
%{_bindir}/gkbd-keyboard-display
%{_libdir}/*.so.*
%{_libdir}/girepository-1.0/Gkbd-3.0.typelib
%{_datadir}/applications/gkbd-keyboard-display.desktop
%{_datadir}/glib-2.0/schemas/*.xml
%{_datadir}/libgnomekbd/ui/*
%{_datadir}/libgnomekbd/icons/*.svg
%{_datadir}/GConf/gsettings/libgnomekbd.convert

%files devel
%defattr(-,root,root,-)
%{_includedir}/libgnomekbd/*
%{_libdir}/*.so
%{_libdir}/pkgconfig/libgnomekbd.pc
%{_libdir}/pkgconfig/libgnomekbdui.pc
%{_datadir}/gir-1.0/Gkbd-3.0.gir


%changelog
* Tue Dec 31 2013 Yoji TOYODA <bsyamato@sea.plala.or.jp> 3.6.0-2
- rebuild with VineSeed environment

* Thu Sep 27 2012 Yoji TOYODA <bsyamato@sea.plala.or.jp> 3.6.0-1
- new upstream release

* Sun Apr 29 2012 Yoji TOYODA <bsyamato@sea.plala.or.jp> 3.4.0.2-1
- new upstream release

* Wed Sep 28 2011 Yoji TOYODA <bsyamato@sea.plala.or.jp> 3.2.0-1
- new upstream release
- add BuildRequires: libSM-devel

* Fri Sep 23 2011 Yoji TOYODA <bsyamato@sea.plala.or.jp> 3.1.92-1
- new upstream release

* Sun Aug 14 2011 Yoji TOYODA <bsyamato@sea.plala.or.jp> 3.0.0-1
- new upstream release
- change BuildRequires: gtk3-devel instead of gtk2-devel

* Sat Oct 02 2010 Yoji TOYODA <bsyamato@sea.plala.or.jp> 2.32.0-1
- new upstream release
- remove BuildRequires: libgnomeui-devel

* Thu Sep 23 2010 Yoji TOYODA <bsyamato@sea.plala.or.jp> 2.30.2-2
- rebuild with rpm-4.8.1 for pkg-config file

* Sat Jun 26 2010 Yoji TOYODA <bsyamato@sea.plala.or.jp> 2.30.2-1
- new upstream release

* Sat May 01 2010 Yoji TOYODA <bsyamato@sea.plala.or.jp> 2.30.1-1
- new upstream release
- drop Patch1

* Sat Apr 17 2010 Daisuke SUZUKI <daisuke@linux.or.jp> 2.30.0-2
- remove old Patches
- add Patch1 to fix invalid default value in schema
  https://bugzilla.gnome.org/show_bug.cgi?id=615077

* Wed Mar 31 2010 Yoji TOYODA <bsyamato@sea.plala.or.jp> 2.30.0-1
- new upstream release
- fix BuildRequires: libxklavier-devel >= 5.0

* Sun Mar 14 2010 Yoji TOYODA <bsyamato@sea.plala.or.jp> 2.28.2-1
- new upstream release

* Sat Oct 31 2009 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 2.28.0-1
- new upstream release
- remove BR: libglade2-devel

* Sat Mar 21 2009 Daisuke SUZUKI <daisuke@linux.or.jp> 2.26.0-1
- new upstream release

* Wed Sep 24 2008 Daisuke SUZUKI <daisuke@linux.or.jp> 2.24.0-1
- new upstream release

* Sun Mar 30 2008 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 2.22.0-1vl5
- new upstream release

* Thu Dec 13 2007 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 2.20.0-0vl1
- new upstream release

* Fri Apr 27 2007 Daisuke SUZUKI <daisuke@linux.or.jp> 2.18.0-0vl1
- initial build for Vine Linux

* Tue Mar 13 2007 Matthias Clasen <mclasen@redhat.com> - 2.18.0-1
- Update to 2.18.0

* Wed Jan 24 2007 Matthias Clasen <mclasen@redhat.com> - 2.17.2-2
- Port former control-center patches to improve keyboard drawing

* Tue Nov  7 2006 Matthias Clasen <mclasen@redhat.com> - 2.17.2-1
- Update to 2.17.2

* Tue Nov  7 2006 Matthias Clasen <mclasen@redhat.com> - 0.1-4
- Fix up Requires

* Thu Nov  2 2006 Matthias Clasen <mclasen@redhat.com> - 0.1-3
- Don't use --Werror

* Sat Oct 28 2006 Matthias Clasen <mclasen@redhat.com> - 0.1-2
- Fix a memory allocation error

* Sat Oct 28 2006 Matthias Clasen <mclasen@redhat.com> - 0.1-1
- Initial release
