Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.python > #108541

Re: Finding .so files without setting LD_LIBRARY_PATH

From dieter <dieter@handshake.de>
Newsgroups comp.lang.python
Subject Re: Finding .so files without setting LD_LIBRARY_PATH
Date 2016-05-12 09:08 +0200
Message-ID <mailman.603.1463036926.32212.python-list@python.org> (permalink)
References <1463002764.2579.26.camel@mad-scientist.net> <874ma3u51o.fsf@handshake.de>

Show all headers | View raw


Paul Smith <paul@mad-scientist.net> writes:
> ...
> That works fine, but here's the problem: because LD_LIBRARY_PATH is in
> Python's environment it is also passed down to programs invoked by
> Python.  That means if I (for example) invoke subprocess.call(['ssh',
> ...]) then it fails because the system ssh is looking for the system
> libcrypto.so, and when it finds the Python libcrypto.so instead
> (because of LD_LIBRARY_PATH) it fails.

I have had a similar problem - however with "PYTHONPATH" instead
of "LD_LIBRARY_PATH". I solved it by removing "PYTHONPATH" from
"os.environ" during Python startup. This way, the envvar
"PYTHONPATH" was effective to set up "sys.path" but
processes started from this python would not see it.

Back to comp.lang.python | Previous | Next | Find similar | Unroll thread


Thread

Re: Finding .so files without setting LD_LIBRARY_PATH dieter <dieter@handshake.de> - 2016-05-12 09:08 +0200

csiph-web