Hello,

Are you linking with libdl.so? (-ldl)

-Tom


Thomas Floodeen, Jr.
Mentor Graphics BSD
720.494.1133


-----Original Message-----
From: owner-openssl-us...@openssl.org [mailto:owner-openssl-us...@openssl.org] 
On Behalf Of zero modulo
Sent: Sunday, March 17, 2013 10:33 PM
To: openssl-users@openssl.org
Subject: libcrypto.a linking problem?

I'm unable to build Git 1.8.1.3 with libcrypto. I've compiled and built OpenSSL 
with the same LDFLAGS and CPPFLAGS as below. I also have a 
`/etc/ld.so.conf.d/sandbox.conf` file which loads `/sandbox/builds/lib` as a 
library path for LD_LIBRARY_PATH.

$ uname -a
Linux kosuna 3.5.0-17-generic #28-Ubuntu SMP Tue Oct 9 19:32:08 UTC
2012 i686 athlon i686 GNU/Linux

$ LDFLAGS="-L/sandbox/builds/lib" CPPFLAGS="-I/sandbox/builds/include"
./configure --prefix=$PREFIX
[...]
$ make
/sandbox/builds/lib/libcrypto.a(dso_dlfcn.o): In function `dlfcn_globallookup':
dso_dlfcn.c:(.text+0x1b): undefined reference to `dlopen'
dso_dlfcn.c:(.text+0x31): undefined reference to `dlsym'
dso_dlfcn.c:(.text+0x3b): undefined reference to `dlclose'
/sandbox/builds/lib/libcrypto.a(dso_dlfcn.o): In function `dlfcn_bind_func':
dso_dlfcn.c:(.text+0x3c1): undefined reference to `dlsym'
dso_dlfcn.c:(.text+0x4a0): undefined reference to `dlerror'
/sandbox/builds/lib/libcrypto.a(dso_dlfcn.o): In function `dlfcn_bind_var':
dso_dlfcn.c:(.text+0x521): undefined reference to `dlsym'
dso_dlfcn.c:(.text+0x600): undefined reference to `dlerror'
/sandbox/builds/lib/libcrypto.a(dso_dlfcn.o): In function `dlfcn_load':
dso_dlfcn.c:(.text+0x678): undefined reference to `dlopen'
dso_dlfcn.c:(.text+0x6e8): undefined reference to `dlclose'
dso_dlfcn.c:(.text+0x72d): undefined reference to `dlerror'
/sandbox/builds/lib/libcrypto.a(dso_dlfcn.o): In function `dlfcn_pathbyaddr':
dso_dlfcn.c:(.text+0x7e1): undefined reference to `dladdr'
dso_dlfcn.c:(.text+0x849): undefined reference to `dlerror'
/sandbox/builds/lib/libcrypto.a(dso_dlfcn.o): In function `dlfcn_unload':
dso_dlfcn.c:(.text+0x8aa): undefined reference to `dlclose'
collect2: error: ld returned 1 exit status
make: *** [git-imap-send] Error 1
______________________________________________________________________
OpenSSL Project                                 http://www.openssl.org
User Support Mailing List                    openssl-users@openssl.org
Automated List Manager                           majord...@openssl.org
______________________________________________________________________
OpenSSL Project                                 http://www.openssl.org
User Support Mailing List                    openssl-users@openssl.org
Automated List Manager                           majord...@openssl.org

Reply via email to