tru64-unix-managers (formerly alpha-osf-managers) (1994-2012)
 help / color / mirror / Atom feed
From: "Eiler, James A." <James.Eiler () alcoa ! com>
To: tru64-unix-managers
Subject: SUMMARY: Saving the Environment (variables)
Date: Thu, 15 Jul 1999 22:34:23 +0000	[thread overview]
Message-ID: <96079058315888.tru64-unix-managers.marc@archive.invalid> (raw)

ORIGINAL MESSAGE:

I'm using the environment variable LD_LIBRARY_PATH to specify where some of
my shared object modules reside (.so) for my C and FORTRAN processes.
Everything works fine until I "su" to root.  

Although I've done an export on LD_LIBRARY_PATH, it (and several other
environment variables) don't make it when I become root.  I believe this
"feature" has something to do with security, or is some mechanism to keep me
from blowing off my foot.  But, I really need LD_LIBRARY_PATH to be set
properly.

Any ideas?

ANSWER(S):

I used the following suggestion from Frank Wortner::

You could try rebuilding your C and FORTRAN shared objects (".so") files and
specifying the "-soname" option.  When you link your executable,  the full
pathname for the ".so" file will be recorded in the executable,  and you
won't need to set LD_LIBRARY_PATH at all.

	ld -shared -soname /some/path/name.so obj.o -o name.so

BTW,  you're right:  ignoring and/or not propagating LD_LIBRARY_PATH through
su is a security feature.


Thanks also to:

Dale Inman
Piotr Bienias
Alethia Dunn

                 reply	other threads:[~1999-07-15 22:34 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed
read-only archive

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox