[Openswan dev] ipcomp.c: structure has no member named `ips_comp_adapt_skip'

Axel Thimm Axel.Thimm at ATrpms.net
Sat Apr 10 18:30:27 CEST 2004


Hi,

On Sat, Apr 10, 2004 at 04:29:38PM +0200, Ken Bantoft wrote:
> On Sat, 10 Apr 2004, Axel Thimm wrote:
> > I have built FC1 kernels with openswan 2.1.1 natt/kern patches
> > included and the following config:
> > 
> > [...]
> > # CONFIG_IPSEC_IPCOMP is not set
> 
> Flip this on, and see if the error still occurs, which I'm pretty sure it 
> won't.  However, read below for an explaination.
> 
> > Building openswan against such a kernel (*), I get the following
> > error:
> > /usr/bin/gcc32  -DIPCOMP_PREFIX -I../../include -I/amd/heretic/1/data_nobkp/bach/bach-kernel/rhfc1/2.4.22-1.2174.nptl_44.rhfc1.at-i686/include -I../. ./lib/zlib  -Wall -DARCH=i386  -DMODVERSIONS -include /amd/heretic/1/data_nobkp/bach/bach-kernel/rhfc1/2.4.22-1.2174.nptl_44.rhfc1.at-i686/include/linux/modversions.h -include /tmp/atrpms-mykernel-2.4.22-1.2174.nptl_44.rhfc1.at-i686.h -DMODULE -DMODVERSIONS -include /amd/heretic/1/data_nobkp/bach/bach-kernel/rhfc1/2.4.22-1.2174.nptl_44.rhfc1.at-i686/include/linux/modversions.h -include /var/tmp/bach-build/BUILD/openswan-2.1.1/autoconf_ipsec.h  -D __KERNEL__ -I/amd/heretic/1/data_nobkp/bach/bach-kernel/rhfc1/2.4.22-1.2174.nptl_44.rhfc1.at-i686/include -Wall -Wstrict-prototypes -Wno-trigraphs -O2 -fomit-frame-pointer -fno-strict-aliasing -fno-common -fomit-frame-pointer -pipe -mpreferred-stack-boundary=2 -march=i686 -DKBUILD_BASENAME=ipcomp   -c -o ipcomp.o ipcomp.c
> > ipcomp.c: In function `skb_compress':
> > ipcomp.c:169: structure has no member named `ips_comp_adapt_skip'
> > [...]

> It seems 'struct ipsec_sa *ips', which is passed to skb_compress() doesn't 
> have all members of struct if CONFIG_IPSEC_IPCOMP is disabled.
> 
> linux/include/openswan/ipsec_sa.h:181
> 
> #ifdef CONFIG_IPSEC_IPCOMP
>         __u16           ips_comp_adapt_tries;   /* ipcomp self-adaption tries */
>         __u16           ips_comp_adapt_skip;    /* ipcomp self-adaption to-skip */
>         __u64           ips_comp_ratio_cbytes;  /* compressed bytes */   
>         __u64           ips_comp_ratio_dbytes;  /* decompressed (or uncompressed bytes) */
> #endif /* CONFIG_IPSEC_IPCOMP */
> 
> So you could always just remove the #ifdefs and keep compression disabled 
> and see if that builds, or we need to #ifdef around the ipcomp code.

I just noticed, that I was trying to build the externally built
modules with CONFIG_IPSEC_IPCOMP on. So the patched in version had it
off, and building openswan with CONFIG_IPSEC_IPCOMP=y mixed the
headers of the openswan tarball and the kernel source tree.

This bug only triggers if you already have openswan patched in and you
build a new module with different CONFIG_* options than used for the
kernel's version. I'll try to find a workaround for the rpms, perhaps
it is the only current scenario where this matters.
-- 
Axel.Thimm at ATrpms.net
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: not available
Url : http://lists.openswan.org/pipermail/dev/attachments/20040410/0631be6a/attachment.bin


More information about the Dev mailing list