[MacPorts] #35533: p5.12-xml-parser: Couldn't find your C compiler

MacPorts noreply at macports.org
Fri Aug 24 21:03:18 PDT 2012


#35533: p5.12-xml-parser: Couldn't find your C compiler
-----------------------------------+----------------------------------------
 Reporter:  Onemer117@…            |       Owner:  macports-tickets@…                   
     Type:  defect                 |      Status:  new                                  
 Priority:  Normal                 |   Milestone:                                       
Component:  ports                  |     Version:  2.1.2                                
 Keywords:                         |        Port:  p5.12-xml-parser                     
-----------------------------------+----------------------------------------

Comment(by piet@…):

 Replying to [comment:1 ryandesign@…]:
 > The log says "Couldn't find your C compiler" so this suggests you
 haven't installed Xcode and its command line tools properly.


 I had the same problem, and really I had the C compiler (XCode) installed.
 I tried everything I could find to solve the problem but to no
 avail.[[BR]]
 Today I decided to dig deeper in the problem and with a lot of patch work
 I could get the thing installed.



 If you look into the log file, you will see the following lines:


 {{{
 :info:configure Couldn't find your C compiler
 :info:configure Compilation failed in require at Makefile.PL line 5.
 :info:configure BEGIN failed--compilation aborted at Makefile.PL line 5.
 }}}


 So the real error seems to be in line 5 of Makefile.PL, This line
 contains:


 {{{
 use Devel::CheckLib;
 }}}


 However in my Macports perl5.12 installation there is no Devel::CheckLib
 module. And I couldn't find a port to install it. [[BR]]
 So I decided to take that out, and to disable the check_lib call at line
 32.[[BR]]
 This line checks for the presence of the expat library, which isn't really
 necessary in Macports because of the dependency on expat. [[BR]]
 It would be wiser IMHO to add a port for Devel::CheckLib and take this as
 a dependency.



 The following problem was with the compilation of the Expat Perl module.
 The Makefiles have /usr/bin/gcc-42 as the required C compiler, which I
 don't have. [[BR]]
 I have /usr/bin/gcc, which is a link to llvm-gcc-4.2. So I made
 /usr/bin/gcc-4.2 a link to /usr/bin/gcc and that finally solved the
 problem.



 Apparently the install procedure needs some additional patches.

-- 
Ticket URL: <https://trac.macports.org/ticket/35533#comment:2>
MacPorts <http://www.macports.org/>
Ports system for Mac OS


More information about the macports-tickets mailing list