Current-Users archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: building source against installed libraries?



On Mon, Oct 31, 2022 at 01:46:56PM +0300, Valeriy E. Ushakov wrote:
> On Mon, Oct 31, 2022 at 11:10:24 +0100, Thomas Klausner wrote:
> 
> > For test builds, I use 'USETOOLS=no make' to avoid building a
> > toolchain.  However that still wants to link against libraries built
> > in the source tree, i.e. I have to 'cd /usr/src/lib/libcrypto &&
> > USETOOLS=no make' to build a new libcrypto if this library is used.
> > 
> > Is there a toggle to build against the installed libraries instead?
> 
> It's entirely unclear from this description what exactly you are
> trying to do and how does it fail.

I'm trying this:

wiz@yt:/usr/src/external/bsd/nsd> USETOOLS=no make

and get
...
all ===> lib/libnsd
all ===> lib/libxfrd
all ===> sbin
all ===> sbin/nsd
make[2]: don't know how to make /disk/6/archive/foreign/src/external/bsd/libevent/lib/libevent/libevent.a. Stop

I want the build to use /usr/lib/libevent.a instead.

> If I have to venture a guess (I don't have time atm to second guess/
> reverse engineer the question), you are probably running into
> something like LIBDPLIBS dependencies that are explicitly listed in
> the in-tree makefiles, b/c those makefiles are intended to build the
> in-tree code (e.g. for curses I would disable its LIBDPLIBS dependency
> on terminfo).  Just overriding them on the command line might help.

I guess this is

./Makefile.inc:DPLIBS+= event ${NETBSDSRCDIR}/external/bsd/libevent/lib/libevent

so perhaps what you're talking about?

What do I have to set? Do I have to do this for every library
separately?
 Thomas


Home | Main Index | Thread Index | Old Index