subdirectory Makefiles should inherit CAPI setting from command line
Jan Dubois [Wed, 23 Dec 1998 21:26:38 +0000 (22:26 +0100)]
To: makemaker@franz.ww.TU-Berlin.DE, perl5-porters@perl.org
Message-ID: <36895086.8849224@smtp1.ibm.net>

p4raw-id: //depot/cfgperl@2503

lib/ExtUtils/MakeMaker.pm

index 36afa91..6bc0f6c 100644 (file)
@@ -439,7 +439,10 @@ sub ExtUtils::MakeMaker::new {
                unless $self->file_name_is_absolute($self->{$key})
                || ($^O eq 'VMS' and ($key =~ /PERL$/ && $self->{$key} =~ /^[\w\-\$]+$/));
        }
-       $self->{PARENT}->{CHILDREN}->{$newclass} = $self if $self->{PARENT};
+       if ($self->{PARENT}) {
+           $self->{PARENT}->{CHILDREN}->{$newclass} = $self;
+           $self->{CAPI} = $self->{PARENT}->{CAPI};
+       }
     } else {
        parse_args($self,split(' ', $ENV{PERL_MM_OPT} || ''),@ARGV);
     }