[virt-tools-list] [virt-viewer] spec: Update/optimize mime scriptlets
Christophe Fergeau
cfergeau at redhat.com
Fri Oct 10 11:20:37 UTC 2014
From: Rex Dieter <rdieter at math.unl.edu>
---
virt-viewer.spec.in | 9 +++++----
1 file changed, 5 insertions(+), 4 deletions(-)
diff --git a/virt-viewer.spec.in b/virt-viewer.spec.in
index b3b6b5e..a70323e 100644
--- a/virt-viewer.spec.in
+++ b/virt-viewer.spec.in
@@ -121,22 +121,23 @@ rm -rf $RPM_BUILD_ROOT
%post
/bin/touch --no-create %{_datadir}/icons/hicolor &>/dev/null || :
+/bin/touch --no-create %{_datadir}/mime/packages &> /dev/null || :
%{_sbindir}/update-alternatives --install %{_libexecdir}/spice-xpi-client \
spice-xpi-client %{_libexecdir}/spice-xpi-client-remote-viewer 25
-update-desktop-database -q %{_datadir}/applications
-%{_bindir}/update-mime-database %{_datadir}/mime &> /dev/null
+/usr/bin/update-desktop-database -q %{_datadir}/applications
%postun
if [ $1 -eq 0 ] ; then
/bin/touch --no-create %{_datadir}/icons/hicolor &>/dev/null
/usr/bin/gtk-update-icon-cache %{_datadir}/icons/hicolor &>/dev/null || :
+ /usr/bin/update-mime-database %{_datadir}/mime &> /dev/null || :
%{_sbindir}/update-alternatives --remove spice-xpi-client %{_libexecdir}/spice-xpi-client-remote-viewer
fi
-update-desktop-database -q %{_datadir}/applications
-%{_bindir}/update-mime-database %{_datadir}/mime &> /dev/null
+/usr/bin/update-desktop-database -q %{_datadir}/applications
%posttrans
/usr/bin/gtk-update-icon-cache %{_datadir}/icons/hicolor &>/dev/null || :
+/usr/bin/update-mime-database %{?fedora:-n} %{_datadir}/mime &> /dev/null || :
%files -f %{name}.lang
%defattr(-,root,root,-)
--
2.1.0
More information about the virt-tools-list
mailing list