Re: How to configure the search path of a run-script build phase?
Re: How to configure the search path of a run-script build phase?
- Subject: Re: How to configure the search path of a run-script build phase?
- From: Matt Neuburg <email@hidden>
- Date: Wed, 27 Jul 2011 07:41:38 -0700
On Mon, 25 Jul 2011 12:08:00 -0700, Jens Alfke <email@hidden> said:
>I need an Xcode 4 Run Script build phase to invoke a nonstandard tool (erlc). Ive installed the tool through Homebrew, so its in /usr/local/bin; but other people might have used MacPorts, in which case itd be in /opt, so I dont want to hard-code the path. But neither of those directories is in the standard $PATH, so the script cant find it if I dont tell it the full path.
>
>The root of the problem seems to be that scripts invoked by Xcode dont read any of the usual shell configuration files (.profile, .bash_profile, .cshrc), so I dont have an opportunity to customize their search paths. Is there any other way I can tell Xcode to customize $PATH on a per-user basis?
In a different but parallel situation, what I do is instruct the user to store the needed information in the defaults (using the command-line "defaults" command and a custom domain, e.g. "com.neuburg.matt.mySpecialInfo". My script can then find the information there, or supply a default default if nothing is specified. (Actually, I also supply interface to help the user store the info in the defaults; but you're probably dealing with technical people who won't have any difficulty with command line.) m.
--
matt neuburg, phd = email@hidden, <http://www.apeth.net/matt/>
A fool + a tool + an autorelease pool = cool!
Programming iOS 4!
http://www.apeth.net/matt/default.html#iosbook _______________________________________________
Do not post admin requests to the list. They will be ignored.
Xcode-users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden