From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Mark Tran Newsgroups: gmane.emacs.devel Subject: Re: exec-path question Date: Sat, 26 Feb 2011 01:48:34 -0800 Message-ID: References: NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: multipart/alternative; boundary=20cf303f6496a61cb2049d2c593e X-Trace: dough.gmane.org 1298713746 2022 80.91.229.12 (26 Feb 2011 09:49:06 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Sat, 26 Feb 2011 09:49:06 +0000 (UTC) Cc: Emacs-devel@gnu.org To: Ben Key Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Sat Feb 26 10:49:02 2011 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1PtGlo-0008TD-JD for ged-emacs-devel@m.gmane.org; Sat, 26 Feb 2011 10:49:01 +0100 Original-Received: from localhost ([127.0.0.1]:53615 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1PtGlo-0007n1-0M for ged-emacs-devel@m.gmane.org; Sat, 26 Feb 2011 04:49:00 -0500 Original-Received: from [140.186.70.92] (port=59569 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1PtGle-0007kn-Ok for Emacs-devel@gnu.org; Sat, 26 Feb 2011 04:48:55 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1PtGlT-0008De-6t for Emacs-devel@gnu.org; Sat, 26 Feb 2011 04:48:50 -0500 Original-Received: from mail-gy0-f169.google.com ([209.85.160.169]:33283) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1PtGlS-0008Cs-Vg for Emacs-devel@gnu.org; Sat, 26 Feb 2011 04:48:39 -0500 Original-Received: by gyb13 with SMTP id 13so1278253gyb.0 for ; Sat, 26 Feb 2011 01:48:37 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:in-reply-to:references:date :message-id:subject:from:to:cc:content-type; bh=cHzG9Sq4dx1l+xN9fVQV3V4KWZw2f4bm6KoTmWAAdJ4=; b=lBd0aeZrI7j7gNveDwaYVWCbVErjYzyd+MMMYRixn4fGkRd/J9kv8VlUrNBPvFqtmn vfyLTzNUtiV6lRk1JHuMHezlcRO1N5uACss5bmLzH8UERBrcp8hES6oeyYCMNnK3rrOk NCpLI/CSVeGAanpX0jlXbUj2wv1Ime8MiLnc0= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type; b=C956dzHhRTwnUIDhiXn0C65iOSKnsgElm2FO6yAOkI+J9sbJY+nXYnOf7PI4rZnwp/ LBbTPRzbWFhVU2krc30bIlXMYivx9qSdPhLFRfZt/RByJTDmjA8Dauif22RNouVaTu3d Fr4q5O994DrGPGorUw3TxhCXUDFswpeUncZc0= Original-Received: by 10.236.191.71 with SMTP id f47mr122681yhn.36.1298713715022; Sat, 26 Feb 2011 01:48:35 -0800 (PST) Original-Received: by 10.147.113.13 with HTTP; Sat, 26 Feb 2011 01:48:34 -0800 (PST) In-Reply-To: X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 2) X-Received-From: 209.85.160.169 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:136552 Archived-At: --20cf303f6496a61cb2049d2c593e Content-Type: text/plain; charset=ISO-8859-1 Applications in OS X are not launched by your shell and therefore do not inherit it's environment variables. They're started through launchd. If you want Emacs.app to inherit environment variables then you can set user session environment variables in ~/.MacOSX/environment.plist. More information at: http://developer.apple.com/library/mac/#documentation/MacOSX/Conceptual/BPRuntimeConfig/Articles/EnvironmentVars.html http://www.emacswiki.org/emacs/MacOSTweaks#toc13 On Fri, Feb 25, 2011 at 7:51 PM, Ben Key wrote: > Hello, > > I have a question about the exec-path variable. I am using the Nextstep > build of Emacs on Mac OS X 10.6.6. In both Emacs 23.2 and Emacs 24.0, the > "/usr/local/bin" directory is not included in the list, even though it is > included in my PATH environment variable. In Emacs 23.2, the exec-path > variable has the value ("/usr/bin" "/bin" "/usr/sbin" "/sbin" > "/Applications/Emacs.app/Contents/MacOS/bin"). In Emacs 24, the exec-path > variable has the value ("/usr/bin" "/bin" "/usr/sbin" "/sbin" > "/Applications/Emacs24.app/Contents/MacOS/bin"). In Emacs 24 the following > additional information is provided. > > Original value was ("/usr/bin" "/bin" "/usr/sbin" "/sbin" "/usr/local/bin" > "/usr/X11/bin" "/Users/bkey/src/emacs/trunk/lib-src" > "/Users/bkey/src/emacs/trunk/nextstep/Emacs.app/Contents/MacOS//libexec/emacs/24.0.50/x86_64-apple-darwin10.6.0") > > It looks like, at least in Emacs 24, the "/usr/local/bin" directory is > initially included in the exec-path but is latter removed for some reason. > > In both versions of Emacs, the "/usr/local/bin" directory is included in > the path if I run Emacs from the command line using the full path to the > Emacs executable. It is also included in the path if am debugging Emacs > using GDB so I at a loss as to how best to discover the cause of the > problem. I only get the problem if I start Emacs using the icon in the > Applications menu, which is my preferred method of starting Emacs. > > I need the "/usr/local/bin" directory to be included in my exec-path > because I wish to use the ispell function and my hunspell executable is > located there. I know I can simply modify my .emacs file to add the > "/usr/local/bin" directory to the exec-path, but I should not have to do > that. Emacs should not be removing this directory from the exec-path. > > Does anyone have any idea how I should go about tracking down the cause of > this problem? > > --20cf303f6496a61cb2049d2c593e Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Applications in OS X are not launched by your shell and therefore do not in= herit it's environment variables. They're started through launchd.<= div>
If you want Emacs.app to inherit environment variables t= hen you can set user session environment variables in ~/.MacOSX/environment= .plist.

More information at:


On Fri, Feb 25, 2011 at 7:51 PM, Ben Key <bkey76@gmail.com> wr= ote:
Hello,

I have a que= stion about the exec-path variable.=A0 I am using the Nextstep build of Ema= cs on Mac OS X 10.6.6.=A0 In both Emacs 23.2 and Emacs 24.0, the "/usr= /local/bin" directory is not included in the list, even though it is i= ncluded in my PATH environment variable.=A0 In Emacs 23.2, the exec-path va= riable has the value ("/usr/bin" "/bin" "/usr/sbin= " "/sbin" "/Applications/Emacs.app/Contents/MacOS/bin&q= uot;).=A0 In Emacs 24, the exec-path variable has the value ("/usr/bin= " "/bin" "/usr/sbin" "/sbin" "/Appl= ications/Emacs24.app/Contents/MacOS/bin").=A0 In Emacs 24 the followin= g additional information is provided.

Original value = was ("/usr/bin" "/bin" "/usr/sbin" "/sbi= n" "/usr/local/bin" "/usr/X11/bin" "/Users/bk= ey/src/emacs/trunk/lib-src" "/Users/bkey/src/emacs/trunk/nextstep= /Emacs.app/Contents/MacOS//libexec/emacs/24.0.50/x86_64-apple-darwin10.6.0&= quot;)

It looks like, at least in Emacs 24, the
= "/usr/local/bin" directory is initially included= in the exec-path but is latter removed for some reason.

In both versions of Emacs, the=A0 "/usr/local/bin" directory is i= ncluded in the path if I run Emacs from the command line using the full pat= h to the Emacs executable.=A0 It is also included in the path if am debuggi= ng Emacs using GDB so I at a loss as to how best to discover the cause of t= he problem.=A0 I only get the problem if I start Emacs using the icon in th= e Applications menu, which is my preferred method of starting Emacs.

I need the "/usr/local/bin" directory to be included in my ex= ec-path because I wish to use the ispell function and my hunspell executabl= e is located there.=A0 I know I can simply modify my .emacs file to add the= "/usr/local/bin" directory to the exec-path, but I should not ha= ve to do that.=A0 Emacs should not be removing this directory from the exec= -path.

Does anyone have any idea how I should go about tracking down the cause= of this problem?


--20cf303f6496a61cb2049d2c593e--