@@ -464,11 +464,11 @@ sub make_tlpobj {
464464
465465 # for all other patterns we create the list and add the files
466466 foreach my $p (@allpospats ) {
467- ddebug (" pos pattern $p \n " );
467+ dddebug (" pos pattern $p \n " );
468468 $self -> _do_normal_pattern($p ,$tlp ,$tltree ,$pattype );
469469 }
470470 foreach my $p (@allnegpats ) {
471- ddebug (" neg pattern $p \n " );
471+ dddebug (" neg pattern: $p \n " );
472472 $self -> _do_normal_pattern($p ,$tlp ,$tltree ,$pattype ,1);
473473 }
474474 }
@@ -479,12 +479,14 @@ sub make_tlpobj {
479479 # in the above loop. We only have to deal with the specialities of
480480 # the bin patterns
481481 foreach my $p (@allpospats ) {
482+ # ddebug ("pos binpattern: $p\n");
482483 my @todoarchs = $tltree -> architectures;
483484 my $finalp = $p ;
484- if ($p =~ m % ^(\w +)/(!?[-_a-z0-9,]+)\s +(.*)$ % ) {
485- my $pt = $1 ;
486- my $aa = $2 ;
487- my $pr = $3 ;
485+ if ($p =~ m % ^(\w +)/(!?[-_a-z0-9,]*)\s *(.*)$ % ) {
486+ my $pt = $1 ; # pattern type
487+ my $aa = $2 ; # arch list (after possible !)
488+ my $pr = $3 ; # filename
489+ # ddebug (" pt=$pt, aa=$aa, pr=$pr\n"); #if $p=~/luajittex/;
488490 if ($aa =~ m / ^!(.*)$ / ) {
489491 # negative specification
490492 my %negarchs ;
@@ -501,6 +503,7 @@ sub make_tlpobj {
501503 }
502504 # set $p to the pattern without arch specification
503505 $finalp = " $pt $pr " ;
506+ # ddebug ("finalp = $pt|$pr\n");
504507 }
505508 # one final trick
506509 # if the original pattern string matches bin/windows/ then we *only*
@@ -511,8 +514,10 @@ sub make_tlpobj {
511514 # now @todoarchs contains only those archs for which we want
512515 # to match the pattern
513516 foreach my $arch (sort @todoarchs ) {
517+ # ddebug (" doing arch: $arch\n");
514518 # get only those files matching the pattern
515- my @archfiles = $tltree -> get_matching_files(' bin' ,$finalp , $pkgname , $arch );
519+ my @archfiles
520+ = $tltree -> get_matching_files (' bin' , $finalp , $pkgname , $arch );
516521 if (!@archfiles ) {
517522 if (($arch ne " windows" ) || defined ($: :tlpsrc_pattern_warn_win)) {
518523 tlwarn(" $self ->{name} ($arch ): no hit on binpattern $finalp \n " );
@@ -522,9 +527,10 @@ sub make_tlpobj {
522527 }
523528 }
524529 foreach my $p (@allnegpats ) {
530+ # ddebug ("neg binpattern: $p\n");
525531 my @todoarchs = $tltree -> architectures;
526532 my $finalp = $p ;
527- if ($p =~ m % ^(\w +)/(!?[-_a-z0-9,]+ )\s + (.*)$ % ) {
533+ if ($p =~ m % ^(\w +)/(!?[-_a-z0-9,]* )\s * (.*)$ % ) {
528534 my $pt = $1 ;
529535 my $aa = $2 ;
530536 my $pr = $3 ;
@@ -549,7 +555,8 @@ sub make_tlpobj {
549555 # to match the pattern
550556 foreach my $arch (sort @todoarchs ) {
551557 # get only those files matching the pattern
552- my @archfiles = $tltree -> get_matching_files(' bin' , $finalp , $pkgname , $arch );
558+ my @archfiles
559+ = $tltree -> get_matching_files(' bin' , $finalp , $pkgname , $arch );
553560 if (!@archfiles ) {
554561 if (($arch ne " windows" ) || defined ($: :tlpsrc_pattern_warn_win)) {
555562 tlwarn(" $self ->{name} ($arch ): no hit on negative binpattern $finalp \n " )
@@ -642,16 +649,16 @@ sub find_default_patterns {
642649 for my $cat (keys %autopatterns ) {
643650 ddebug (" Category $cat \n " );
644651 for my $d (@{$autopatterns {$cat }{" bin" }}) {
645- ddebug (" auto bin pattern $d \n " );
652+ dddebug (" auto bin pattern $d \n " );
646653 }
647654 for my $d (@{$autopatterns {$cat }{" src" }}) {
648- ddebug (" auto src pattern $d \n " );
655+ dddebug (" auto src pattern $d \n " );
649656 }
650657 for my $d (@{$autopatterns {$cat }{" doc" }}) {
651- ddebug (" auto doc pattern $d \n " );
658+ dddebug (" auto doc pattern $d \n " );
652659 }
653660 for my $d (@{$autopatterns {$cat }{" run" }}) {
654- ddebug (" auto run pattern $d \n " );
661+ dddebug (" auto run pattern $d \n " );
655662 }
656663 }
657664
0 commit comments