Skip to contentSkip to conversation

iptables-1.4.0 with 2.6.26

DISCUSSION Hinko Kocevar 2 participants 6 messages Aug 19, 2008

lore
Share & tools
lore
#0 lore raw

Hi,

Trying to build iptables-1.4.0 with 2.6.26 kernel on x86 fails with:

hinkok@alala /tmp/iptables-1.4.0 $ make
Extensions found:
cc -O2 -Wall -Wunused -I"/lib/modules/2.6.26/build"/include -I"/lib/modules/2.6.26/source"/include -Iinclude/ -DIPTABLES_VERSION=\"1.4.0\" -fPIC -o extensions/libxt_sctp_sh.o -c extensions/libxt_sctp.c In file included from extensions/libxt_sctp.c:23:
/lib/modules/2.6.26/build/include/linux/netfilter/xt_sctp.h:68: error: expected '=', ',', ';', 'asm' or '__attribute__' before '__sctp_chunkmap_is_clear' /lib/modules/2.6.26/build/include/linux/netfilter/xt_sctp.h:80: error: expected '=', ',', ';', 'asm' or '__attribute__' before '__sctp_chunkmap_is_all_set' extensions/libxt_sctp.c: In function 'print_chunks':
extensions/libxt_sctp.c:416: warning: implicit declaration of function '__sctp_chunkmap_is_clear'
extensions/libxt_sctp.c:421: warning: implicit declaration of function '__sctp_chunkmap_is_all_set'
make: *** [extensions/libxt_sctp_sh.o] Error 1

I think it complains about the bool type.

Regards,
Hinko

Signature · 7 lines
ČETRTA POT, d.o.o., Kranj
Planina 3
4000 Kranj
Slovenia, Europe
Tel. +386 (0) 4 280 66 03
E-mail: [email protected]
Http: www.cetrtapot.si
#2 lore raw
In reply to Phil Oester
Quoted 7 lines · Phil Oester
Quoted 3 lines · Hinko Kocevar

Hi,

Trying to build iptables-1.4.0 with 2.6.26 kernel on x86 fails with:

Try 1.4.1.1 instead?

Well, it builds.
But trying to add simple rule fails:

hinkok@alala /tmp/iptables-1.4.1.1 $ sudo ./iptables -A INPUT -p tcp --dport 80 -j DROP iptables v1.4.1.1: Unknown arg `--dport'
Try `iptables -h' or 'iptables --help' for more information.

Regards,
Hinko

Signature · 7 lines
ČETRTA POT, d.o.o., Kranj
Planina 3
4000 Kranj
Slovenia, Europe
Tel. +386 (0) 4 280 66 03
E-mail: [email protected]
Http: www.cetrtapot.si
#3 lore raw
In reply to Hinko Kocevar
Quoted 6 lines · Hinko Kocevar

Well, it builds.
But trying to add simple rule fails:

hinkok@alala /tmp/iptables-1.4.1.1 $ sudo ./iptables -A INPUT -p tcp --dport 80 -j DROP iptables v1.4.1.1: Unknown arg `--dport'
Try `iptables -h' or 'iptables --help' for more information.

Yes, that wouldn't work unless you built a static iptables binary (--enable-static). Please run make install, then it will work for you from the install directory.

Phil

#4 lore raw
Quoted 9 lines · Phil Oester
Quoted 6 lines · Hinko Kocevar

Well, it builds.
But trying to add simple rule fails:

hinkok@alala /tmp/iptables-1.4.1.1 $ sudo ./iptables -A INPUT -p tcp --dport 80 -j DROP iptables v1.4.1.1: Unknown arg `--dport'
Try `iptables -h' or 'iptables --help' for more information.

Yes, that wouldn't work unless you built a static iptables binary (--enable-static).

Tried and it works, with forcing symlink on iptables-static.
hinkok@alala /tmp/iptables-1.4.1.1 $ rm iptables
hinkok@alala /tmp/iptables-1.4.1.1 $ ln -s iptables-static iptables hinkok@alala /tmp/iptables-1.4.1.1 $ sudo ./iptables -A INPUT -p tcp --dport 80 -j DROP hinkok@alala /tmp/iptables-1.4.1.1 $

Quoted 1 line

Please run make install, then it will work for you from the install directory.

Will this be a problem on an embedded system, when iptables are cross compiled?
Are there some cynimic libraries that are pulled in from somewhere (probably destdir installation dir)?

Thank you,
Hinko

Signature · 7 lines
ČETRTA POT, d.o.o., Kranj
Planina 3
4000 Kranj
Slovenia, Europe
Tel. +386 (0) 4 280 66 03
E-mail: [email protected]
Http: www.cetrtapot.si
#5 lore raw
Quoted 4 lines · Hinko Kocevar
Quoted 1 line

Please run make install, then it will work for you from the install directory.

Will this be a problem on an embedded system, when iptables are cross compiled?
Are there some cynimic libraries that are pulled in from somewhere (probably destdir installation dir)?

Well, if you use the non-static version, then you need the various .so files - see /lib/xtables/lib*.

Phil