]> xenbits.xensource.com Git - libvirt.git/commitdiff
build: Fix RPM build for non-x86 platforms
authorViktor Mihajlovski <mihajlov@linux.vnet.ibm.com>
Wed, 31 Oct 2012 21:21:06 +0000 (22:21 +0100)
committerEric Blake <eblake@redhat.com>
Thu, 1 Nov 2012 02:45:12 +0000 (20:45 -0600)
Make the post install script for the lock-sanlock package optional
to prevent break on non-x86 platforms.

Signed-off-by: Viktor Mihajlovski <mihajlov@linux.vnet.ibm.com>
libvirt.spec.in

index 41d26285b7e63b633a229fa8613e1aec88f20649..f8ede3f69035d62ae0b968e15f4ce60deeb9c932 100644 (file)
@@ -1568,12 +1568,13 @@ fi
 /bin/systemctl try-restart libvirt-guests.service >/dev/null 2>&1 || :
 %endif
 
+%if %{with_sanlock}
 %post lock-sanlock
 if getent group sanlock > /dev/null ; then
     chmod 0770 %{_localstatedir}/lib/libvirt/sanlock
     chown root:sanlock %{_localstatedir}/lib/libvirt/sanlock
 fi
-
+%endif
 
 %files
 %defattr(-, root, root)