All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] KERNEL_DIR support in autogen.sh for libnfnetlink/libnetfilter_conntrack
@ 2005-11-14 23:48 Krzysztof Oledzki
  2005-11-15  0:25 ` Pablo Neira
  2005-11-15  8:11 ` Sven Schuster
  0 siblings, 2 replies; 6+ messages in thread
From: Krzysztof Oledzki @ 2005-11-14 23:48 UTC (permalink / raw)
  To: Pablo Neira; +Cc: netfilter-devel

[-- Attachment #1: Type: TEXT/PLAIN, Size: 271 bytes --]

Hello,

Attached two patches for libnfnetlink and libnetfilter_conntrack allow 
user to specify custom KERNEL_DIR like in iptables build. If KERNEL_DIR is 
empty default directory - "/lib/modules/`uname -r`/build" is used.

Best regards,


 				Krzysztof Olędzki

[-- Attachment #2: Type: TEXT/PLAIN, Size: 990 bytes --]


[libnfnetlink] Add KERNEL_DIR support to autogen.sh

Allow user to specify custom KERNEL_DIR to support building library
against selected kernel tree.

Signed-off-by: Krzysztof Piotr Oledzki <ole@ans.pl>

Index: autogen.sh
===================================================================
--- autogen.sh	(revision 4538)
+++ autogen.sh	(working copy)
@@ -7,14 +7,15 @@
     # the headers that we need from the lastest kernel version at autogen
     # stage.
 
-    INCLUDEDIR=/lib/modules/`uname -r`/build/include/linux
+    INCLUDEDIR=${KERNEL_DIR:-/lib/modules/`uname -r`/build}/include/linux
+
     if [ -f $INCLUDEDIR/netfilter/nfnetlink.h ]
     then
     	TARGET=include/libnfnetlink/linux_nfnetlink.h
     	echo "Copying nfnetlink.h to linux_nfnetlink.h"
     	cp $INCLUDEDIR/netfilter/nfnetlink.h $TARGET
     else
-    	echo "can't find nfnetlink.h kernel file"
+    	echo "can't find nfnetlink.h kernel file in $INCLUDEDIR"
     	exit 1
     fi
 }

[-- Attachment #3: Type: TEXT/PLAIN, Size: 1068 bytes --]


[libnetfilter_conntrack] Add KERNEL_DIR support to autogen.sh

Allow user to specify custom KERNEL_DIR to support building library
against selected kernel tree.

Signed-off-by: Krzysztof Piotr Oledzki <ole@ans.pl>

Index: autogen.sh
===================================================================
--- autogen.sh	(revision 4538)
+++ autogen.sh	(working copy)
@@ -7,7 +7,7 @@
     # the headers that we need from the lastest kernel version at autogen
     # stage.
 
-    INCLUDEDIR=/lib/modules/`uname -r`/build/include/linux
+    INCLUDEDIR=${KERNEL_DIR:-/lib/modules/`uname -r`/build}/include/linux
     if [ -f $INCLUDEDIR/netfilter/nfnetlink_conntrack.h ]
     then
     	TARGET=include/libnetfilter_conntrack/linux_nfnetlink_conntrack.h
@@ -17,7 +17,7 @@
 	sed 's/linux\/netfilter\/nfnetlink.h/libnfnetlink\/linux_nfnetlink.h/g' $TARGET > $TEMP
 	mv $TEMP $TARGET
     else
-    	echo "can't find nfnetlink_conntrack.h kernel file"
+    	echo "can't find nfnetlink_conntrack.h kernel file in $INCLUDEDIR"
     	exit 1
     fi
 }

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [PATCH] KERNEL_DIR support in autogen.sh for libnfnetlink/libnetfilter_conntrack
  2005-11-14 23:48 [PATCH] KERNEL_DIR support in autogen.sh for libnfnetlink/libnetfilter_conntrack Krzysztof Oledzki
@ 2005-11-15  0:25 ` Pablo Neira
  2005-11-15 13:15   ` Krzysztof Oledzki
  2005-11-15  8:11 ` Sven Schuster
  1 sibling, 1 reply; 6+ messages in thread
From: Pablo Neira @ 2005-11-15  0:25 UTC (permalink / raw)
  To: Krzysztof Oledzki; +Cc: netfilter-devel

Krzysztof Oledzki wrote:
> Attached two patches for libnfnetlink and libnetfilter_conntrack allow
> user to specify custom KERNEL_DIR like in iptables build. If KERNEL_DIR
> is empty default directory - "/lib/modules/`uname -r`/build" is used.

The patches look fine. Could you resend the same patch including
libnetfilter_queue and libnetfilter_log as well? That way we'll keep all
the libnetfilter_* friends in sync. Thanks!

-- 
Pablo

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [PATCH] KERNEL_DIR support in autogen.sh for libnfnetlink/libnetfilter_conntrack
  2005-11-14 23:48 [PATCH] KERNEL_DIR support in autogen.sh for libnfnetlink/libnetfilter_conntrack Krzysztof Oledzki
  2005-11-15  0:25 ` Pablo Neira
@ 2005-11-15  8:11 ` Sven Schuster
  2005-11-15  8:14   ` Sven Schuster
  1 sibling, 1 reply; 6+ messages in thread
From: Sven Schuster @ 2005-11-15  8:11 UTC (permalink / raw)
  To: Krzysztof Oledzki; +Cc: netfilter-devel, Pablo Neira

[-- Attachment #1: Type: text/plain, Size: 1413 bytes --]


Hi Krzysztof,

On Tue, Nov 15, 2005 at 12:48:13AM +0100, Krzysztof Oledzki told us:
> Index: autogen.sh
> ===================================================================
> --- autogen.sh	(revision 4538)
> +++ autogen.sh	(working copy)
> @@ -7,14 +7,15 @@
>      # the headers that we need from the lastest kernel version at autogen
>      # stage.
>  
> -    INCLUDEDIR=/lib/modules/`uname -r`/build/include/linux
> +    INCLUDEDIR=${KERNEL_DIR:-/lib/modules/`uname -r`/build}/include/linux
> +

shouldn't INCLUDEDIR be set to something like ${KERNEL_DIR}/include/linux
when KERNEL_DIR is set?? The name KERNEL_DIR implies that this variable
holds the path of the linux kernel, not the path of the linux kernel's
include/linux directory...!?

Just my humble opinion, of course!!


have a nice day :-)

Sven

>      if [ -f $INCLUDEDIR/netfilter/nfnetlink.h ]
>      then
>      	TARGET=include/libnfnetlink/linux_nfnetlink.h
>      	echo "Copying nfnetlink.h to linux_nfnetlink.h"
>      	cp $INCLUDEDIR/netfilter/nfnetlink.h $TARGET
>      else
> -    	echo "can't find nfnetlink.h kernel file"
> +    	echo "can't find nfnetlink.h kernel file in $INCLUDEDIR"
>      	exit 1
>      fi
>  }


-- 
Linux zion.homelinux.com 2.6.14-mm2_16 #16 Sun Nov 13 22:16:30 CET 2005 i686 athlon i386 GNU/Linux
 09:07:19 up 1 day, 10:29,  1 user,  load average: 0.03, 0.03, 0.00

[-- Attachment #2: Type: application/pgp-signature, Size: 189 bytes --]

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [PATCH] KERNEL_DIR support in autogen.sh for libnfnetlink/libnetfilter_conntrack
  2005-11-15  8:11 ` Sven Schuster
@ 2005-11-15  8:14   ` Sven Schuster
  0 siblings, 0 replies; 6+ messages in thread
From: Sven Schuster @ 2005-11-15  8:14 UTC (permalink / raw)
  To: Krzysztof Oledzki; +Cc: netfilter-devel, Pablo Neira

[-- Attachment #1: Type: text/plain, Size: 1847 bytes --]


sorry didn't see the '}' before /include/linux :-)

will get some caffeine now ;-)


Sven

On Tue, Nov 15, 2005 at 09:11:00AM +0100, Sven Schuster told us:
> 
> Hi Krzysztof,
> 
> On Tue, Nov 15, 2005 at 12:48:13AM +0100, Krzysztof Oledzki told us:
> > Index: autogen.sh
> > ===================================================================
> > --- autogen.sh	(revision 4538)
> > +++ autogen.sh	(working copy)
> > @@ -7,14 +7,15 @@
> >      # the headers that we need from the lastest kernel version at autogen
> >      # stage.
> >  
> > -    INCLUDEDIR=/lib/modules/`uname -r`/build/include/linux
> > +    INCLUDEDIR=${KERNEL_DIR:-/lib/modules/`uname -r`/build}/include/linux
> > +
> 
> shouldn't INCLUDEDIR be set to something like ${KERNEL_DIR}/include/linux
> when KERNEL_DIR is set?? The name KERNEL_DIR implies that this variable
> holds the path of the linux kernel, not the path of the linux kernel's
> include/linux directory...!?
> 
> Just my humble opinion, of course!!
> 
> 
> have a nice day :-)
> 
> Sven
> 
> >      if [ -f $INCLUDEDIR/netfilter/nfnetlink.h ]
> >      then
> >      	TARGET=include/libnfnetlink/linux_nfnetlink.h
> >      	echo "Copying nfnetlink.h to linux_nfnetlink.h"
> >      	cp $INCLUDEDIR/netfilter/nfnetlink.h $TARGET
> >      else
> > -    	echo "can't find nfnetlink.h kernel file"
> > +    	echo "can't find nfnetlink.h kernel file in $INCLUDEDIR"
> >      	exit 1
> >      fi
> >  }
> 
> 
> -- 
> Linux zion.homelinux.com 2.6.14-mm2_16 #16 Sun Nov 13 22:16:30 CET 2005 i686 athlon i386 GNU/Linux
>  09:07:19 up 1 day, 10:29,  1 user,  load average: 0.03, 0.03, 0.00



-- 
Linux zion.homelinux.com 2.6.14-mm2_16 #16 Sun Nov 13 22:16:30 CET 2005 i686 athlon i386 GNU/Linux
 09:13:42 up 1 day, 10:36,  1 user,  load average: 0.11, 0.06, 0.01

[-- Attachment #2: Type: application/pgp-signature, Size: 189 bytes --]

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [PATCH] KERNEL_DIR support in autogen.sh for libnfnetlink/libnetfilter_conntrack
  2005-11-15  0:25 ` Pablo Neira
@ 2005-11-15 13:15   ` Krzysztof Oledzki
  2005-11-17 12:55     ` Harald Welte
  0 siblings, 1 reply; 6+ messages in thread
From: Krzysztof Oledzki @ 2005-11-15 13:15 UTC (permalink / raw)
  To: Pablo Neira; +Cc: netfilter-devel

[-- Attachment #1: Type: TEXT/PLAIN, Size: 653 bytes --]



On Tue, 15 Nov 2005, Pablo Neira wrote:

> Krzysztof Oledzki wrote:
>> Attached two patches for libnfnetlink and libnetfilter_conntrack allow
>> user to specify custom KERNEL_DIR like in iptables build. If KERNEL_DIR
>> is empty default directory - "/lib/modules/`uname -r`/build" is used.
>
> The patches look fine. Could you resend the same patch including
> libnetfilter_queue and libnetfilter_log as well? That way we'll keep all
> the libnetfilter_* friends in sync. Thanks!

Attached four patches for libnetfilter_log, libnetfilter_queue, 
libnetfilter_conntrack and finally libnfnetlink.

Best regards,

 				Krzysztof Olędzki

[-- Attachment #2: Type: TEXT/PLAIN, Size: 955 bytes --]


[libnetfilter_log] Add KERNEL_DIR support to autogen.sh

Allow user to specify custom KERNEL_DIR to support building library
against selected kernel tree.

Signed-off-by: Krzysztof Piotr Oledzki <ole@ans.pl>

Index: autogen.sh
===================================================================
--- autogen.sh	(revision 4538)
+++ autogen.sh	(working copy)
@@ -7,7 +7,7 @@
     # the headers that we need from the lastest kernel version at autogen
     # stage.
 
-    INCLUDEDIR=/lib/modules/`uname -r`/build/include/linux
+    INCLUDEDIR=${KERNEL_DIR:-/lib/modules/`uname -r`/build}/include/linux
     if [ -f $INCLUDEDIR/netfilter/nfnetlink_log.h ]
     then
     	TARGET=include/libnetfilter_log/linux_nfnetlink_log.h
@@ -29,7 +29,7 @@
 	print $0
 	}' $TEMP > $TARGET
     else
-    	echo "can't find nfnetlink_log.h kernel file"
+    	echo "can't find nfnetlink_log.h kernel file in $INCLUDEDIR"
     	exit 1
     fi
 }

[-- Attachment #3: Type: TEXT/PLAIN, Size: 967 bytes --]


[libnetfilter_queue] Add KERNEL_DIR support to autogen.sh

Allow user to specify custom KERNEL_DIR to support building library
against selected kernel tree.

Signed-off-by: Krzysztof Piotr Oledzki <ole@ans.pl>

Index: autogen.sh
===================================================================
--- autogen.sh	(revision 4538)
+++ autogen.sh	(working copy)
@@ -7,7 +7,7 @@
     # the headers that we need from the lastest kernel version at autogen
     # stage.
 
-    INCLUDEDIR=/lib/modules/`uname -r`/build/include/linux
+    INCLUDEDIR=${KERNEL_DIR:-/lib/modules/`uname -r`/build}/include/linux
     if [ -f $INCLUDEDIR/netfilter/nfnetlink_queue.h ]
     then
     	TARGET=include/libnetfilter_queue/linux_nfnetlink_queue.h
@@ -29,7 +29,7 @@
 	print $0
 	}' $TEMP > $TARGET
     else
-    	echo "can't find nfnetlink_queue.h kernel file"
+    	echo "can't find nfnetlink_queue.h kernel file in $INCLUDEDIR"
     	exit 1
     fi
 }

[-- Attachment #4: Type: TEXT/PLAIN, Size: 1068 bytes --]


[libnetfilter_conntrack] Add KERNEL_DIR support to autogen.sh

Allow user to specify custom KERNEL_DIR to support building library
against selected kernel tree.

Signed-off-by: Krzysztof Piotr Oledzki <ole@ans.pl>

Index: autogen.sh
===================================================================
--- autogen.sh	(revision 4538)
+++ autogen.sh	(working copy)
@@ -7,7 +7,7 @@
     # the headers that we need from the lastest kernel version at autogen
     # stage.
 
-    INCLUDEDIR=/lib/modules/`uname -r`/build/include/linux
+    INCLUDEDIR=${KERNEL_DIR:-/lib/modules/`uname -r`/build}/include/linux
     if [ -f $INCLUDEDIR/netfilter/nfnetlink_conntrack.h ]
     then
     	TARGET=include/libnetfilter_conntrack/linux_nfnetlink_conntrack.h
@@ -17,7 +17,7 @@
 	sed 's/linux\/netfilter\/nfnetlink.h/libnfnetlink\/linux_nfnetlink.h/g' $TARGET > $TEMP
 	mv $TEMP $TARGET
     else
-    	echo "can't find nfnetlink_conntrack.h kernel file"
+    	echo "can't find nfnetlink_conntrack.h kernel file in $INCLUDEDIR"
     	exit 1
     fi
 }

[-- Attachment #5: Type: TEXT/PLAIN, Size: 990 bytes --]


[libnfnetlink] Add KERNEL_DIR support to autogen.sh

Allow user to specify custom KERNEL_DIR to support building library
against selected kernel tree.

Signed-off-by: Krzysztof Piotr Oledzki <ole@ans.pl>

Index: autogen.sh
===================================================================
--- autogen.sh	(revision 4538)
+++ autogen.sh	(working copy)
@@ -7,14 +7,15 @@
     # the headers that we need from the lastest kernel version at autogen
     # stage.
 
-    INCLUDEDIR=/lib/modules/`uname -r`/build/include/linux
+    INCLUDEDIR=${KERNEL_DIR:-/lib/modules/`uname -r`/build}/include/linux
+
     if [ -f $INCLUDEDIR/netfilter/nfnetlink.h ]
     then
     	TARGET=include/libnfnetlink/linux_nfnetlink.h
     	echo "Copying nfnetlink.h to linux_nfnetlink.h"
     	cp $INCLUDEDIR/netfilter/nfnetlink.h $TARGET
     else
-    	echo "can't find nfnetlink.h kernel file"
+    	echo "can't find nfnetlink.h kernel file in $INCLUDEDIR"
     	exit 1
     fi
 }

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [PATCH] KERNEL_DIR support in autogen.sh for libnfnetlink/libnetfilter_conntrack
  2005-11-15 13:15   ` Krzysztof Oledzki
@ 2005-11-17 12:55     ` Harald Welte
  0 siblings, 0 replies; 6+ messages in thread
From: Harald Welte @ 2005-11-17 12:55 UTC (permalink / raw)
  To: Krzysztof Oledzki; +Cc: netfilter-devel, Pablo Neira

[-- Attachment #1: Type: text/plain, Size: 578 bytes --]

On Tue, Nov 15, 2005 at 02:15:48PM +0100, Krzysztof Oledzki wrote:
> Attached four patches for libnetfilter_log, libnetfilter_queue,
> libnetfilter_conntrack and finally libnfnetlink.

thanks, applied.
-- 
- Harald Welte <laforge@netfilter.org>                 http://netfilter.org/
============================================================================
  "Fragmentation is like classful addressing -- an interesting early
   architectural error that shows how much experimentation was going
   on while IP was being designed."                    -- Paul Vixie

[-- Attachment #2: Type: application/pgp-signature, Size: 189 bytes --]

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2005-11-17 12:55 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2005-11-14 23:48 [PATCH] KERNEL_DIR support in autogen.sh for libnfnetlink/libnetfilter_conntrack Krzysztof Oledzki
2005-11-15  0:25 ` Pablo Neira
2005-11-15 13:15   ` Krzysztof Oledzki
2005-11-17 12:55     ` Harald Welte
2005-11-15  8:11 ` Sven Schuster
2005-11-15  8:14   ` Sven Schuster

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.