From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Ivan Andrus Newsgroups: gmane.emacs.devel Subject: Re: Inferior process mystery Date: Wed, 25 Apr 2012 21:15:47 +0200 Message-ID: <6626E25F-B780-4773-AEAA-D9451BC0E9ED@gmail.com> References: NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 (Apple Message framework v1084) Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: quoted-printable X-Trace: dough.gmane.org 1335381368 8261 80.91.229.3 (25 Apr 2012 19:16:08 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Wed, 25 Apr 2012 19:16:08 +0000 (UTC) Cc: Emacs Dev To: Andreas Schwab Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Wed Apr 25 21:16:06 2012 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1SN7h1-00025U-Mf for ged-emacs-devel@m.gmane.org; Wed, 25 Apr 2012 21:15:59 +0200 Original-Received: from localhost ([::1]:35818 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SN7h0-00087P-SH for ged-emacs-devel@m.gmane.org; Wed, 25 Apr 2012 15:15:58 -0400 Original-Received: from eggs.gnu.org ([208.118.235.92]:42301) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SN7gy-00087F-Bm for emacs-devel@gnu.org; Wed, 25 Apr 2012 15:15:57 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1SN7gw-0004QN-3a for emacs-devel@gnu.org; Wed, 25 Apr 2012 15:15:55 -0400 Original-Received: from mail-bk0-f41.google.com ([209.85.214.41]:51230) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SN7gv-0004P9-QT for emacs-devel@gnu.org; Wed, 25 Apr 2012 15:15:54 -0400 Original-Received: by bkvi17 with SMTP id i17so463965bkv.0 for ; Wed, 25 Apr 2012 12:15:51 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=subject:mime-version:content-type:from:in-reply-to:date:cc :content-transfer-encoding:message-id:references:to:x-mailer; bh=pGdnLBcHhYoDFFUPtohyXmvlSKq2IsGs6EY6K96DNz8=; b=M4lJGHJNnp9STyMYrnJKrNqr8dG3tEQ3egcZ0adKihhTgkNvQA9mpLN+XO9ZDhDSH3 z6QA4DAsIHftu4Y/4Y5L5IjPkMGsj051MQVy/mW97U0AuixR7ApOFycS7IlT+FrnLsjJ TVW2aTe4+zLgBVLiMesb5GThBplq+3UFtfTBgcF+2PtX237Lzx77vlkyxYd8ibgxZ64s cDEJBkP+CjsRfGEAditA1a8+Y75kbh4vRwKoFakIrGPQUWUV1O7ICB90ELIbVzPEhyy+ LOphbDmbs3Jl1svONq+/6BfjiAkjRTDTqgUT20eNX89FBjpt1rK3faDUWep3AK5ZZB0b D1vA== Original-Received: by 10.205.122.69 with SMTP id gf5mr1272545bkc.66.1335381350973; Wed, 25 Apr 2012 12:15:50 -0700 (PDT) Original-Received: from [10.0.2.16] (catv-80-99-177-93.catv.broadband.hu. [80.99.177.93]) by mx.google.com with ESMTPS id s16sm1057586bkt.3.2012.04.25.12.15.49 (version=SSLv3 cipher=OTHER); Wed, 25 Apr 2012 12:15:49 -0700 (PDT) In-Reply-To: X-Mailer: Apple Mail (2.1084) X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 209.85.214.41 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:150026 Archived-At: On Apr 25, 2012, at 8:02 PM, Andreas Schwab wrote: > Dave Abrahams writes: >=20 >> Yep, that is in fact the problem. But how do I discover what is = changing my exec-path? >=20 > exec-path is initialized from $PATH as inherited by emacs, which = appears > to be different from the one set in your shell. Since you're on a Mac, GUI applications don't inherit from your shell. = Instead you should set environment variables in = ~/.MacOSX/environment.plist, or see [1] for a number of other ways to = set them and the different problems they have. There are various ways to "fix" this automatically. The method I use is = to update environment.plist if .bashrc is newer [2]. Other methods = include setting exec-path by calling a shell-script which will inherit = your .bashrc setting. This is a huge source of confusion and questions in places like = StackOverflow. I've been trying to think of a good way to bring this to = people's attention without being obnoxious. One idea is when, for = example, a compilation buffer get's a command not found error, create an = overlay (only on OS X (or perhaps not since it can happen in other = desktop environments as well)) which explains the problem. It wouldn't = always apply of course, but it might save people some headaches. I'm = not sure if that sort of thing would be acceptable for inclusion in = Emacs, but I think it would only be useful if it were on by default. -Ivan [1] = http://stackoverflow.com/questions/135688/setting-environment-variables-in= -os-x [2] http://use.perl.org/~brian_d_foy/journal/8915=