@@ -24,6 +24,7 @@ my @Prepend_parent;
24
24
my %Recognized_Att_Keys ;
25
25
our %macro_fsentity ; # whether a macro is a filesystem name
26
26
our %macro_dep ; # whether a macro is a dependency
27
+ my @children_skip ;
27
28
28
29
our $VERSION = ' 7.05_05' ;
29
30
$VERSION = eval $VERSION ; # # no critic [BuiltinFunctions::ProhibitStringyEval]
@@ -394,6 +395,11 @@ sub full_setup {
394
395
MAP_TARGET INST_MAN1DIR INST_MAN3DIR PERL_SRC
395
396
PERL FULLPERL
396
397
) ;
398
+
399
+ # in generate_makefile - EUMM's with a PARENT skip these sections
400
+ @children_skip = qw(
401
+ install dist dist_basics dist_core distdir dist_test dist_ci
402
+ ) ;
397
403
}
398
404
399
405
sub _has_cpan_meta_requirements {
477
483
);
478
484
479
485
$self -> makefile_preamble(\@ARGV , \%initial_att , \%configure_att );
480
-
481
- # turn the SKIP array into a SKIPHASH hash
482
- for my $skip (@{$self -> {SKIP } || []}) {
483
- $self -> {SKIPHASH }{$skip } = 1;
484
- }
485
- delete $self -> {SKIP }; # free memory
486
- if ($self -> {PARENT }) {
487
- for (qw/ install dist dist_basics dist_core distdir dist_test dist_ci/ ) {
488
- $self -> {SKIPHASH }{$_ } = 1;
489
- }
490
- }
491
-
492
- # We run all the subdirectories now. They don't have much to query
493
- # from the parent, but the parent has to query them: if they need linking!
494
- unless ($self -> {NORECURS }) {
495
- $self -> eval_in_subdirs if @{$self -> {DIR }};
496
- }
497
-
498
- foreach my $section ( @MM_Sections ) {
499
- # Support for new foo_target() methods.
500
- my $method = $section ;
501
- $method .= ' _target' unless $self -> can($method );
502
-
503
- print " Processing Makefile '$section ' section\n " if ($Verbose >= 2);
504
- my ($skipit ) = $self -> skipsection($section );
505
- if ($skipit ) {
506
- push @{$self -> {RESULT }}, " \n # --- MakeMaker $section section $skipit ." ;
507
- } else {
508
- my (%a ) = %{$self -> {$section } || {}};
509
- push @{$self -> {RESULT }}, " \n # --- MakeMaker $section section:" ;
510
- push @{$self -> {RESULT }}, " # " . join " , " , %a if $Verbose && %a ;
511
- push @{$self -> {RESULT }}, $self -> maketext_filter(
512
- $self -> $method ( %a )
513
- );
514
- }
515
- }
516
-
517
- push @{$self -> {RESULT }}, " \n # End." ;
486
+ $self -> generate_makefile;
518
487
519
488
$self ;
520
489
}
@@ -564,6 +533,34 @@ sub extract_ARGV {
564
533
}
565
534
}
566
535
536
+ sub generate_makefile {
537
+ my ($self ) = @_ ;
538
+ # turn the SKIP array into a SKIPHASH hash
539
+ $self -> {SKIPHASH }{$_ } = 1 for @{$self -> {SKIP } || []};
540
+ delete $self -> {SKIP }; # free memory
541
+ if ($self -> {PARENT }) { $self -> {SKIPHASH }{$_ } = 1 for @children_skip }
542
+ # We run all the subdirectories now. They don't have much to query
543
+ # from the parent, but the parent has to query them: if they need linking!
544
+ $self -> eval_in_subdirs if @{$self -> {DIR }} and not $self -> {NORECURS };
545
+ foreach my $section ( @MM_Sections ) {
546
+ print " Processing Makefile '$section ' section\n " if ($Verbose >= 2);
547
+ if ($self -> skipsection($section )){
548
+ push @{$self -> {RESULT }}, " \n # --- MakeMaker $section section skipped." ;
549
+ } else {
550
+ my (%a ) = %{$self -> {$section } || {}};
551
+ push @{$self -> {RESULT }}, " \n # --- MakeMaker $section section:" ;
552
+ push @{$self -> {RESULT }}, " # " . join " , " , %a if $Verbose && %a ;
553
+ # Support new foo_target() methods.
554
+ my $method = $section ;
555
+ $method .= ' _target' unless $self -> can($method );
556
+ push @{$self -> {RESULT }}, $self -> maketext_filter(
557
+ $self -> $method ( %a )
558
+ );
559
+ }
560
+ }
561
+ push @{$self -> {RESULT }}, " \n # End." ;
562
+ }
563
+
567
564
sub extract_PARENT {
568
565
my ($self ) = @_ ;
569
566
push @Parent , $self ;
0 commit comments