Skip to content
This repository was archived by the owner on Jun 1, 2023. It is now read-only.

Commit 0cf9926

Browse files
committed
ExtUtils-CBuilder: Update to 0.280226
Fix C++ compiler detection (RT #131749)
1 parent c4f9ed5 commit 0cf9926

File tree

21 files changed

+64
-29
lines changed

21 files changed

+64
-29
lines changed

Porting/Maintainers.pl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -615,7 +615,7 @@ package Maintainers;
615615
},
616616

617617
'ExtUtils::CBuilder' => {
618-
'DISTRIBUTION' => 'AMBS/ExtUtils-CBuilder-0.280224.tar.gz',
618+
'DISTRIBUTION' => 'AMBS/ExtUtils-CBuilder-0.280226.tar.gz',
619619
'FILES' => q[dist/ExtUtils-CBuilder],
620620
'EXCLUDED' => [
621621
qw(README.mkdn),

dist/ExtUtils-CBuilder/Changes

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,12 @@
11
Revision history for Perl extension ExtUtils::CBuilder.
22

3+
0.280226 - 2017-07-14
4+
5+
Fixed:
6+
7+
- Fix C++ compiler detection (RT #131749)
8+
(thanks to stphnlyd)
9+
310
0.280225 - 2016-01-04
411

512
Fixed:
@@ -8,7 +15,7 @@ Revision history for Perl extension ExtUtils::CBuilder.
815

916
0.280224 - 2015-10-09
1017

11-
Enhncements:
18+
Enhancements:
1219

1320
- Use warnings/strict on all modules.
1421

dist/ExtUtils-CBuilder/LICENSE

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
This software is copyright (c) 2015 by Ken Williams.
1+
This software is copyright (c) 2017 by Ken Williams.
22

33
This is free software; you can redistribute it and/or modify it under
44
the same terms as the Perl 5 programming language system itself.
@@ -12,7 +12,7 @@ b) the "Artistic License"
1212

1313
--- The GNU General Public License, Version 1, February 1989 ---
1414

15-
This software is Copyright (c) 2015 by Ken Williams.
15+
This software is Copyright (c) 2017 by Ken Williams.
1616

1717
This is free software, licensed under:
1818

@@ -272,7 +272,7 @@ That's all there is to it!
272272

273273
--- The Artistic License 1.0 ---
274274

275-
This software is Copyright (c) 2015 by Ken Williams.
275+
This software is Copyright (c) 2017 by Ken Williams.
276276

277277
This is free software, licensed under:
278278

dist/ExtUtils-CBuilder/Makefile.PL

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# This file was automatically generated by Dist::Zilla::Plugin::MakeMaker v5.039.
1+
# This file was automatically generated by Dist::Zilla::Plugin::MakeMaker v6.010.
22
use strict;
33
use warnings;
44

@@ -29,7 +29,7 @@ my %WriteMakefileArgs = (
2929
"TEST_REQUIRES" => {
3030
"Test::More" => "0.47"
3131
},
32-
"VERSION" => "0.280225",
32+
"VERSION" => "0.280226",
3333
"test" => {
3434
"TESTS" => "t/*.t"
3535
}
@@ -60,6 +60,6 @@ delete $WriteMakefileArgs{CONFIGURE_REQUIRES}
6060
unless eval { ExtUtils::MakeMaker->VERSION(6.52) };
6161

6262
$WriteMakefileArgs{INSTALLDIRS} = 'perl'
63-
if $] >= 5.009003 && $] <= 5.011000;
63+
if "$]" >= 5.009003 && "$]" <= 5.011000;
6464

6565
WriteMakefile(%WriteMakefileArgs);

dist/ExtUtils-CBuilder/lib/ExtUtils/CBuilder.pm

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
package ExtUtils::CBuilder;
2-
$ExtUtils::CBuilder::VERSION = '0.280225';
2+
$ExtUtils::CBuilder::VERSION = '0.280226';
33
use File::Spec ();
44
use File::Path ();
55
use File::Basename ();

dist/ExtUtils-CBuilder/lib/ExtUtils/CBuilder/Base.pm

Lines changed: 16 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
package ExtUtils::CBuilder::Base;
2-
$ExtUtils::CBuilder::Base::VERSION = '0.280225';
2+
$ExtUtils::CBuilder::Base::VERSION = '0.280226';
33
use strict;
44
use warnings;
55
use File::Spec;
@@ -45,16 +45,26 @@ sub new {
4545
if defined $ENV{LDFLAGS};
4646

4747
unless ( exists $self->{config}{cxx} ) {
48-
my ($ccpath, $ccbase, $ccsfx ) = fileparse($self->{config}{cc}, qr/\.[^.]*/);
48+
49+
my ($ccbase, $ccpath, $ccsfx ) = fileparse($self->{config}{cc}, qr/\.[^.]*/);
50+
51+
## If the path is just "cc", fileparse returns $ccpath as "./"
52+
$ccpath = "" if $self->{config}{cc} =~ /^$ccbase$ccsfx$/;
53+
4954
foreach my $cxx (@{$cc2cxx{$ccbase}}) {
50-
if( can_run( File::Spec->catfile( $ccpath, $cxx, $ccsfx ) ) ) {
51-
$self->{config}{cxx} = File::Spec->catfile( $ccpath, $cxx, $ccsfx );
55+
my $cxx1 = File::Spec->catfile( $ccpath, $cxx . $ccsfx);
56+
57+
if( can_run( $cxx1 ) ) {
58+
$self->{config}{cxx} = $cxx1;
5259
last;
5360
}
54-
if( can_run( File::Spec->catfile( $cxx, $ccsfx ) ) ) {
55-
$self->{config}{cxx} = File::Spec->catfile( $cxx, $ccsfx );
61+
my $cxx2 = $cxx . $ccsfx;
62+
63+
if( can_run( $cxx2 ) ) {
64+
$self->{config}{cxx} = $cxx2;
5665
last;
5766
}
67+
5868
if( can_run( $cxx ) ) {
5969
$self->{config}{cxx} = $cxx;
6070
last;

dist/ExtUtils-CBuilder/lib/ExtUtils/CBuilder/Platform/Unix.pm

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
package ExtUtils::CBuilder::Platform::Unix;
2-
$ExtUtils::CBuilder::Platform::Unix::VERSION = '0.280225';
2+
$ExtUtils::CBuilder::Platform::Unix::VERSION = '0.280226';
33
use warnings;
44
use strict;
55
use ExtUtils::CBuilder::Base;

dist/ExtUtils-CBuilder/lib/ExtUtils/CBuilder/Platform/VMS.pm

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
package ExtUtils::CBuilder::Platform::VMS;
2-
$ExtUtils::CBuilder::Platform::VMS::VERSION = '0.280225';
2+
$ExtUtils::CBuilder::Platform::VMS::VERSION = '0.280226';
33
use warnings;
44
use strict;
55
use ExtUtils::CBuilder::Base;

dist/ExtUtils-CBuilder/lib/ExtUtils/CBuilder/Platform/Windows.pm

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
package ExtUtils::CBuilder::Platform::Windows;
2-
$ExtUtils::CBuilder::Platform::Windows::VERSION = '0.280225';
2+
$ExtUtils::CBuilder::Platform::Windows::VERSION = '0.280226';
33
use strict;
44
use warnings;
55

@@ -151,7 +151,7 @@ sub link {
151151
# if running in perl source tree, look for libs there, not installed
152152
my $lddlflags = $cf->{lddlflags};
153153
my $perl_src = $self->perl_src();
154-
$lddlflags =~ s/\Q$cf->{archlibexp}\E[\\\/]CORE/$perl_src\/lib\/CORE/ if $perl_src;
154+
$lddlflags =~ s{\Q$cf->{archlibexp}\E[\\/]CORE}{$perl_src\/lib/CORE} if $perl_src;
155155
156156
my %spec = (
157157
srcdir => $to,

dist/ExtUtils-CBuilder/lib/ExtUtils/CBuilder/Platform/Windows/BCC.pm

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
package ExtUtils::CBuilder::Platform::Windows::BCC;
2-
$ExtUtils::CBuilder::Platform::Windows::BCC::VERSION = '0.280225';
2+
$ExtUtils::CBuilder::Platform::Windows::BCC::VERSION = '0.280226';
33
use strict;
44
use warnings;
55

0 commit comments

Comments
 (0)