Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 61784 - iptables 1.2.11-r2 doesn't compile on system with default-1.0 profile
Summary: iptables 1.2.11-r2 doesn't compile on system with default-1.0 profile
Status: RESOLVED CANTFIX
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: New packages (show other bugs)
Hardware: x86 Linux
: High normal (vote)
Assignee: Daniel Ahlberg (RETIRED)
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2004-08-26 03:56 UTC by Ronald Moesbergen
Modified: 2005-05-03 05:34 UTC (History)
2 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Ronald Moesbergen 2004-08-26 03:56:52 UTC
iptables 1.2.11-r2 compile aborts with the following error:

ld -shared  -o extensions/libipt_ULOG.so extensions/libipt_ULOG_sh.o
gcc -march=i686 -O3 -pipe -Wall -Wunused -I/usr/include -Iinclude/ -DIPTABLES_VERSION=\"1.2.11\"  -DIPT_LIB_DIR=\"/lib/iptables\" -c -o iptables.o iptables.c
iptables.c:238: `IPPROTO_SCTP' undeclared here (not in a function)
iptables.c:238: initializer element is not constant
iptables.c:238: (near initialization for `chain_protos[5].num')
iptables.c:349: warning: `struct iptables_rule_match' declared inside parameter list
iptables.c:349: warning: its scope is only this definition or declaration, which is probably not what you want.
iptables.c: In function `exit_printhelp':
iptables.c:423: dereferencing pointer to incomplete type
iptables.c:425: dereferencing pointer to incomplete type
iptables.c: At top level:
iptables.c:667: warning: `struct iptables_rule_match' declared inside parameter list
iptables.c:668: conflicting types for `find_match'
/usr/include/iptables.h:137: previous declaration of `find_match'
iptables.c: In function `find_match':
iptables.c:712: sizeof applied to an incomplete type
iptables.c:714: dereferencing pointer to incomplete type
iptables.c:715: dereferencing pointer to incomplete type
iptables.c:716: dereferencing pointer to incomplete type
iptables.c: At top level:
iptables.c:725: warning: `struct iptables_rule_match' declared inside parameter list
iptables.c: In function `find_proto':
iptables.c:733: warning: passing arg 3 of `find_match' from incompatible pointer type
iptables.c:735: warning: passing arg 3 of `find_match' from incompatible pointer type
iptables.c: At top level:
iptables.c:1404: warning: `struct iptables_rule_match' declared inside parameter list
iptables.c: In function `make_delete_mask':
iptables.c:1412: dereferencing pointer to incomplete type
iptables.c:1413: dereferencing pointer to incomplete type
iptables.c:1422: dereferencing pointer to incomplete type
iptables.c:1425: dereferencing pointer to incomplete type
iptables.c:1425: dereferencing pointer to incomplete type
iptables.c:1425: dereferencing pointer to incomplete type
iptables.c:1425: dereferencing pointer to incomplete type
iptables.c:1425: warning: unreachable code at beginning of switch statement
iptables.c:1425: dereferencing pointer to incomplete type
iptables.c:1425: dereferencing pointer to incomplete type
iptables.c:1426: dereferencing pointer to incomplete type
iptables.c: At top level:
iptables.c:1445: warning: `struct iptables_rule_match' declared inside parameter list
iptables.c: In function `delete_entry':
iptables.c:1451: warning: passing arg 2 of `make_delete_mask' from incompatible pointer type
iptables.c: At top level:
iptables.c:1653: warning: `struct iptables_rule_match' declared inside parameter list
iptables.c: In function `generate_entry':
iptables.c:1660: dereferencing pointer to incomplete type
iptables.c:1661: dereferencing pointer to incomplete type
iptables.c:1669: dereferencing pointer to incomplete type
iptables.c:1670: dereferencing pointer to incomplete type
iptables.c:1670: dereferencing pointer to incomplete type
iptables.c:1671: dereferencing pointer to incomplete type
iptables.c: At top level:
iptables.c:1678: warning: `struct iptables_rule_match' declared inside parameter list
iptables.c: In function `clear_rule_matches':
iptables.c:1683: dereferencing pointer to incomplete type
iptables.c:1684: dereferencing pointer to incomplete type
iptables.c:1685: dereferencing pointer to incomplete type
iptables.c: In function `do_command':
iptables.c:1867: warning: passing arg 3 of `find_match' from incompatible pointer type
iptables.c:1869: warning: passing arg 1 of `exit_printhelp' from incompatible pointer type
iptables.c:1972: warning: passing arg 3 of `find_match' from incompatible pointer type
iptables.c:2064: dereferencing pointer to incomplete type
iptables.c:2065: dereferencing pointer to incomplete type
iptables.c:2065: dereferencing pointer to incomplete type
iptables.c:2067: dereferencing pointer to incomplete type
iptables.c:2070: dereferencing pointer to incomplete type
iptables.c:2073: dereferencing pointer to incomplete type
iptables.c:2107: warning: passing arg 4 of `find_proto' from incompatible pointer type
iptables.c:2136: dereferencing pointer to incomplete type
iptables.c:2137: dereferencing pointer to incomplete type
iptables.c:2137: dereferencing pointer to incomplete type
iptables.c:2258: warning: passing arg 2 of `generate_entry' from incompatible pointer type
iptables.c:2274: warning: passing arg 9 of `delete_entry' from incompatible pointer type
iptables.c:2335: warning: passing arg 1 of `clear_rule_matches' from incompatible pointer type
iptables.c:1680: warning: `tmp' might be used uninitialized in this function
iptables.c: In function `clear_rule_matches':
iptables.c:1680: warning: `tmp' might be used uninitialized in this function
make: *** [iptables.o] Error 1

!!! ERROR: net-firewall/iptables-1.2.11-r2 failed.
!!! Function src_compile, Line 99, Exitcode 2
!!! (no error message)

This is probably due to linux-headers being too old in this profile, the SCTP protocol is undefined.

Reproducible: Always
Steps to Reproduce:
1. emerge iptables on a 1.0 profile system.

Actual Results:  
Compile error

Expected Results:  
Compile and install.

Portage 2.0.50-r9 (default-1.0, gcc-2.95.3, glibc-2.2.5-r9, 2.6.7)
=================================================================
System uname: 2.6.7 i686 Pentium II (Deschutes)
Gentoo Base System version 1.4.16
Autoconf: sys-devel/autoconf-2.59-r4
Automake: sys-devel/automake-1.8.3
ACCEPT_KEYWORDS="x86"
AUTOCLEAN="yes"
CFLAGS="-march=i686 -O3 -pipe"
CHOST="i686-pc-linux-gnu"
COMPILER=""
CONFIG_PROTECT="/etc /usr/kde/2/share/config /usr/kde/3/share/config /usr/share/
config /var/qmail/control"
CONFIG_PROTECT_MASK="/etc/gconf /etc/terminfo /etc/env.d"
CXXFLAGS="-O2 -mcpu=i686 -pipe"
DISTDIR="/usr/portage/distfiles"
FEATURES="autoaddcvs ccache sandbox"
GENTOO_MIRRORS="http://ftp.snt.utwente.nl/pub/os/linux/gentoo"
MAKEOPTS="-j2"
PKGDIR="/usr/portage/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY=""
SYNC="rsync://172.30.11.246/gentoo-portage"
USE="gdbm mmx pam ssl x86"
Comment 1 Klaus Kusche 2004-08-29 02:14:31 UTC
Same here (with gcc-3.1.1 and the "official" linux-headers-2.4.21-r1).
Comment 2 Paul Slinski 2005-01-04 10:49:42 UTC
Man...this is old and I'm having this problem as well. Was there ever a fix?
Comment 3 Klaus Kusche 2005-01-05 01:43:33 UTC
It's just a question of playing around with linux-headers.
For me, iptables-1.2.11-r3 currently emerges without errors.
However, I dropped linux-headers-2.4.21-r1 and installed linux26-headers-2.6.8.1-r1 (I also run a 2.6 kernel).
Comment 4 Paul Slinski 2005-01-05 08:16:27 UTC
That's a bit of a problem on my system.
I can't change the headers without rebuiling glibc and I can't rebuild glibc with 2.6 headers and gcc2. On top of the the upgrade guide (from gcc2 -> gcc3) is no longer valid due to portage changes.

Anyhow, I suppose I'll have to re-build the entire system unless this bug is fixable and the upgrade docs are repaired.
Comment 5 Robin Johnson archtester Gentoo Infrastructure gentoo-dev Security 2005-05-03 02:47:44 UTC
sorry guys, you must have the newer linux-headers to compile iptables.
re-installing such old machines is probably the easiest route.
Comment 6 Paul Slinski 2005-05-03 05:34:19 UTC
:-( Yeah, that's what I thought.

Thanks.