Perl "... / config.h needed by the Makefile does not work after updating OSX Lion

SOLVED. See below.

Just upgraded to OSX Lion and trying to run my Perl installation again:

sudo /usr/bin/perl -MCPAN -e 'install "MODULENAME"'

with any MODULENAME value that I tried (for example, JSON ) produces:

 ... Checking if your kit is complete... Looks good Writing Makefile for JSON make: *** No rule to make target `/System/Library/Perl/5.12/darwin-thread-multi-2level/CORE/config.h', needed by `Makefile'. Stop. MAKAMAKA/JSON-2.53.tar.gz /Developer/usr/bin/make -- NOT OK 

I can not find anything like config.h anywhere, the directory exists, though ...

Even this does not work:

 /usr/bin/cpan CPAN 

SOLVED: Download and install the latest version of Xcode from the AppStore. Please note that simply downloading Xcode from the AppStore does not install it (why, Apple, and why?), But only unloads the installer in / Applications. Run the installer to fix this problem.

+7
source share
2 answers

SOLVED: Download and install the latest version of Xcode from the AppStore. Please note that simply downloading Xcode from the AppStore does not install it (why, Apple, and why?), But only unloads the installer in / Applications. Run the installer to fix this problem.

+7
source

I had this problem after installing Xcode because Xcode did not automatically install the Command Line Tools for Xcode package. It is available in Xcode | Settings | Downloads | Components and click "Install" next to "Command Line Tools."

Now that this is a separate package, it can also solve this problem without installing all of Xcode (i.e. you can just install this package :-)

+6
source

All Articles