Macports stopped working after xcode 4.6 upgrade

Harald Hanche-Olsen hanche at math.ntnu.no
Wed Feb 20 01:09:07 PST 2013


[Lawrence Velázquez <larryv at macports.org> (2013-02-20 08:47:13 UTC)]

> On Feb 20, 2013, at 3:22 AM, Harald Hanche-Olsen <hanche at math.ntnu.no> wrote:
> 
> > ["Richard R. Cahilig" <chr05210084 at gmail.com> (2013-02-19 22:39:32 UTC)]
> > 
> >> export PATH="/opt/local/bin:/opt/local/sbin:$PATH"
> > 
> > Another way to do that is to put this in a file in /etc/paths.d/:
> > 
> > /opt/local/bin
> > /opt/local/sbin
> 
> These are not equivalent. Directory entries added via /etc/paths.d are tacked onto the *end* of the default PATH, while the quoted "export" statement adds them to the *beginning*. The latter is necessary if you want your shell to find MacPorts executables before system ones.

True. If that is what you want, you can tack the directories onto the front of /etc/paths instead. Not sure if either will survive a system upgrade, though. But on the other hand, it will work for all users on the machine.

- Harald


More information about the macports-users mailing list