unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
* exec-path and PATH
@ 2011-03-19  3:19 Christoph Scholtes
  2011-03-19  8:10 ` Eli Zaretskii
  0 siblings, 1 reply; 19+ messages in thread
From: Christoph Scholtes @ 2011-03-19  3:19 UTC (permalink / raw)
  To: emacs-devel

I was troubleshooting a problem with Emacs not being able to find
certain external programs on Windows, e.g. grep or find.

I noticed that there seem to be two ways that external programs are
invoked:

1. directly, via start-process
2. indirectly, through the shell

It was a little confusing that it was not enough to add the path to
grep.exe to exec-path for Emacs to find it. The same would work fine for
svn.exe when invoked by the vc backend. 

I add the paths to certain programs in my init.el, e.g. GnuWin32 for
grep. For them to work in every situation I have to remember to add them
to exec-path and the Windows PATH environment variable. This seems
somewhat redundant, no? I would prefer only manipulating the exec-path
to tell Emacs where to find the programs.

Maybe this is a silly question, but why are some of the programs invoked
different than others? 

Christoph

PS: Here is a small docfix patch for process.c for review:

=== modified file 'src/ChangeLog'
--- src/ChangeLog	2011-03-17 19:55:40 +0000
+++ src/ChangeLog	2011-03-19 02:30:14 +0000
@@ -1,3 +1,7 @@
+2011-03-19  Christoph Scholtes  <cschol2112@googlemail.com>
+
+	* process.c (Fstart_process): Doc fix.
+
 2011-03-17  Eli Zaretskii  <eliz@gnu.org>
 
 	* makefile.w32-in ($(BLD)/unexw32.$(O)): Depend on $(SRC)/unexec.h.

=== modified file 'src/process.c'
--- src/process.c	2011-03-17 05:18:33 +0000
+++ src/process.c	2011-03-19 02:26:39 +0000
@@ -1510,7 +1510,7 @@
 function to handle the output.  BUFFER may also be nil, meaning that
 this process is not associated with any buffer.
 
-PROGRAM is the program file name.  It is searched for in PATH.  If
+PROGRAM is the program file name.  It is searched for in EXEC-PATH.  If
 nil, just associate a pty with the buffer.  Remaining arguments are
 strings to give program as arguments.



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

end of thread, other threads:[~2011-03-21 14:04 UTC | newest]

Thread overview: 19+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-03-19  3:19 exec-path and PATH Christoph Scholtes
2011-03-19  8:10 ` Eli Zaretskii
2011-03-19 16:36   ` Christoph Scholtes
2011-03-19 17:26     ` Eli Zaretskii
2011-03-19 19:50       ` Christoph Scholtes
2011-03-19 20:59         ` Eli Zaretskii
2011-03-20 19:45           ` Christoph Scholtes
2011-03-20 20:36             ` Eli Zaretskii
2011-03-20 20:46               ` Eric Hanchrow
2011-03-21 14:04                 ` Eric Schulte
2011-03-20 22:44               ` Wojciech Meyer
2011-03-19 16:49   ` Christoph Scholtes
2011-03-19 17:18     ` PJ Weisberg
2011-03-19 17:23       ` Christoph Scholtes
2011-03-19 18:52       ` Harald Hanche-Olsen
2011-03-20  2:53         ` Stefan Monnier
2011-03-19 17:43     ` Eli Zaretskii
2011-03-20  2:50   ` Stefan Monnier
2011-03-20  6:34     ` Eli Zaretskii

Code repositories for project(s) associated with this public inbox

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

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).