summaryrefslogtreecommitdiff
path: root/t/run
diff options
context:
space:
mode:
authorDaniel Dragan <bulk88@hotmail.com>2014-11-23 16:14:40 -0500
committerTony Cook <tony@develop-help.com>2014-11-27 15:46:27 +1100
commitebfad2b9fea703468a88acb6a1afbb759366ffd5 (patch)
tree294ea272542016ed9a57987d575880565c0638b3 /t/run
parent3d50e539516253e2d26166a3eca071cba7bd72b8 (diff)
downloadperl-ebfad2b9fea703468a88acb6a1afbb759366ffd5.tar.gz
allow PERL_DISABLE_PMC to be defined from anywhere
I enable PERL_DISABLE_PMC in a .h, not in CCFLAGS. CCFLAGS on Unix typically has no -Ds in it, build options go into config.h, not Config.pm's CCFLAGS. This change allows PERL_DISABLE_PMC option to pass tests regardless of where it is defined. cpan/parent/t/parent-pmc.t is not fixed by this patch.
Diffstat (limited to 't/run')
-rw-r--r--t/run/switchM.t10
1 files changed, 9 insertions, 1 deletions
diff --git a/t/run/switchM.t b/t/run/switchM.t
index 603d5c5fa0..d2b1d2d6ce 100644
--- a/t/run/switchM.t
+++ b/t/run/switchM.t
@@ -24,7 +24,15 @@ like(runperl(switches => ['-Irun/flib/', '-Mbroken'], stderr => 1),
"Ensure -Irun/flib/ produces correct filename in warnings");
SKIP: {
- if ( $Config{ccflags} =~ /(?:^|\s)-DPERL_DISABLE_PMC\b/ ) {
+ my $no_pmc;
+ foreach(Config::non_bincompat_options()) {
+ if($_ eq "PERL_DISABLE_PMC"){
+ $no_pmc = 1;
+ last;
+ }
+ }
+
+ if ( $no_pmc ) {
skip('Tests fail without PMC support', 2);
}