Subject: Re: not finding libraries that exist in /usr/pkg/lib
To: Tracy Di Marco White <>
From: Jared D. McNeill <>
List: tech-pkg
Date: 04/01/2001 19:17:26
Quoting Tracy Di Marco White <>:
> All of these libraries are in /usr/pkg/lib.
> I'd like to understand how to fix this, because I've been attempting
> to
> create a package myself that I can't figure out how to make it use the
> libraries in /usr/pkg/lib without setting LD_LIBRARY_PATH.  At least,
> I
> consider having to set LD_LIBRARY_PATH not the right solution.

You need to add the following flags to the compiler during the linking stage:

  -L${LOCALBASE}/lib -Wl,-R${LOCALBASE}/lib


Jared D. McNeill -
Computer Programming Technology
New Brunswick Community College, Saint John