Xref: utzoo comp.emacs:5945 gnu.emacs:802 Path: utzoo!attcan!uunet!brunix!doorknob!mnp From: mnp@cs.brown.edu Newsgroups: comp.emacs,gnu.emacs Subject: Re: putenv (was Re: exec-path and process-environment in gnu-18.53) Message-ID: Date: 28 Apr 89 01:10:59 GMT References: <39147@bbn.COM> <4348@omepd.UUCP> Sender: news@brunix.UUCP Organization: Brown University Department of Computer Science Lines: 57 In-reply-to: merlyn@intelob.intel.com's message of 27 Apr 89 18:02:43 GMT In article <4348@omepd.UUCP> merlyn@intelob.intel.com (Randal L. Schwartz @ Stonehenge) writes: From: merlyn@intelob.intel.com (Randal L. Schwartz @ Stonehenge) Newsgroups: comp.emacs,gnu.emacs Date: 27 Apr 89 18:02:43 GMT Reply-To: merlyn@intelob.intel.com (Randal L. Schwartz @ Stonehenge) Organization: Stonehenge; netaccess via BiiN, Hillsboro, Oregon, USA In article <39147@bbn.COM>, jr@bbn (John Robinson) writes: | In article , mlm@doorknob writes: | >Elisp Gurus, | >I am using gnuemacs distribution 18.53, and i need to change the PATH | >used when emacs spawns subprocesses. | | Generally, there are two answers. | | 1. Compile emacs with the MAINTAIN_ENVIRONMENT variable set. This | will bring in a function (setenv) like (getenv) for you to use from | elisp. And, if you don't have MAINTAIN_ENVIRONMENT turned on, you can use this code: ... [ elisp code removed ] Merlyn, Thanks very much for the effort, but that doesn't work. Perhaps it is because i do not have MAINTAIN_ENVIRONMENT defined, but i had written a routine just like the one you posted before i posted my original article. Change process-environment by hand does not help. All subshells started after the process-environment variable is set DO NOT reflect the changed environment. To see this do: M-x edit-options Change process-environment to whatever you like, M-x shell shell prompt -> printenv the environment printed out in the subshell is entirely wrong. looks like a bug in gnuemacs dist-18.53. Please tell me i'm wrong. -matt p.s. in the meantime i have found a hack/fix. i changed a local version of the compile library to invoke the 'env' program distributed with gnuemacs dist-18.53. so i say: M-x compile Compile command: make install and my hacked compile.el invokes the compilation as: env PATH=whatever make install _________________________________________________________________________ { decvax,ihnp4,allegra,uunet }! brunix ! mnp Matthew Nicholas Pappas or mnp @ {cs.brown.edu, browncs.bitnet } Brown University