Macports stopped working after xcode 4.6 upgrade

Jeremy Lavergne jeremy at lavergne.gotdns.org
Tue Feb 19 13:40:40 PST 2013


>> sh: port: command not found
> 
> Any ideas to fix it? I'm using OSX Mountain Lion and I don't know the version of Macports but I downloaded it in December last year. Any help would be greatly appreciated. Thanks.

The error means `port` is no longer in your $PATH. You should be able to run `/opt/local/bin/port` in the meantime.

Here's how to fix $PATH (from macports.org/install.php):

You will need to manually adapt your shell's environment to work with MacPorts and your chosen installation prefix (the value passed to configure's --prefix flag, defaulting to /opt/local):

	• Add ${prefix}/bin and ${prefix}/sbin to the start of your PATH environment variable so that MacPorts-installed programs take precedence over system-provided programs of the same name.
	• If a standard MANPATH environment variable already exists (that is, one that doesn't contain any empty components), add the ${prefix}/share/man path to it so that MacPorts-installed man pages are found by your shell.
	• For Tiger and earlier only, add an appropriate X11 DISPLAY environment variable to run X11-dependent programs, as Leopard takes care of this requirement on its own.





More information about the macports-users mailing list