]> xenbits.xensource.com Git - qemu-xen-4.0-testing.git/commitdiff
Do not rebuild every time ./xen-setup is run.
authorIan Jackson <iwj@mariner.uk.xensource.com>
Wed, 9 Jul 2008 10:38:33 +0000 (11:38 +0100)
committerIan Jackson <Ian.Jackson@eu.citrix.com>
Wed, 9 Jul 2008 10:38:33 +0000 (11:38 +0100)
This involves saving config-host.h while we rerun config and
regenerate it, putting the saved version back, and then installing
the new version only if it has changed.

xen-setup

index 6b2093606b971401d04d7d9ef2ccf884a314b3ca..826f94027cc0fcbe6ce95110182b7a53747db9c7 100755 (executable)
--- a/xen-setup
+++ b/xen-setup
@@ -7,6 +7,8 @@ rm -f $target/Makefile
 rm -f $target/config.mak
 rm -f config-host.mak
 
+mv config-host.h config-host.h~
+
 ./configure --disable-curses "$@" --prefix=/usr
 
 target=i386-dm
@@ -21,4 +23,6 @@ cat xen-config-host.mak >>config-host.mak
 
 sed -e 's,qemu,xen/qemu,' config-host.h >config-host.h.new
 echo '#include "xen-config-host.h"' >>config-host.h.new
-mv config-host.h.new config-host.h
+
+mv config-host.h~ config-host.h
+cmp -s config-host.h.new config-host.h || mv config-host.h.new config-host.h