I am trying to install ghostcript on Macports 2.2.1-10.0-Mavericks. I get the following message:
**checking for gcc... /usr/bin/clang checking whether the C compiler works... no configure: error: in `/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_print_ghostscript/ghostscript/work/ghostscript-9.10':
configure: error: C compiler cannot create executables See `config.log' for more details Command failed: cd
"/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_print_ghostscript/ghostscript/work/ghostscript-9.10"
&& ./configure --prefix=/opt/local --disable-compile-inits
--disable-cups --disable-dbus --disable-gtk --without-luratech --with-system-libtiff --with-x Exit code: 77 Error: Failed to configure ghostscript, consult
/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_print_ghostscript/ghostscript/work/ghostscript-9.10/config.log
Error: org.macports.configure for port ghostscript returned: configure
failure: command execution failed Warning: targets not executed for
ghostscript: org.macports.activate org.macports.configure
org.macports.build org.macports.destroot org.macports.install Please
see the log file for port ghostscript for details:
/opt/local/var/macports/logs/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_print_ghostscript/ghostscript/main.log
To report a bug, follow the instructions in the guide:
http://guide.macports.org/#project.tickets Error: Processing of port ghostscript failed**
Any ideas how to solve this?
Best Answer
You either didn't install the Xcode Command Line Tools (use
xcode-select --install
to do that), or didn't accept the Xcode License agreement (that can be achieved usingsudo xcodebuild -license
).Once you've completed both of these checks, configure should correctly pick up the working compiler.
MacPorts 2.3 will contain checks to detect and warn you about these problems.