[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Acrobat 7.0 for linux is out



Once upon a time Roberto C. Sanchez said...
> >On Wed, Mar 16, 2005 at 05:37:56PM -0500, Roberto C. Sanchez wrote:
> >
> >>The question is, how do I get /opt/bin into the default PATH?  It would
> >>appear that as long as I run moz from an xterm (where the PATH is set
> >>by /etc/profile), it works.  If I run it from the Menu, it doesn't work.
> >>I am wondering if maybe X or gdm ignore the ENV_PATH specification.
> >
> 
> The problem is that if I launch *Firefox* from the menu, then the
> acroread *plugin* does not function.  The solution I need is to get
> the system to understand that I *really* want /opt/bin in the default
> search PATH.

It's somewhat complicated because [xgk]dm do not source your .profile,
so the environment will not be set up until you run a shell, and then
only for that shell and all child processes.

What I do is have my .profile set up the environment. Everything in here
must be bourne shell compatible. In my .bashrc I set up bash specific,
non-inheriting stuff (shell functions, aliases, bash options, etc) and
then from my .bash_profile, I souce .profile and .bashrc.

To hook into the xsession startup, I have created a file called
/etc/X11/Xsession.d/75local-profile that contains:

---------------
#
# Source a users .profile, etc
#
PROFILES="/etc/profile $HOME/.profile /etc/xprofile $HOME/.xprofile"

for PROFILE in $PROFILES ; do
  [ -f "$PROFILE" ] && . "$PROFILE"
done
---------------

This will end up loading the environment before the desktop is started,
so the desktop and all child processes will have then environment the
way I want it.

[I put .xprofile in there in case I wanted to set up anything specific
to X but not for a console login]

It's necessary to do your environment setup in a bourne shell compatible
format (.profile) because the xsession scripts run under the bourne
shell, not your user shell (most likely bash).




Reply to: