Subject: compiling ping6 on current failed
To: Matthias Scheler <tron@zhadum.de>
From: Patrick Welche <prlw1@newn.cam.ac.uk>
List: current-users
Date: 03/10/2005 12:58:00
On Wed, Mar 09, 2005 at 08:42:07PM +0000, Matthias Scheler wrote:
> On Wed, Mar 09, 2005 at 07:49:46PM +0000, Patrick Welche wrote:
> > Yup that's now fine thanks - the next stopage is at
> > 
> > #      link  ping6/ping6
> 
> Works for me on NetBSD-i386. Did you try a full build?

Hmm.. same again:

#      link  ping6/ping6
/usr/src/obj.i386/tooldir.NetBSD-2.99.16-i386/bin/i386--netbsdelf-gcc -Wl,-nostdlib     -o ping6  -Wl,-dynamic-linker=/libexec/ld.elf_so -Wl,-rpath-link,/destdir/i386/lib:/destdir/i386/usr/lib  -R/lib  -L/destdir/i386/lib  -B/destdir/i386/usr/lib/ -B/destdir/i386/usr/lib/   ping6.o -lipsec -lm   -L/destdir/i386/usr/lib -L/destdir/i386/usr/lib
ping6.o(.text+0x1170): In function `main':
: undefined reference to `inet6_rthdr_init'
ping6.o(.text+0x11d3): In function `main':
: undefined reference to `inet6_rthdr_add'
ping6.o(.text+0x1204): In function `main':
: undefined reference to `inet6_rthdr_lasthop'
ping6.o(.text+0x166f): In function `main':
: undefined reference to `inet6_rthdr_space'
collect2: ld returned 1 exit status

quartz% nm -g /destdir/i386/lib/libc.so | grep inet6_r
quartz% nm -g /lib/libc.so | grep inet6_r
0002c750 T _inet6_rthdr_add
0002c894 T _inet6_rthdr_getaddr
0002c8fc T _inet6_rthdr_getflags
0002c6d4 T _inet6_rthdr_init
0002c7f4 T _inet6_rthdr_lasthop
0002c844 T _inet6_rthdr_segments
0002c670 T _inet6_rthdr_space
0002c750 W inet6_rthdr_add
0002c894 W inet6_rthdr_getaddr
0002c8fc W inet6_rthdr_getflags
0002c6d4 W inet6_rthdr_init
0002c7f4 W inet6_rthdr_lasthop
0002c844 W inet6_rthdr_segments
0002c670 W inet6_rthdr_space
quartz% ls -l /lib/libc.so*
lrwxr-xr-x  1 root  wheel      14 Feb 25 20:37 /lib/libc.so -> libc.so.12.125
lrwxr-xr-x  1 root  wheel      14 Feb 25 20:37 /lib/libc.so.12 -> libc.so.12.125
-r--r--r--  1 root  wheel  866413 Feb 25 20:32 /lib/libc.so.12.125
quartz% ls -l /destdir/i386/lib/libc.so*
lrwxr-xr-x  1 root  wheel      14 Mar 10 12:05 /destdir/i386/lib/libc.so -> libc.so.12.125
lrwxr-xr-x  1 root  wheel      14 Mar 10 12:05 /destdir/i386/lib/libc.so.12 -> libc.so.12.125
-r--r--r--  1 root  wheel  860271 Mar 10 12:05 /destdir/i386/lib/libc.so.12.125

and the differences between /destdir and / are
- the source (/destdir from now)
- I added MKPAM=no to /etc/mk.conf (MKKERBEROS=no is already there)

Curiouser and curiouser..

Cheers,

Patrick