[ovirt-guest-agent/el5: 2/2] ovirt-guest-agent: Initial EL5 package

Vinzenz Feenstra evilissimo at fedoraproject.org
Thu Jul 11 11:09:39 UTC 2013


commit 486e12cefea7ec8cd91f93afd395c2f9ea2e2e4c
Author: Vinzenz Feenstra <vfeenstr at redhat.com>
Date:   Thu Jul 11 13:09:08 2013 +0200

    ovirt-guest-agent: Initial EL5 package
    
    Signed-off-by: Vinzenz Feenstra <vfeenstr at redhat.com>

 ovirt-guest-agent.spec |   17 ++++++++++-------
 1 files changed, 10 insertions(+), 7 deletions(-)
---
diff --git a/ovirt-guest-agent.spec b/ovirt-guest-agent.spec
index bedb58a..ccdba33 100644
--- a/ovirt-guest-agent.spec
+++ b/ovirt-guest-agent.spec
@@ -46,7 +46,10 @@ restart).
 make %{?_smp_mflags}
 
 %install
-make install DESTDIR=%{buildroot}
+make -C ovirt-guest-agent -f Makefile.el5 install DESTDIR=%{buildroot}
+
+mkdir -p %{buildroot}%{_localstatedir}/log/ovirt-guest-agent
+mkdir -p %{buildroot}%{_localstatedir}/lock/subsys/ovirt-guest-agent
 
 %if 0%{?rhel}
     # Install SystemV init script.
@@ -63,9 +66,9 @@ exit 0
 %post
 /sbin/chkconfig --add ovirt-guest-agent
 
-%posttrans
-/sbin/udevadm trigger --subsystem-match="virtio-ports" \
-    --attr-match="name=com.redhat.rhevm.vdsm"
+ln -sf /usr/bin/consolehelper %{_datadir}/ovirt-guest-agent/ovirt-shutdown
+ln -sf /usr/bin/consolehelper %{_datadir}/ovirt-guest-agent/ovirt-hibernate
+ln -sf /usr/bin/consolehelper %{_datadir}/ovirt-guest-agent/ovirt-locksession
 
 %preun
 if [ "$1" -eq 0 ]
@@ -86,9 +89,9 @@ fi
 %postun
 if [ "$1" -eq 0 ]
 then
-    # Let udev clear access rights
-    /sbin/udevadm trigger --subsystem-match="virtio-ports" \
-        --attr-match="name=com.redhat.rhevm.vdsm"
+    rm -f %{_datadir}/ovirt-guest-agent/ovirt-shutdown
+    rm -f %{_datadir}/ovirt-guest-agent/ovirt-hibernate
+    rm -f %{_datadir}/ovirt-guest-agent/ovirt-locksession
 fi
 
 if [ "$1" -ge 1 ]; then


More information about the scm-commits mailing list