Your kernel is probably compiled with MODVERSIONS, which requires the
appropriate options when compiling kernel modules. See attached message
on the subject of compiling ip_wccp.o.
-- Henrik Nordstrom Squid hacker Daren McGill wrote: > > Thank you for the information we have gotten the code to compile to the > module however when we do a modprobe wccp.o this is what we receive. We > have tried to configure the sever at this point but it doesn't seem to > work. Any ideas. > > /lib/modules/2.2.12-20smp/ipv4/ip_wccp.o: unresolved symbol __kfree_skb > /lib/modules/2.2.12-20smp/ipv4/ip_wccp.o: unresolved symbol > inet_del_protocol > /lib/modules/2.2.12-20smp/ipv4/ip_wccp.o: unresolved symbol > inet_add_protocol > /lib/modules/2.2.12-20smp/ipv4/ip_wccp.o: unresolved symbol ip_rcv > /lib/modules/2.2.12-20smp/ipv4/ip_wccp.o: unresolved symbol printk > > Thanks, > Daren >
attached mail follows:
You would compile it exacly like the other modules are compiled when you
build your kernel. Easies way is to copy a gcc line from the output of
"make modules". The exact line depends on what modules support you have
configured in your kernel, where the kernel sources are installed and
any CPU specific flags.
A example from my machine is
gcc -D__KERNEL__ -I/usr/src/linux-2.2.13/include -Wall
-Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strict-aliasing -pipe
-fno-strength-reduce -m486 -malign-loops=2 -malign-jumps=2
-malign-functions=2 -DCPU=586 -DMODULE -DMODVERSIONS -include
/usr/src/linux-2.2.13/include/linux/modversions.h -DEXPORT_SYMTAB -c
ip_wccp.c
Shortened down to the minimal:
gcc -D__KERNEL__ -I/usr/src/linux-2.2.13/include -DMODULE -DMODVERSIONS
-include /usr/src/linux-2.2.13-/include/linux/modversions.h -c ip_wccp.c
If you aren't using modversions, then the minimal line becomes
gcc -D__KERNEL__ -I/usr/src/linux-2.2.13/include -DMODULE -c ip_wccp.c
The -f, -m and -O flags are optimizations, specific to your CPU type.
The -DEXPORT_SYMTAB can be ignored on this module as it doesn't export
any symbols to the rest of the kernel.
/Henrik
Walter Klomp wrote:
>
> Hi Henrik,
>
> I am a newbie on compiling and installing modules... How would I compile
> this module?
>
> just gcc ip_wccp.c ?
>
> or do I need to do something else ?
>
> Sorry for my ignorance,
>
> Thanks.
>
> -----Original Message-----
> From: hno@hem.passagen.se [mailto:hno@hem.passagen.se]
> Sent: Saturday, January 29, 2000 3:21 AM
> To: Walter Klomp
> Cc: squid-users@ircache.net
> Subject: Re: WCCP with 2.3Stable1 & Cisco
>
> Walter Klomp wrote:
>
> > I have just downloaded kernel 2.2.14, re-applied the patch to ip_gre.c,
> > re-compiled it...
>
> What Glenn is referring to is his ip_wccp module, not the patch to
> ip_gre.
>
> ip_wccp is a minimal GRE module only capable of decapsulating WCCP GRE
> capsulated IP packets. This module is downloadable from
> http://www.squid-cache.org/WCCP-support/Linux/ip_wccp.c
>
> See also Squid FAQ 17.10
> <http://www.squid-cache.org/Doc/FAQ/FAQ-17.html#ss17.10>
>
> --
> Henrik Nordstrom
> Squid Hacker
Received on Tue Apr 11 2000 - 15:18:13 MDT
This archive was generated by hypermail pre-2.1.9 : Tue Dec 09 2003 - 16:52:54 MST