Date: Fri, 20 Oct 2000 22:10:57 +0200 From: Chive <lex@blacktrap.net> To: freebsd-questions@FreeBSD.ORG Subject: Re: linking oddness Message-ID: <20001020221057.A40152@blacktrap.net> In-Reply-To: <20001020135840.P11549@genuity.net>; from jdiehl@genuity.net on Fri, Oct 20, 2000 at 01:58:40PM -0400 References: <20001020135840.P11549@genuity.net>
next in thread | previous in thread | raw e-mail | index | archive | help
On Fri, Oct 20, 2000 at 01:58:40PM -0400, Joe Diehl wrote: > I was wondering if someone can help me out here, seeing as I'm now rather lost. > I'm having problems with linking libraries that I install in /usr/local/lib. > > For instance: > > $ LD_LIBRARY_PATH=/usr/local/lib:/usr/lib:/usr/X11R6/lib:/lib > $ export LD_LIBRARY_PATH > $ gcc -o test test.o -ljpeg > /usr/libexec/elf/ld: cannot find -ljpeg > $ gcc -o test test.o -L/usr/local/lib -ljpeg > $ ldd test > test: > libjpeg.so.62 => /usr/local/lib/libjpeg.so.62 (0x28064000) > libc.so.4 => /usr/lib/libc.so.4 (0x28082000) > LIBRARY_PATH is the variable to use for compilation... Wonder why this isn't in gcc or ld manpage. You can find it with "info gcc". Ciao, Chive. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20001020221057.A40152>