[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH] Do not redefine DEFAULT_NETWORK_{, DOWN_}SCRIP
From: |
Ian Jackson |
Subject: |
Re: [Qemu-devel] [PATCH] Do not redefine DEFAULT_NETWORK_{, DOWN_}SCRIPT |
Date: |
Fri, 13 Jun 2008 12:24:50 +0100 |
Anthony Liguori writes ("Re: [Qemu-devel] [PATCH] Do not redefine
DEFAULT_NETWORK_{, DOWN_}SCRIPT"):
> This is a good idea, but I think it should be something that is
> specified in ./configure.
In the attached patch, you can specify this as an argument to
./configure, --network-scripts=ifup,ifdown.
You need my previous patch too to avoid redefinition.
Signed-off-by: Ian Jackson <address@hidden>
---
configure | 14 ++++++++++++++
1 files changed, 14 insertions(+), 0 deletions(-)
diff --git a/configure b/configure
index c1ab850..0b9cbb2 100755
--- a/configure
+++ b/configure
@@ -331,6 +331,10 @@ for opt do
;;
--disable-curses) curses="no"
;;
+ --network-scripts=*) network_scripts="$optarg"
+ ;;
+ --network-script-ifup=*) network_script_ifup="$optarg"
+ ;;
*) echo "ERROR: unknown option $opt"; show_help="yes"
;;
esac
@@ -430,6 +434,7 @@ echo " --enable-linux-user enable all linux usermode
emulation targets"
echo " --disable-linux-user disable all linux usermode emulation targets"
echo " --enable-darwin-user enable all darwin usermode emulation targets"
echo " --disable-darwin-user disable all darwin usermode emulation targets"
+echo " --network-scripts=IFUP,IFDOWN use IFUP, IFDOWN for networking setup"
echo " --fmod-lib path to FMOD library"
echo " --fmod-inc path to FMOD includes"
echo " --enable-uname-release=R Return R for uname -r in usermode emulation"
@@ -1100,6 +1105,15 @@ if [ "$bsd" = "yes" ] ; then
echo "#define _BSD 1" >> $config_h
fi
+if [ "x$network_scripts" != x ]; then
+ cat >>$config_h <<END
+#define DEFAULT_NETWORK_SCRIPT "${network_scripts%,*}"
+#define DEFAULT_NETWORK_DOWN_SCRIPT "${network_scripts#*,}"
+END
+else
+ echo >>$config_h "/* DEFAULT_NETWORK_[DOWN_]SCRIPT not set */"
+fi
+
echo "#define CONFIG_UNAME_RELEASE \"$uname_release\"" >> $config_h
tools=
--
1.4.4.4