cURL / Mailing Lists / curl-users / Single Mail

curl-users

Build Trouble: "OpenSSL libs and/or directories were not found where specified!"

From: Weston C <westonc_at_gmail.com>
Date: Thu, 29 May 2008 15:59:31 -0700

Hi,

Having a little trouble building on Centos 4.... I can't seem to get
configure to see openssl.

I started with "./configure --with-ssl=/usr/local/ssl", which got me
the following back from configure:

"OpenSSL libs and/or directories were not found where specified!"

I'm definitely a bit puzzled by this -- a quick peek in /usr/local/ssl
shows me what I think ought to be there, including lib/libcrypto.a and
lib/libssl.a, and IIRC, the openssl install instructions notes
/usr/local/ssl is the default/historical install location.

But I poked around the list archives looking to see if someone else
had a similar problem and found this:

http://curl.haxx.se/mail/archive-2007-11/0014.html

which probably does have the solution to my problem, I'm just having
trouble understanding a few parts of it.

I think I follow the recommendations to set PKG_CONFIG_PATH, CFLAGS,
and LDFLAGS, and consequently, here's what my invocation of configure
now looks like:

  PKG_CONFIG_PATH="$PKG_CONFIG_PATH:/usr/local/ssl/lib/pkgconfig" \
  CFLAGS="-I/usr/local/ssl/include" \
  LDFLAGS="-L/usr/local/ssl/lib" \
  ./configure --prefix=/usr/local/curl/ \
    --with-ssl=/usr/local/ssl/ \
    --with-zlib

However, I'm afraid I don't understand this advice:

"linking in -ldl with anything that
is using ssl libs from now on. You'll also need to tell the dynamic linker
where libcryto.so/libssl.so are (ld.so.cache, rpath, LD_*) if linking
dynamically, or make sure the *.a static versions are compiled in statically."

Can someone explain this?

I'm also open to any general advice on understanding/fixing the build
process, or setting up/installing an openssl build in a better way, or
just about anything, really.

Thanks!

Weston
Received on 2008-05-30