Beefy Boxes and Bandwidth Generously Provided by pair Networks
Keep It Simple, Stupid
 
PerlMonks  

Re: Link Net::SSLeay to custom-built OpenSSL

by Anonyrnous Monk (Hermit)
on Feb 04, 2011 at 16:42 UTC ( [id://886248]=note: print w/replies, xml ) Need Help??


in reply to Link Net::SSLeay to custom-built OpenSSL

LD_RUN_PATH="/dsk01/apache/app/build2064/openssl-0.9.8p/lib:/usr/lib" +...

You might want to check:

(a) if your libssl.so does in fact live in the above RUNPATH .../openssl-0.9.8p/lib,  and (b) if that path is actually being written to SSLeay.so. Check RUNPATH/RPATH settings with

$ dump -Lv .../SSLeay.so

The theory is that the linker (ld) puts the lib search path(s) into the .so (or binary), and the dynamic linker (ld.so.1) then picks it up from there...

(See also LD_RUN_PATH, and the option -R, in the ld man page.)

Replies are listed 'Best First'.
Re^2: Link Net::SSLeay to custom-built OpenSSL
by RachunZero (Novice) on Feb 04, 2011 at 17:49 UTC

    Oh. That's it. Thanks!

    I forgot that the gcc packaged in Solaris 10 doesn't do runpaths properly using the environment variable. It's only got /usr/sfw/lib showing in the runpath header.

    If I want a proper runpath, I have to explicitly pass it in -R parameters to gcc.

    Hmmm... I wonder what I do now. Can I change the gcc options? Makefile.PL seems to ignore LDFLAGS.

      Can I change the gcc options? Makefile.PL seems to ignore LDFLAGS.

      IIRC, you can say

      dynamic_lib => { OTHERLDFLAGS => '-R...' }

      (untested)

        Thanks again :-) My lazy secular nature made me do:
        mv Makefile Makefile.tmp nawk -v d=$OPENSSL_DIR ' /OTHERLDFLAGS =/ { print $0" -R "d"/lib" } ! +/OTHERLDFLAGS =/ { print $0 }' Makefile.tmp > Makefile

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://886248]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others rifling through the Monastery: (2)
As of 2025-02-08 03:37 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    Which URL do you most often use to access this site?












    Results (95 votes). Check out past polls.