how to build with --enable-shared so that binary knows wherelibraries are.

D

d d

The following is on Linux.

I'd like to build python with ./configure --enable-shared. And
install in a non-standard place (an nfs-mounted directory).

However, the binary is then not usable, since it can't find the
library. I can fix this by defining LD_LIBRARY_PATH, but I don't want
to do that. Doing anything system-specific is impractical, since many
systems will point to this directory (LD_LIBRARY_PATH is feasible,
though undesired, because it can be set in a common script that users
call from their .cshrc files.)

Is there a way to configure the build such that the binary will know
where the shared library is?

I found this:
http://koansys.com/tech/building-python-with-enable-shared-in-non-standard-location
It recommends LDFLAGS="-rpath <path to lib>", and mentions that you
get a "compiler cannot create executables" error unless you first
create the empty directory. But I get that error even when I do
create the empty directory.

Any help would be appreciated.

--Dan
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,995
Messages
2,570,236
Members
46,821
Latest member
AleidaSchi

Latest Threads

Top