Problem with inlines for linux-2.2.1-ac2, and egcs-2.93.03 19990129

Richard Ketchersid ketchers@pacbell.net
Sun Jan 31 02:35:00 GMT 1999


While trying to build the kernel several symbols needed by network.a fail
to get defined due to inlining difficulties ? Here is an example, notice
the problem with skb_put:

=======================================================================
gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O3
-fomit-frame-pointer -pipe -fno-strength-reduce -m486 -DCPU=486
 -Winline -c -o test.o af_packet.c
/usr/src/linux/include/linux/skbuff.h: In function `skb_put':
In file included from /usr/src/linux/include/linux/netdevice.h:158,
                 from af_packet.c:52:
/usr/src/linux/include/linux/skbuff.h:453: warning: function with label
addresses taken cannot inline
/usr/src/linux/include/linux/skbuff.h: In function `skb_push':
/usr/src/linux/include/linux/skbuff.h:467: warning: function with label
addresses taken cannot inline
/usr/src/linux/include/linux/skbuff.h: In function `__nlmsg_put':
/usr/src/linux/include/linux/skbuff.h:453: warning: can't inline call to
`skb_put'
In file included from /usr/src/linux/include/linux/rtnetlink.h:5,
                 from /usr/src/linux/include/net/route.h:29,
                 from /usr/src/linux/include/net/ip.h:32,
                 from af_packet.c:56:
/usr/src/linux/include/linux/netlink.h:135: warning: called from here
/usr/src/linux/include/linux/skbuff.h: In function `ip_finish_output':
/usr/src/linux/include/linux/skbuff.h:467: warning: can't inline call to
`skb_push'
In file included from af_packet.c:56:
/usr/src/linux/include/net/ip.h:151: warning: called from here
=========================================================================

In the end when trying to link the kernel you get: packet.o = af_packet.o

net/network.a(netlink.o)(.text+0xac4): more undefined references to
`skb_put' follow
net/network.a(packet.o): In function `packet_rcv_spkt':
packet.o(.text+0x37): undefined reference to `skb_push'
net/network.a(packet.o): In function `packet_sendmsg_spkt':
packet.o(.text+0x1fd): undefined reference to `skb_put'
net/network.a(packet.o): In function `packet_rcv':
packet.o(.text+0x303): undefined reference to `skb_push'
net/network.a(packet.o): In function `packet_sendmsg':
packet.o(.text+0x501): undefined reference to `skb_put'
make: *** [vmlinux] Error 1

-- Thanks

-- 
Richard Ketchersid                                            _/_/   _/_/+
UC Berkeley, Logic Group                                     _/_/_/  _/ _/
816 Evans                                                   _/    _/ _/_/







More information about the Gcc-bugs mailing list