[netfilter-cvslog] r3514 - trunk/nfsim

rusty at netfilter.org rusty at netfilter.org
Wed Dec 29 14:25:17 CET 2004


Author: rusty at netfilter.org
Date: 2004-12-29 14:25:16 +0100 (Wed, 29 Dec 2004)
New Revision: 3514

Added:
   trunk/nfsim/UNSUPPORTED
Modified:
   trunk/nfsim/configure
Log:
Use .config from --kerneldir if it exists.
Use UNSUPPORTED to specify which config options to remove.


Added: trunk/nfsim/UNSUPPORTED
===================================================================
--- trunk/nfsim/UNSUPPORTED	2004-12-29 12:56:31 UTC (rev 3513)
+++ trunk/nfsim/UNSUPPORTED	2004-12-29 13:25:16 UTC (rev 3514)
@@ -0,0 +1,20 @@
+# Unsupported config options.  This file is parsed by configure.
+
+# No bridging, or anything which relies on that.
+CONFIG_BRIDGE_NETFILTER
+CONFIG_IP_NF_MATCH_PHYSDEV
+
+# No netlink support
+CONFIG_IP_NF_QUEUE
+CONFIG_IP_NF_TARGET_ULOG
+
+# No arptables
+CONFIG_IP_NF_ARPTABLES
+CONFIG_IP_NF_ARPFILTER
+CONFIG_IP_NF_ARP_MANGLE
+
+# tasklist not yet implemented.
+CONFIG_IP_NF_MATCH_OWNER
+
+# sysctl not yet implemented
+CONFIG_SYSCTL

Modified: trunk/nfsim/configure
===================================================================
--- trunk/nfsim/configure	2004-12-29 12:56:31 UTC (rev 3513)
+++ trunk/nfsim/configure	2004-12-29 13:25:16 UTC (rev 3514)
@@ -15,6 +15,12 @@
     exit 1
 }
 
+# Create regex to grep out unsupported config options.
+unsupported()
+{
+    grep -v '^#' UNSUPPORTED | tr -s '\n' '|'
+}
+
 for arg; do
     case "$arg" in
 	--kerneldir=*) KERNELDIR=$(echo "$arg" | cut -d= -f2-);;
@@ -78,8 +84,13 @@
 #define LINUX_VERSION_CODE KERNEL_VERSION($VERSION, $PATCHLEVEL, $SUBLEVEL)
 EOF
 
-#cp $(KERNELDIR)/.config ./ || cp .config.sample .config
-cp .config.sample .config
+if [ -f $KERNELDIR/.config ]; then
+    echo Using $KERNELDIR config...
+    egrep -v @@`unsupported`@@ $KERNELDIR/.config | sed 's/=m$/=y/' > .config
+else
+    echo Using sample config...
+    cp .config.sample .config
+fi
 
 # Create symlinks in case they're not already there.
 (cd kernelenv/include && while read i; do ln -sf ../kernelenv.h $i; done) < .links




More information about the netfilter-cvslog mailing list