Opened 10 years ago

Closed 10 years ago

#41236 closed defect (invalid)

selfupdate to 2.2.1 fails: configure: error: cannot run C compiled programs.

Reported by: paul@… Owned by: macports-tickets@…
Priority: Normal Milestone:
Component: base Version: 2.2.0
Keywords: Cc:
Port:

Description

I'm on OSX 10.9.0 (13A603) with MacPorts 2.2.0 installed, and apparently Xcode version 4.4.1. Trying to selfupdate to MacPorts 2.2.1 I run sudo port -v selfupdate and everything starts off well until we get to:

--->  MacPorts base is outdated, installing new version 2.2.1
Installing new MacPorts release in /opt/local as root:admin; permissions 0755; Tcl-Package in /Library/Tcl

checking build system type... x86_64-apple-darwin13.0.0
checking host system type... x86_64-apple-darwin13.0.0
checking target system type... x86_64-apple-darwin13.0.0
checking MacPorts version... 2.2.1
checking for sw_vers... /usr/bin/sw_vers
checking for defaults... /usr/bin/defaults
checking for xcode-select... /usr/bin/xcode-select
checking Mac OS X version... 10.9
checking Xcode location... /Applications/Xcode.app/Contents/Developer
checking Xcode version... 4.4.1
checking for gcc... /usr/bin/cc
checking whether the C compiler works... yes
checking for C compiler default output file name... a.out
checking for suffix of executables... 
checking whether we are cross compiling... configure: error: in `/opt/local/var/macports/sources/rsync.macports.org/release/tarballs/base':
configure: error: cannot run C compiled programs.
If you meant to cross compile, use `--host'.
See `config.log' for more details
Command failed: cd /opt/local/var/macports/sources/rsync.macports.org/release/tarballs/base && CC=/usr/bin/cc OBJC=/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 SELFUPDATING=1 && make install SELFUPDATING=1
Exit code: 1
Error: Error installing new MacPorts base: command execution failed
To report a bug, follow the instructions in the guide:
    http://guide.macports.org/#project.tickets
Error: /opt/local/bin/port: port selfupdate failed: Error installing new MacPorts base: command execution failed

I would attach the config.log that's mentioned, but I looked for it and can't find it. Not even sure where it would be. Best guess is /opt/local/var/log/ but that log directory doesn't exist under var on my computer.

I also tried changing the sources.conf file to point to rsync://rsync.macports.org/release/ports/ but that gave the same error.

Change History (4)

comment:1 Changed 10 years ago by neverpanic (Clemens Lang)

The config.log is in /opt/local/var/macports/sources/rsync.macports.org/release/tarballs/base. Mavericks doesn't support Xcode 4.x, please update your Xcode and install the command line tools using xcode-select --install.

comment:2 Changed 10 years ago by pawemo@…

Thanks! (Would have been nice if the check for Xcode version had given a warning...)

I am now following the instructions here: wiki:Migration

which I found on the MacPorts user list. For Mavericks it says: "For minimum support of MacPorts, you need the Command Line Tools, which can be installed using xcode-select --install. If you are installing MacPorts from source, you will also want to run sudo xcodebuild -license. Note that some ports will require a full Xcode installation, which is available for free on the Mac App Store."

I went ahead with the full app store install, so that should do the trick right? I have already reinstalled MacPorts and that went fine, but maybe I will do xcode-select --install just for good measure.

Last edited 10 years ago by ryandesign (Ryan Carsten Schmidt) (previous) (diff)

comment:3 Changed 10 years ago by neverpanic (Clemens Lang)

Yeah, you still need xcode-select --install, even if you have Xcode.

comment:4 Changed 10 years ago by ryandesign (Ryan Carsten Schmidt)

Resolution: invalid
Status: newclosed
Note: See TracTickets for help on using tickets.