Last Updated: February 25, 2016
·
560
· momoto

macports selfupdate failed

$ sudo port selfupdate -v

...

Error: Error installing new MacPorts base: command execution failed
Please run `port -v selfupdate' for details.
Error: /opt/local/bin/port: port selfupdate failed: Error installing new MacPorts base: command execution failed

Install the "Command Line Tools" first

$ sudo xcode-select --install

Then upgrade the ports

$ sudo port selfupdate -v

...

The ports tree has been updated. To upgrade your installed ports, you should run
  port upgrade outdated