public inbox for git-commits@fedoraproject.org
help / color / mirror / Atom feed
* [rpms/ibus] autotool: Follow packaging guidline for .desktop files
@ 2026-05-31  2:04 Peng Huang
  0 siblings, 0 replies; only message in thread
From: Peng Huang @ 2026-05-31  2:04 UTC (permalink / raw)
  To: git-commits

A new commit has been pushed.

Repo   : rpms/ibus
Branch : autotool
Commit : d3fa3eebd3d3b71b60655c28aa4ce061fcc6474a
Author : Peng Huang <phuang@fedoraproject.org>
Date   : 2008-10-07T04:43:20+00:00
Stats  : +23/-12 in 1 file(s)
URL    : https://src.fedoraproject.org/rpms/ibus/c/d3fa3eebd3d3b71b60655c28aa4ce061fcc6474a?branch=autotool

Log:
Follow packaging guidline for .desktop files

---
diff --git a/ibus.spec b/ibus.spec
index d327c6b..e8f870b 100644
--- a/ibus.spec
+++ b/ibus.spec
@@ -19,14 +19,18 @@ BuildRequires:  python
 BuildRequires:  gtk2-devel
 BuildRequires:  qt-devel
 BuildRequires:  dbus-glib-devel
+BuildRequires:  desktop-file-utils
+
+Requires(post):  desktop-file-utils
+Requires(post):  %{_sbindir}/alternatives
+Requires(postun):  desktop-file-utils
+Requires(postun):  %{_sbindir}/alternatives
 
 Requires:   pygtk2
 Requires:   dbus-python >= 0.83.0
-Requires:   gnome-python2-gconf
 Requires:   pyxdg
+Requires:   gnome-python2-gconf
 Requires:   iso-codes
-Requires(post): %{_sbindir}/alternatives
-Requires(postun): %{_sbindir}/alternatives
 
 %description
 IBus means Intelligent Input Bus. It is a new input framework for Linux OS. It provides
@@ -34,7 +38,7 @@ full featured and user friendly input method user interface. It also may help
 developers to develop input method easily.
 
 %package gtk
-Summary:    iBus im module for gtk2
+Summary:    IBus im module for gtk2
 Group:      System Environment/Libraries
 Requires:   %{name} = %{version}-%{release}
 
@@ -42,10 +46,10 @@ Requires:   %{name} = %{version}-%{release}
 This package contains ibus im module for gtk2
 
 %package qt
-Summary:    iBus im module for qt4
+Summary:    IBus im module for qt4
 Group:      System Environment/Libraries
 Requires:   %{name} = %{version}-%{release}
-Requires:   qt >= 4.4.1
+Requires:   qt >= 4.4.2
 
 %description qt
 This package contains ibus im module for qt4
@@ -71,6 +75,11 @@ rm -f $RPM_BUILD_ROOT%{_libdir}/gtk-2.0/%{gtk_binary_version}/immodules/im-ibus.
 mkdir -pm 755 ${RPM_BUILD_ROOT}/%{_sysconfdir}/X11/xinit/xinput.d
 install -pm 644 %{SOURCE1} ${RPM_BUILD_ROOT}/%{_xinputconf}
 
+# install .desktop files
+desktop-file-install --delete-original          \
+  --dir $RPM_BUILD_ROOT%{_datadir}/applications \
+  $RPM_BUILD_ROOT%{_datadir}/applications/*
+
 %find_lang %{name}
 
 %clean
@@ -78,22 +87,24 @@ rm -rf $RPM_BUILD_ROOT
 
 %post
 /sbin/ldconfig
+update-desktop-database -q
 %{_sbindir}/alternatives --install %{_sysconfdir}/X11/xinit/xinputrc xinputrc %{_xinputconf} 83 || :
 
 %post gtk
 %{_bindir}/update-gtk-immodules %{_host} || :
 
-%postun gtk
-%{_bindir}/update-gtk-immodules %{_host} || :
-
 %postun
 /sbin/ldconfig
+update-desktop-database -q
 if [ "$1" = "0" ]; then
-   %{_sbindir}/alternatives --remove xinputrc %{_xinputconf} || :
-   # if alternative was set to manual, reset to auto
-   [ -L %{_sysconfdir}/alternatives/xinputrc -a "`readlink %{_sysconfdir}/alternatives/xinputrc`" = "%{_xinputconf}" ] && %{_sbindir}/alternatives --auto xinputrc || :
+  %{_sbindir}/alternatives --remove xinputrc %{_xinputconf} || :
+  # if alternative was set to manual, reset to auto
+  [ -L %{_sysconfdir}/alternatives/xinputrc -a "`readlink %{_sysconfdir}/alternatives/xinputrc`" = "%{_xinputconf}" ] && %{_sbindir}/alternatives --auto xinputrc || :
 fi
 
+%postun gtk
+%{_bindir}/update-gtk-immodules %{_host} || :
+
 %files -f %{name}.lang
 %defattr(-,root,root,-)
 %doc AUTHORS COPYING README

^ permalink raw reply related	[flat|nested] only message in thread

only message in thread, other threads:[~2026-05-31  2:04 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2026-05-31  2:04 [rpms/ibus] autotool: Follow packaging guidline for .desktop files Peng Huang

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox