Mac Ports Update Failing

13,240

Solution 1

You need to use the -d option to get enough information to diagnose this; but take a look at https://trac.macports.org/wiki/FAQ#selfupdatefails for common problems and solutions.

Solution 2

Seems Apple no longer installs Xcode's command line tools. See here: http://ericwilson.erics.ws/ericsblog/2012/8/26/macports-port-selfupdate-fail for solution.

Solution 3

Just wanted to add that on Mac OS 10.12 Sierra i was getting the WARNING: GNUSTEP_SYSTEM_ROOT is not defined error on selfupdate and i did already have the Xcode command line tools installed, licensed and working. But my copy of Xcode had become out of date, even though that was not showing up on the automatic software updates.

I had version 7 and for Sierra (and macports) you need version 8.

So I manually downloaded Xcode 8 via the App Store and it solved the problem for me.

Share:
13,240
Hans Adiputra Arijanto
Author by

Hans Adiputra Arijanto

Updated on June 12, 2022

Comments

  • Hans Adiputra Arijanto
    Hans Adiputra Arijanto about 2 years
    hansarijanto$ port -v
    MacPorts 2.0.3
    hansarijanto$ xcodebuild -version
    Xcode 4.3.2
    Build version 4E2002
    

    I am running the above xcode and macport version. on max os x when I try to self update my mac port I get the following error.

    hansarijanto$ sudo port selfupdate
    Password:
    --->  Updating MacPorts base sources using rsync
    MacPorts base version 2.0.3 installed,
    MacPorts base version 2.0.4 downloaded.
    --->  Updating the ports tree
    --->  MacPorts base is outdated, installing new version 2.0.4
    Installing new MacPorts release in /opt/local as root:admin; permissions 0755; Tcl-Package in /Library/Tcl
    
    Error: /opt/local/bin/port: port selfupdate failed: Error installing new MacPorts base: shell command failed (see log for details)
    

    I am trying to update mac port to install qt.

    sudo port install qt4-mac-devel(error no SDK found)
    

    which I need to install webkit-capybara

    sudo gem install capybara-webkit -v '0.7.2'(error in setting up native environment)
    
  • Hans Adiputra Arijanto
    Hans Adiputra Arijanto about 12 years
    configure: WARNING: GNUSTEP_SYSTEM_ROOT is not defined in your environment, preventing the use of GNUstep's Foundation library configure: error: Could not find a working Foundation implementation I reveived the following error
  • Hans Adiputra Arijanto
    Hans Adiputra Arijanto about 12 years
    shell command "cd /opt/local/var/macports/sources/rsync.macports.org/release/t‌​arballs/base && CC=/usr/bin/cc ./configure --prefix=/opt/local --with-tclpackage=/Library/Tcl --with-install-user=root --with-install-group=admin --with-directory-mode=0755 --enable-readline && make && make install SELFUPDATING=1" returned error 1 DEBUG: Error installing new MacPorts base: shell command failed (see log for details) while executing "macports::selfupdate [array get global_options] base_updated" Error: /opt/local/bin/port: port selfupdate failed: Error installing new MacPorts base
  • Sven Amann
    Sven Amann over 10 years
    Running "xcode-select --install" installs the command-line tools. This did the job for me, after I updated to Maverick and ports suddenly stopped working even though I had XCode installed and port working before the update.
  • Neal Young
    Neal Young about 6 years
    I had the same issue for Xcode version 8 (needed 9) and High Sierra.