in reply to Env Variables
In case the environment variables in question involve LD_LIBRARY_PATH, and in case you're using Apache, see SetEnv/PassEnv.
LD_LIBRARY_PATH is special in that (on some operating systems like Solaris1) it needs to be set before the process is started that would need it for dynamic linking (this is because the runtime linker caches the search paths on exec). That means that simply changing the environment from within the script itself may not work.
In case you do want to set it from within the script (as opposed to having the webserver set it, as suggested above), you'll need to re-exec the script after having changed the environment. This has been discussed a few times here, so you should be able to find related sample code. Update: see PATH is not setting - PERL, for example.
___
1 as you mentioned crle, I figured you might be on Solaris
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: Env Variables
by LinuxUser2008 (Acolyte) on Jun 10, 2010 at 17:04 UTC | |
by almut (Canon) on Jun 10, 2010 at 17:15 UTC | |
by LinuxUser2008 (Acolyte) on Jun 10, 2010 at 17:29 UTC | |
by almut (Canon) on Jun 10, 2010 at 17:39 UTC | |
by LinuxUser2008 (Acolyte) on Jun 10, 2010 at 18:15 UTC | |
by LinuxUser2008 (Acolyte) on Jun 10, 2010 at 18:16 UTC |