changeset 38532:d00c83b7f2e8

(compile-internal): If EMACS is already defined in the environment, don't override its value.
author Eli Zaretskii <eliz@gnu.org>
date Mon, 23 Jul 2001 15:23:03 +0000
parents 393c8e5512ee
children c056c3bc5b59
files lisp/progmodes/compile.el
diffstat 1 files changed, 5 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/lisp/progmodes/compile.el	Mon Jul 23 14:47:42 2001 +0000
+++ b/lisp/progmodes/compile.el	Mon Jul 23 15:23:03 2001 +0000
@@ -805,7 +805,11 @@
 	    (funcall compilation-process-setup-function))
 	;; Start the compilation.
 	(if (fboundp 'start-process)
-	    (let* ((process-environment (cons "EMACS=t" process-environment))
+	    (let* ((process-environment
+		    ;; Don't override users' setting of $EMACS.
+		    (if (getenv "EMACS")
+			process-environment
+		      (cons "EMACS=t" process-environment)))
 		   (proc (start-process-shell-command (downcase mode-name)
 						      outbuf
 						      command)))