Skip Menu |

This queue is for tickets about the Inline-CPP CPAN distribution.

Report information
The Basics
Id: 72394
Status: resolved
Worked: 20 min
Priority: 0/
Queue: Inline-CPP

People
Owner: davido [...] cpan.org
Requestors: sisyphus [...] cpan.org
Cc:
AdminCc:

Bug Information
Severity: Critical
Broken in: 0.28
Fixed in: (no value)



Subject: 0.29 builds only with g++ compiler
Hi, The 0.29 distro is effectively hard coded to use only g++ as the compiler. Here is a patch to Makefile.PL that addresses this shortcoming. ############################## --- Makefile.PL_orig 2011-11-13 20:56:58 +1100 +++ Makefile.PL 2011-11-13 20:56:03 +1100 @@ -71,8 +71,8 @@ close CPP; for (@lines) { - s|\@COMPILER|$cpp_compiler| if m|\# default compiler|; - s|\@DEFAULTLIBS|$libs| if m|\# default libs|; + $_ = " \$o->{ILSM}{MAKEFILE}{CC} ||= '$cpp_compiler'; # default compiler\n" if $_ =~ /# default compiler/; + $_ = " \$o->{ILSM}{MAKEFILE}{LIBS} ||= ['$libs']; # default libs\n" if $_ =~ /# default libs/; } open CPP, ">CPP.pm" ############################## I'm sure there are alternative approaches that could be taken to resolve this. Note that the above patch relies on the presence of the comments "# default compiler" and "#default libs" to work - probably not a good practice. If those comments are removed from CPP.pm (or altered in such a way that the matching regex no longer works) then the source is broken again. Cheers, Rob
This patch (#72394) has been applied as part of the 0.30 dist. There is also a change to CPP.pm reflecting the patch submitted in RT#72396, which is applied in 0.30 as well. Thanks sisyphus. Not sure I'm ultra-qualified either, but I suppose willingness to keep patches and updates fresh is at least one component of being qualified that I am happy to provide.
Patch applied for v0.30.