LD_LIBRARY_PATH root question

Hi All,

I use fedora 9-13.
I’ve setup the USERNAME/.bashrc to point at python and other shared
libraries, all works fine as USERNAME.

My question is: If I login as USERNAME, then in terminal su root and
start a GR py it will fail due to it can’t find some libraries (boost).
I must always do an export first

Where do I declare LD_LIBRARY_PATH properly for root (or any user)
access at startup?
At the moment I’ve declared paths in /root/.bash_profile, but when
rebooted it complains and an export is needed to shared library path:s
inorder to run GR

Patrik

On Fri, Jan 28, 2011 at 8:41 AM, Patrik T. [email protected]
wrote:

Where do I declare LD_LIBRARY_PATH properly for root (or any user) accessat
startup?
At the moment I’ve declared paths in /root/.bash_profile, but when rebooted
it complains and an export is needed to shared library path:s inorder to run
GR

Patrik

If you have to su, you can pass it the -p (or -m) flag and that will
preserve your environment (see man su; there’s a restriction on PATH
when doing this).

You should also be able to edit /etc/bash.bashrc (might be different
in Fedora, but something similar should be there) to make common
environments shared among all users.

Tom

Aha, thanks!

Lots to learn…

Patrik

----- Original Message -----
From: “Tom R.” [email protected]
To: “Patrik T.” [email protected]; “GNURadio D.ion List”
[email protected]
Sent: Saturday, January 29, 2011 17:28
Subject: Re: [Discuss-gnuradio] LD_LIBRARY_PATH root question

On Fri, Jan 28, 2011 at 8:41 AM, Patrik T. [email protected]
wrote:

Where do I declare LD_LIBRARY_PATH properly for root (or any user) access
at
startup?
At the moment I’ve declared paths in /root/.bash_profile, but when
rebooted
it complains and an export is needed to shared library path:s inorder to
run
GR

Patrik

If you have to su, you can pass it the -p (or -m) flag and that will
preserve your environment (see man su; there’s a restriction on PATH
when doing this).

You should also be able to edit /etc/bash.bashrc (might be different
in Fedora, but something similar should be there) to make common
environments shared among all users.

Tom

This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs