packages: gtk-im-libthai/gtk-im-libthai.spec - added post/postun

qboosh qboosh at pld-linux.org
Sun Nov 6 09:49:11 CET 2011


Author: qboosh                       Date: Sun Nov  6 08:49:11 2011 GMT
Module: packages                      Tag: HEAD
---- Log message:
- added post/postun

---- Files affected:
packages/gtk-im-libthai:
   gtk-im-libthai.spec (1.1 -> 1.2) 

---- Diffs:

================================================================
Index: packages/gtk-im-libthai/gtk-im-libthai.spec
diff -u packages/gtk-im-libthai/gtk-im-libthai.spec:1.1 packages/gtk-im-libthai/gtk-im-libthai.spec:1.2
--- packages/gtk-im-libthai/gtk-im-libthai.spec:1.1	Sun Nov  6 09:11:33 2011
+++ packages/gtk-im-libthai/gtk-im-libthai.spec	Sun Nov  6 09:49:06 2011
@@ -30,6 +30,7 @@
 Summary:	GTK+ 2 Thai input method based on libthai
 Summary(pl.UTF-8):	Metoda wprowadzania znaków tajskich dla GTK+ 2 oparta na libthai
 Group:		Libraries
+Requires(post,postun):	gtk+2 >= 2:2.22
 Requires:	gtk+2 >= 2:2.22
 Requires:	libthai >= 0.1.2
 
@@ -43,6 +44,7 @@
 Summary:	GTK+ 3 Thai input method based on libthai
 Summary(pl.UTF-8):	Metoda wprowadzania znaków tajskich dla GTK+ 3 oparta na libthai
 Group:		Libraries
+Requires(post,postun):	gtk+3 >= 3.0.0
 Requires:	gtk+3 >= 3.0.0
 Requires:	libthai >= 0.1.2
 
@@ -73,15 +75,47 @@
 %clean
 rm -rf $RPM_BUILD_ROOT
 
+%post -n gtk+2-im-libthai
+%if "%{_lib}" == "lib64"
+%{_bindir}/gtk-query-immodules-2.0-64 > %{_sysconfdir}/gtk64-2.0/gtk.immodules
+%else
+%{_bindir}/gtk-query-immodules-2.0 > %{_sysconfdir}/gtk-2.0/gtk.immodules
+%endif
+
+%postun -n gtk+2-im-libthai
+%if "%{_lib}" == "lib64"
+%{_bindir}/gtk-query-immodules-2.0-64 > %{_sysconfdir}/gtk64-2.0/gtk.immodules
+%else
+%{_bindir}/gtk-query-immodules-2.0 > %{_sysconfdir}/gtk-2.0/gtk.immodules
+%endif
+
+%post -n gtk+3-im-libthai
+%if "%{_lib}" == "lib64"
+%{_bindir}/gtk-query-immodules-3.0-64 --update-cache
+%else
+%{_bindir}/gtk-query-immodules-3.0 --update-cache
+%endif
+
+%postun -n gtk+3-im-libthai
+%if "%{_lib}" == "lib64"
+%{_bindir}/gtk-query-immodules-3.0-64 --update-cache
+%else
+%{_bindir}/gtk-query-immodules-3.0 --update-cache
+%endif
+
+%if %{with gtk2}
 %files -n gtk+2-im-libthai
 %defattr(644,root,root,755)
 %doc AUTHORS ChangeLog NEWS
 %attr(755,root,root) %{_libdir}/gtk-2.0/2.10.0/immodules/im-thai-libthai.so
+%endif
 
+%if %{with gtk3}
 %files -n gtk+3-im-libthai
 %defattr(644,root,root,755)
 %doc AUTHORS ChangeLog NEWS
 %attr(755,root,root) %{_libdir}/gtk-3.0/3.0.0/immodules/im-thai-libthai.so
+%endif
 
 %define date	%(echo `LC_ALL="C" date +"%a %b %d %Y"`)
 %changelog
@@ -89,5 +123,8 @@
 All persons listed below can be reached at <cvs_login>@pld-linux.org
 
 $Log$
+Revision 1.2  2011/11/06 08:49:06  qboosh
+- added post/postun
+
 Revision 1.1  2011/11/06 08:11:33  qboosh
 - new
================================================================

---- CVS-web:
    http://cvs.pld-linux.org/cgi-bin/cvsweb.cgi/packages/gtk-im-libthai/gtk-im-libthai.spec?r1=1.1&r2=1.2&f=u



More information about the pld-cvs-commit mailing list