Don't munge default network XML if uuidgen is not present (John Levon)

This commit is contained in:
Daniel P. Berrange 2008-12-18 11:54:34 +00:00
parent 13d98d68fc
commit 9e8517c745
2 changed files with 9 additions and 3 deletions

View File

@ -1,3 +1,8 @@
Thu Dec 18 11:54:58 GMT 2008 Daniel P. Berrange <berrange@redhat.com>
* qemud/Makefile.am: Don't munge default network XML if
uuidgen is not present (John Levon)
Thu Dec 18 11:50:58 GMT 2008 Daniel P. Berrange <berrange@redhat.com>
Misc daemon bug fixes (John Levon)

View File

@ -60,7 +60,7 @@ remote_protocol.c: remote_protocol.h
if WITH_LIBVIRTD
UUID=$(shell uuidgen)
UUID=$(shell uuidgen 2>/dev/null)
sbin_PROGRAMS = libvirtd
@ -144,8 +144,9 @@ install-data-local: install-init install-data-sasl install-data-polkit \
mkdir -p $(DESTDIR)$(sysconfdir)/libvirt/qemu/networks/autostart
$(INSTALL_DATA) $(srcdir)/default-network.xml \
$(DESTDIR)$(sysconfdir)/$(default_xml_dest)
sed -i -e "s,</name>,</name>\n <uuid>$(UUID)</uuid>," \
$(DESTDIR)$(sysconfdir)/$(default_xml_dest)
test -z "$(UUID)" || \
sed -i -e "s,</name>,</name>\n <uuid>$(UUID)</uuid>," \
$(DESTDIR)$(sysconfdir)/$(default_xml_dest)
test -e $(DESTDIR)$(sysconfdir)/libvirt/qemu/networks/autostart/default.xml || \
ln -s ../default.xml \
$(DESTDIR)$(sysconfdir)/libvirt/qemu/networks/autostart/default.xml