Subject: Re: CVS commit: pkgsrc/mk/compiler
To: Johnny C. Lam <jlam@NetBSD.org>
From: Manuel Bouyer <bouyer@antioche.lip6.fr>
List: tech-pkg
Date: 02/09/2004 14:26:31
Hi,
On Sat, Feb 07, 2004 at 11:54:40PM +0000, Johnny C. Lam wrote:
> This particular problem you're experiencing is actually a
> openssh*/Makefile problem as it redefines LD to ${CC}, which is
> generally a bad thing to do (as you've noted). It should just pass
> LD=${CC} to the configure process as the comment in the Makefile says
> that it wants to do.
You commit fix this problem, but now the build fails at link time. It seems
it because it doesn't add -lc to the libraries:
ld -o ssh ssh.o readconf.o clientloop.o sshtty.o sshconnect.o sshconnect1.o sshconnect2.o -L. -Lopenbsd-compat/ -L/usr/local/lib -L/usr/local/lib -L/usr/local/gcc-3.3.2/lib/gcc-lib/sparc64-sun-solaris2/3.3.2 -Wl,-R/usr/local/gcc-3.3.2/lib/gcc-lib/sparc64-sun-solaris2/3.3.2 -L/usr/local/gcc-3.3.2/lib -Wl,-R/usr/local/gcc-3.3.2/lib -L/usr/local/lib -Wl,-R/usr/local/lib -L/usr/local/lib -R/usr/local/lib -L/usr/local/lib -lssh -lopenbsd-compat -lrt -lskey -lz -lsocket -lnsl -lcrypto
Undefined first referenced
symbol in file
setuid ssh.o (symbol belongs to implicit dependency /lib/64/libc.so.1)
cfsetospeed ./libssh.a(ttymodes.o) (symbol belongs to implicit dependency /lib/64/libc.so.1)
strcspn ./libssh.a(readpass.o) (symbol belongs to implicit dependency /lib/64/libc.so.1)
[...]
With the previous Makefile, just removind ld from .buildink/bin allowed
a successfull build. I don't know what the difference is ...
--
Manuel Bouyer <bouyer@antioche.eu.org>
NetBSD: 26 ans d'experience feront toujours la difference
--