all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* NT Emacs and Cygwin
@ 2004-11-28 15:54 Elvin Peterson
  2004-11-28 20:02 ` Eli Zaretskii
       [not found] ` <mailman.2030.1101672934.27204.help-gnu-emacs@gnu.org>
  0 siblings, 2 replies; 6+ messages in thread
From: Elvin Peterson @ 2004-11-28 15:54 UTC (permalink / raw)


Hello,
	I am using

(setenv "PATH" (concat (getenv "PATH") ";C:\\cygwin\\bin"))

to add cygwin's path, but emacs cannot find the executables.  I have 
workarounds for modes which have an option for specifying programs, but 
it doesn't work in general.  How can I make the above work?  Any help is 
appreciated.
TIA.

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: NT Emacs and Cygwin
  2004-11-28 15:54 NT Emacs and Cygwin Elvin Peterson
@ 2004-11-28 20:02 ` Eli Zaretskii
       [not found] ` <mailman.2030.1101672934.27204.help-gnu-emacs@gnu.org>
  1 sibling, 0 replies; 6+ messages in thread
From: Eli Zaretskii @ 2004-11-28 20:02 UTC (permalink / raw)


> From: Elvin Peterson <elvin_peterson@yahoo.com>
> Date: Sun, 28 Nov 2004 21:24:44 +0530
> 
> 	I am using
> 
> (setenv "PATH" (concat (getenv "PATH") ";C:\\cygwin\\bin"))
> 
> to add cygwin's path, but emacs cannot find the executables.

setenv modifies the environment that Emacs passes to its subprocesses,
but doesn't affect the environment Emacs itself uses.  Thus, the value
of PATH seen by Emacs will not change after the above.

You need to modify PATH outside of Emacs, and before Emacs is invoked,
to get what you want.

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: NT Emacs and Cygwin
       [not found] ` <mailman.2030.1101672934.27204.help-gnu-emacs@gnu.org>
@ 2004-11-28 20:15   ` David Kastrup
  2004-11-29  4:41     ` Eli Zaretskii
       [not found]     ` <mailman.2088.1101704044.27204.help-gnu-emacs@gnu.org>
  0 siblings, 2 replies; 6+ messages in thread
From: David Kastrup @ 2004-11-28 20:15 UTC (permalink / raw)


"Eli Zaretskii" <eliz@gnu.org> writes:

>> From: Elvin Peterson <elvin_peterson@yahoo.com>
>> Date: Sun, 28 Nov 2004 21:24:44 +0530
>> 
>> 	I am using
>> 
>> (setenv "PATH" (concat (getenv "PATH") ";C:\\cygwin\\bin"))
>> 
>> to add cygwin's path, but emacs cannot find the executables.
>
> setenv modifies the environment that Emacs passes to its subprocesses,
> but doesn't affect the environment Emacs itself uses.  Thus, the value
> of PATH seen by Emacs will not change after the above.
>
> You need to modify PATH outside of Emacs, and before Emacs is invoked,
> to get what you want.

Not necessarily.

exec-path's value is 
("/usr/kerberos/bin" "/usr/local/bin" "/usr/bin" "/bin" "/usr/X11R6/bin" "/home/dak/bin" "/usr/local/emacs-21/libexec/emacs/21.3.50/i686-pc-linux-gnu")


*List of directories to search programs to run in subprocesses.
Each element is a string (directory name) or nil (try default directory).

You can customize this variable.

Defined in `C source code'.


-- 
David Kastrup, Kriemhildstr. 15, 44793 Bochum

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: NT Emacs and Cygwin
  2004-11-28 20:15   ` David Kastrup
@ 2004-11-29  4:41     ` Eli Zaretskii
       [not found]     ` <mailman.2088.1101704044.27204.help-gnu-emacs@gnu.org>
  1 sibling, 0 replies; 6+ messages in thread
From: Eli Zaretskii @ 2004-11-29  4:41 UTC (permalink / raw)


> From: David Kastrup <dak@gnu.org>
> Date: Sun, 28 Nov 2004 21:15:39 +0100
> 
> > You need to modify PATH outside of Emacs, and before Emacs is invoked,
> > to get what you want.
> 
> Not necessarily.
> 
> exec-path's value is 
> ("/usr/kerberos/bin" "/usr/local/bin" "/usr/bin" "/bin" "/usr/X11R6/bin" "/home/dak/bin" "/usr/local/emacs-21/libexec/emacs/21.3.50/i686-pc-linux-gnu")

IIRC, exec-path is effective only for programs for which Emacs
actively looks for the program's executable.  Examples include
programs that are part of the Emacs distribution, like hexl.  I
assumed the OP was complaining about commands like M-!, for which
Emacs does not look for the executable, but lets the OS find them.

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: NT Emacs and Cygwin
       [not found]     ` <mailman.2088.1101704044.27204.help-gnu-emacs@gnu.org>
@ 2004-11-29 10:38       ` Håkon Alstadheim
  2004-11-29 18:27         ` Elvin Peterson
  0 siblings, 1 reply; 6+ messages in thread
From: Håkon Alstadheim @ 2004-11-29 10:38 UTC (permalink / raw)


"Eli Zaretskii" <eliz@gnu.org> writes:

>> From: David Kastrup <dak@gnu.org>
>> Date: Sun, 28 Nov 2004 21:15:39 +0100
>> 
>> > You need to modify PATH outside of Emacs, and before Emacs is invoked,
>> > to get what you want.
>> 
>> Not necessarily.
>> 
>> exec-path's value is 
>> ("/usr/kerberos/bin" "/usr/local/bin" "/usr/bin" "/bin" "/usr/X11R6/bin" "/home/dak/bin" "/usr/local/emacs-21/libexec/emacs/21.3.50/i686-pc-linux-gnu")
>
> IIRC, exec-path is effective only for programs for which Emacs
> actively looks for the program's executable.  Examples include
> programs that are part of the Emacs distribution, like hexl.  I
> assumed the OP was complaining about commands like M-!, for which
> Emacs does not look for the executable, but lets the OS find them.

In which case the SETENV should work, since sub-shells will be
affected by the SETENV call.

M-x grep, M-x find-* would (I guess) benefit from having exec-path
adjusted.

-- 
Håkon Alstadheim, hjemmepappa.

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: NT Emacs and Cygwin
  2004-11-29 10:38       ` Håkon Alstadheim
@ 2004-11-29 18:27         ` Elvin Peterson
  0 siblings, 0 replies; 6+ messages in thread
From: Elvin Peterson @ 2004-11-29 18:27 UTC (permalink / raw)


Håkon Alstadheim wrote:
> "Eli Zaretskii" <eliz@gnu.org> writes:
> 
> 
>>>From: David Kastrup <dak@gnu.org>
>>>Date: Sun, 28 Nov 2004 21:15:39 +0100
>>>
>>>
>>>>You need to modify PATH outside of Emacs, and before Emacs is invoked,
>>>>to get what you want.
>>>
>>>Not necessarily.
>>>
>>>exec-path's value is 
>>>("/usr/kerberos/bin" "/usr/local/bin" "/usr/bin" "/bin" "/usr/X11R6/bin" "/home/dak/bin" "/usr/local/emacs-21/libexec/emacs/21.3.50/i686-pc-linux-gnu")
>>
>>IIRC, exec-path is effective only for programs for which Emacs
>>actively looks for the program's executable.  Examples include
>>programs that are part of the Emacs distribution, like hexl.  I
>>assumed the OP was complaining about commands like M-!, for which
>>Emacs does not look for the executable, but lets the OS find them.
> 
> 
> In which case the SETENV should work, since sub-shells will be
> affected by the SETENV call.
> 
> M-x grep, M-x find-* would (I guess) benefit from having exec-path
> adjusted.
> 

Exactly--since emacs spawns a new cmd shell, it should pass the new PATH 
value along.  However, I find that many OS specific functions are simply 
not implemented in Windows for Emacs.  (ref my post earlier about the 
allowable characters in a filename not being implemented.)

Thanks to all who replied.

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2004-11-29 18:27 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2004-11-28 15:54 NT Emacs and Cygwin Elvin Peterson
2004-11-28 20:02 ` Eli Zaretskii
     [not found] ` <mailman.2030.1101672934.27204.help-gnu-emacs@gnu.org>
2004-11-28 20:15   ` David Kastrup
2004-11-29  4:41     ` Eli Zaretskii
     [not found]     ` <mailman.2088.1101704044.27204.help-gnu-emacs@gnu.org>
2004-11-29 10:38       ` Håkon Alstadheim
2004-11-29 18:27         ` Elvin Peterson

Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.