.configure && make fails to find ld [dlopen]

Simon J. Gerraty sjg at juniper.net
Thu Jul 6 00:15:46 UTC 2017


blubee blubeeme <gurenchan at gmail.com> wrote:
> I run autoreconf -fi and it asks me to add AC_CONFIG_MACRO_DIRS([m4]) to my
> configure.ac file, which I do. It creates a ./m4 directory and proceeds.
> 
> After running .configure --prefix=/tmp [for testing] that' also goes fine,
> except .configure cannot find dlopen
> checking for dlopen in -ldl... no

dlopen is actually implemeted in the rtld - so you need to link at least
one shared lib (usually libc) to get it.

> make also fails when it comes time to link because of the dlopen although
> it's a part of FreeBSD libc

Check that you don't have -static or equivalent in CFLAGS/LDFLAGS.


More information about the freebsd-current mailing list