summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--lib/ExtUtils/MakeMaker.pm11
1 files changed, 10 insertions, 1 deletions
diff --git a/lib/ExtUtils/MakeMaker.pm b/lib/ExtUtils/MakeMaker.pm
index 070156bedc..08a1c66ccd 100644
--- a/lib/ExtUtils/MakeMaker.pm
+++ b/lib/ExtUtils/MakeMaker.pm
@@ -441,7 +441,12 @@ sub ExtUtils::MakeMaker::new {
}
if ($self->{PARENT}) {
$self->{PARENT}->{CHILDREN}->{$newclass} = $self;
- $self->{CAPI} = $self->{PARENT}->{CAPI};
+ if (exists $self->{PARENT}->{CAPI}
+ and not exists $self->{CAPI})
+ {
+ # inherit, but only if already unspecified
+ $self->{CAPI} = $self->{PARENT}->{CAPI};
+ }
}
} else {
parse_args($self,split(' ', $ENV{PERL_MM_OPT} || ''),@ARGV);
@@ -1210,6 +1215,10 @@ currently used by MakeMaker but may be handy in Makefile.PLs.
Switch to force usage of the Perl C API even when compiling for PERL_OBJECT.
+Note that this attribute is passed through to any recursive build,
+but if and only if the submodule's Makefile.PL itself makes no mention
+of the 'CAPI' attribute.
+
=item CCFLAGS
String that will be included in the compiler call command line between