ce76083
Name:		imsettings
f06b8c8
Version:	0.104.1
f63f055
Release:	3%{?dist}
ce76083
License:	LGPLv2+
ce76083
URL:		http://code.google.com/p/imsettings/
ce76083
BuildRoot:	%{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
ce76083
BuildRequires:	intltool gettext
ce76083
BuildRequires:	dbus-devel >= 0.23, dbus-glib-devel >= 0.74, glib2 >= 2.16
3266afa
BuildRequires:	libgxim-devel >= 0.2.0, libnotify-devel
ce76083
BuildRequires:	xfce-mcs-manager-devel libxfce4mcs-devel
ce76083
BuildRequires:	GConf2-devel
ce76083
BuildRequires:	libX11-devel
ce76083
Source0:	http://imsettings.googlecode.com/files/%{name}-%{version}.tar.bz2
f63f055
# workaround for KDE, it will be removed when we have a correct fix
f63f055
Source1:        imsettings-kde.sh
ce76083
Patch0:		imsettings-constraint-of-language.patch
15bd29d
Patch1:		imsettings-disable-xim.patch
ce76083
ce76083
Summary:	Delivery framework for general Input Method configuration
ce76083
Group:		Applications/System
ce76083
Requires:	xorg-x11-xinit >= 1.0.2-22.fc8
ce76083
Requires:	imsettings-libs = %{version}-%{release}
f06b8c8
Requires(pre):	GConf2
f06b8c8
Requires(post):	/bin/dbus-send %{_sbindir}/alternatives GConf2
f06b8c8
Requires(preun):	GConf2
ce76083
Requires(postun):	/bin/dbus-send %{_sbindir}/alternatives
ce76083
ce76083
%description
ce76083
IMSettings is a framework that delivers Input Method
ce76083
settings and applies the changes so they take effect
ce76083
immediately without any need to restart applications
ce76083
or the desktop.
ce76083
ce76083
This package contains the core DBus services and some utilities.
ce76083
ce76083
%package	libs
ce76083
Summary:	Libraries for imsettings
ce76083
Group:		Development/Libraries
ce76083
ce76083
%description	libs
ce76083
IMSettings is a framework that delivers Input Method
ce76083
settings and applies the changes so they take effect
ce76083
immediately without any need to restart applications
ce76083
or the desktop.
ce76083
ce76083
This package contains the shared library for imsettings.
ce76083
ce76083
%package	devel
ce76083
Summary:	Development files for imsettings
ce76083
Group:		Development/Libraries
ce76083
Requires:	%{name}-libs = %{version}-%{release}
ce76083
Requires:	pkgconfig
3e8e47b
Requires:	glib2-devel >= 2.16.0
f9cf45e
Requires:	dbus-glib-devel >= 0.74
ce76083
ce76083
%description	devel
ce76083
IMSettings is a framework that delivers Input Method
ce76083
settings and applies the changes so they take effect
ce76083
immediately without any need to restart applications
ce76083
or the desktop.
ce76083
ce76083
This package contains the development files to make any
ce76083
applications with imsettings.
ce76083
ce76083
%package	xfce
ce76083
Summary:	Xfce support on imsettings
ce76083
Group:		Applications/System
ce76083
Requires:	%{name} = %{version}-%{release}
ce76083
Requires:	im-chooser
ce76083
ce76083
%description	xfce
ce76083
IMSettings is a framework that delivers Input Method
ce76083
settings and applies the changes so they take effect
ce76083
immediately without any need to restart applications
ce76083
or the desktop.
ce76083
ce76083
This package contains a plugin to get this working on Xfce.  
ce76083
ce76083
%prep
ce76083
%setup -q
ce76083
%patch0 -p1 -b .0-lang
9fa90dc
#%%patch1 -p1 -b .1-xim
ce76083
ce76083
%build
ce76083
%configure	\
ce76083
	--with-xinputsh=50-xinput.sh \
f06b8c8
	--disable-static \
f06b8c8
	--disable-schemas-install
ce76083
ce76083
make %{?_smp_mflags}
ce76083
ce76083
ce76083
%install
ce76083
rm -rf $RPM_BUILD_ROOT
ce76083
make install DESTDIR=$RPM_BUILD_ROOT
ce76083
ce76083
# change the file attributes
ce76083
chmod 0755 $RPM_BUILD_ROOT%{_libexecdir}/xinputinfo.sh
ce76083
chmod 0755 $RPM_BUILD_ROOT%{_sysconfdir}/X11/xinit/xinitrc.d/50-xinput.sh
ce76083
ce76083
# clean up the unnecessary files
ce76083
rm -f $RPM_BUILD_ROOT%{_libdir}/*.la
ce76083
rm -f $RPM_BUILD_ROOT%{_libdir}/xfce4/mcs-plugins/*.la
ce76083
ce76083
# still not stable
ce76083
rm -f $RPM_BUILD_ROOT%{_datadir}/dbus-1/services/qt-im-settings-daemon.service
ce76083
rm -f $RPM_BUILD_ROOT%{_libexecdir}/qt-im-settings-daemon
ce76083
f63f055
# workaround for KDE
f17c1a6
mkdir -p $RPM_BUILD_ROOT%{_sysconfdir}/kde/env
f63f055
install -m 644 %{SOURCE1} $RPM_BUILD_ROOT%{_sysconfdir}/kde/env/
f63f055
ce76083
%find_lang %{name}
ce76083
ce76083
%clean
ce76083
rm -rf $RPM_BUILD_ROOT
ce76083
ce76083
f06b8c8
%pre
f06b8c8
if [ "$1" -gt 1 ]; then
f06b8c8
	export GCONF_CONFIG_SOURCE=`gconftool-2 --get-default-source`
176094b
	if [ -f %{_sysconfdir}/gconf/schemas/imsettings-applet.schemas ]; then
176094b
		gconftool-2 --makefile-uninstall-rule %{_sysconfdir}/gconf/schemas/imsettings-applet.schemas > /dev/null || :
176094b
	fi
f06b8c8
fi
f06b8c8
ce76083
%post
f06b8c8
export GCONF_CONFIG_SOURCE=`gconftool-2 --get-default-source`
f06b8c8
gconftool-2 --makefile-install-rule %{_sysconfdir}/gconf/schemas/imsettings-applet.schemas > /dev/null || :
ce76083
alternatives --install %{_sysconfdir}/X11/xinit/xinputrc xinputrc %{_sysconfdir}/X11/xinit/xinput.d/none.conf 10
ce76083
alternatives --install %{_sysconfdir}/X11/xinit/xinputrc xinputrc %{_sysconfdir}/X11/xinit/xinput.d/xim.conf 30
ce76083
dbus-send --system --type=method_call --dest=org.freedesktop.DBus / org.freedesktop.DBus.ReloadConfig > /dev/null 2>&1 || :
ce76083
f06b8c8
%preun
f06b8c8
if [ "$1" -eq 0 ]; then
f06b8c8
	export GCONF_CONFIG_SOURCE=`gconftool-2 --get-default-source`
f06b8c8
	gconftool-2 --makefile-uninstall-rule %{_sysconfdir}/gconf/schemas/imsettings-applet.schemas > /dev/null || :
f06b8c8
fi
f06b8c8
ce76083
%postun
ce76083
if [ "$1" = 0 ]; then
ce76083
	alternatives --remove xinputrc %{_sysconfdir}/X11/xinit/xinput.d/none.conf
ce76083
	alternatives --remove xinputrc %{_sysconfdir}/X11/xinit/xinput.d/xim.conf
ce76083
	dbus-send --system --type=method_call --dest=org.freedesktop.DBus / org.freedesktop.DBus.ReloadConfig > /dev/null 2>&1 || :
ce76083
fi
ce76083
ce76083
%post libs -p /sbin/ldconfig
ce76083
%postun libs -p /sbin/ldconfig
ce76083
ce76083
%files	-f %{name}.lang
ce76083
%defattr(-, root, root, -)
ce76083
%doc AUTHORS COPYING ChangeLog NEWS README
ce76083
%{_bindir}/imsettings-*
5ab3902
%{_bindir}/im-xsettings-daemon
ce76083
%{_libexecdir}/gconf-im-settings-daemon
ce76083
%{_libexecdir}/im-info-daemon
ce76083
%{_libexecdir}/im-settings-daemon
ce76083
%{_libexecdir}/xinputinfo.sh
ce76083
%{_datadir}/dbus-1/services/*.service
9fa90dc
%{_datadir}/pixmaps/*.png
ce76083
%{_sysconfdir}/X11/xinit/xinitrc.d/50-xinput.sh
ce76083
%{_sysconfdir}/X11/xinit/xinput.d
9fa90dc
%{_sysconfdir}/xdg/autostart/imsettings-applet.desktop
f06b8c8
%{_sysconfdir}/gconf/schemas/imsettings-applet.schemas
f63f055
%{_sysconfdir}/kde/env/*.sh
ce76083
ce76083
%files	libs
ce76083
%defattr(-, root, root, -)
ce76083
%doc AUTHORS COPYING ChangeLog NEWS README
ce76083
%{_libdir}/libimsettings.so.*
9fa90dc
%{_libdir}/libimsettings-xim.so.*
3266afa
%{_libdir}/libimsettings-xsettings.so.*
ce76083
ce76083
%files	devel
ce76083
%defattr(-, root, root, -)
ce76083
%doc AUTHORS COPYING ChangeLog NEWS README
ce76083
%{_includedir}/imsettings
ce76083
%{_libdir}/libimsettings.so
9fa90dc
%{_libdir}/libimsettings-xim.so
3266afa
%{_libdir}/libimsettings-xsettings.so
ce76083
%{_libdir}/pkgconfig/imsettings.pc
ce76083
ce76083
%files	xfce
ce76083
%defattr(-, root, root, -)
ce76083
%doc AUTHORS COPYING ChangeLog NEWS README
ce76083
%{_libdir}/xfce4/mcs-plugins/imsettings_plugin.so 
ce76083
ce76083
ce76083
%changelog
f63f055
* Wed Oct 01 2008 Than Ngo <than@redhat.com> 0.104.1-3
f63f055
- add workaround for KDE
f63f055
176094b
* Mon Sep 29 2008 Akira TAGOH <tagoh@redhat.com> - 0.104.1-2
176094b
- Fix a gconf error in %%pre. (#464453)
176094b
f06b8c8
* Thu Sep 25 2008 Akira TAGOH <tagoh@redhat.com> - 0.104.1-1
f06b8c8
- New upstream release.
f06b8c8
  - Fix a segfault issue. (#462899)
f06b8c8
  - Suppress the unnecessary notification. (#463797)
f06b8c8
  - Add .schemas file missing. real fix of #460703.
f06b8c8
3266afa
* Wed Sep 17 2008 Akira TAGOH <tagoh@redhat.com> - 0.104.0-1
3266afa
- New upstream release.
3266afa
  - Fix deadkey issue under XIM. (#457901)
3266afa
  - Correct .desktop file for imsettings-applet (#460695)
3266afa
  - Hide a status icon by default. (#460703)
3266afa
9fa90dc
* Fri Aug 29 2008 Akira TAGOH <tagoh@redhat.com> - 0.103.0-1
9fa90dc
- New upstream release.
9fa90dc
  - im-xsettings-daemon doesn't run automatically. (#459443)
9fa90dc
- Enable XIM support again. (#457635)
9fa90dc
- BR: libgxim-devel and libnotify-devel
9fa90dc
5ab3902
* Tue Jul 29 2008 Akira TAGOH <tagoh@redhat.com> - 0.102.0-1
5ab3902
- New upstream release.
5ab3902
  - Fix no recommendation updated. (#455363)
5ab3902
  - Work on WMs not own/bring up XSETTINGS manager. (#455228)
5ab3902
f5e0042
* Tue Jul  8 2008 Akira TAGOH <tagoh@redhat.com> - 0.101.3-2
f5e0042
- rebuild.
f5e0042
15bd29d
* Thu Jul  3 2008 Akira TAGOH <tagoh@redhat.com> - 0.101.3-1
15bd29d
- New upstream release.
15bd29d
  - Use the system-wide xinputrc if .xinputrc is a dangling
15bd29d
    symlink. (#453358)
15bd29d
bb8e8ed
* Thu Jun 26 2008 Akira TAGOH <tagoh@redhat.com> - 0.101.2-3
bb8e8ed
- Disable XIM support so far. (#452849, #452870)
bb8e8ed
bb8e8ed
* Wed Jun 18 2008 Akira TAGOH <tagoh@redhat.com> - 0.101.2-2
6c82867
- Backport patch from upstream to solve issues.
6c82867
  - always saying IM is running when no .xinputrc.
6c82867
  - workaround for a delay of that IM is ready for XIM.
6c82867
9361315
* Tue Jun 17 2008 Akira TAGOH <tagoh@redhat.com> - 0.101.2-1
9361315
- New upstream release.
9361315
  - Fix a typo in the help message. (#451739)
9361315
  - Fix a invalid memory access. (#451753)
9361315
f9cf45e
* Mon Jun 16 2008 Akira TAGOH <tagoh@redhat.com> - 0.101.1-2
f9cf45e
- Add Reqruies: glib2-devel, dbus-glib-devel to -devel.
f9cf45e
ce76083
* Thu Jun 12 2008 Akira TAGOH <tagoh@redhat.com> - 0.101.1-1
ce76083
- New upstream release.
ce76083
- Add Requires pkgconfig to -devel.
ce76083
ce76083
* Wed Jun 11 2008 Akira TAGOH <tagoh@redhat.com> - 0.101.0-1
ce76083
- New upstream release.
ce76083
- Add Requires alternatives for %%post and %%postun.
ce76083
- Improve summary.
ce76083
- Remove imsettings-reload from %%post and %%postun. these are
ce76083
  no longer needed.
ce76083
ce76083
* Wed Jun  4 2008 Akira TAGOH <tagoh@redhat.com> - 0.100.0-1
ce76083
- Initial package.
ce76083