octave-maintainers
[Top][All Lists]
Advanced

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

Re: R: EXEC_PATH


From: Ben Abbott
Subject: Re: R: EXEC_PATH
Date: Thu, 25 Nov 2010 15:35:49 -0500

On Nov 25, 2010, at 3:03 PM, Marco Atzeri wrote:

> --- Gio 25/11/10, John W. Eaton <address@hidden> ha scritto:
> 
>> Currently that is done by
>> 
>>   1. storing the value of PATH when Octave starts
>> 
>>   2. setting PATH in the environment to the original
>> PATH + EXEC_PATH
>>      when EXEC_PATH is initialized or
>> any time EXEC_PATH changes
>> 
>> I added the following note in the set_exec_path function
>> in
>> src/defaults.cc:
>> 
>>   // FIXME -- should we really be modifying PATH in
>> the environment?
>>   // The way things are now, Octave will ignore
>> directories set in the
>>   // PATH with calls like
>>   //
>>   //   setenv ("PATH", "/my/path");
>>   //
>>   // To fix this, I think Octave should be searching
>> the combination of
>>   // PATH and EXEC_PATH for programs that it executes
>> instead of setting
>>   // the PATH in the environment and relying on the
>> shell to do the
>>   // searching.
>> 
>> so I'm considering this change as well, so that changes to
>> PATH while
>> Octave is running will not be ignored when executing
>> programs.  I
>> think the current behavior might be confusing. 
>> However, it has always
>> been this way and I don't recall complaints (though
>> previously, the
>> extra directories were prepended to PATH).  The recent
>> changes were
>> in response to bug report #31695.  Oops, I see there
>> was no ChangeLog
>> entry for this change.  I will fix that.
>> 
>> BTW, how did you notice this, and in what way did it cause
>> a problem
>> for you?
>> 
> 
> print("prova.jpg", "-djpg")
> 
> it complains that ghostscript and other programs are not in 
> EXEC_PATH.
> 
> gs is on /usr/bin that is missing from EXEC_PATH
> 

Does 'system ("which gs")'  return "/usr/bin/gs"?

Ben




reply via email to

[Prev in Thread] Current Thread [Next in Thread]