Changeset 3473


Ignore:
Timestamp:
Oct 3, 2015, 11:16:38 AM (2 years ago)
Author:
bruno
Message:

Fix mindi-get-perl-modules to support symlinks

  • If perl has symlinks in its installation, mindi-get-perl-modules wasn't returning them. THis is now fixed by calling mr_file_read_all_link
File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/3.2/mindi/mindi-get-perl-modules

    r3462 r3473  
    104104unlink("$tmpf");
    105105
     106my $h2;
     107
    106108pb_log(1,"Returning:");
    107109pb_log(1,Dumper($h));
    108110pb_log(1,"-----------------------\n");
     111# In case there are links in the perl installation
    109112foreach my $f (sort keys %$h) {
    110         # Skip the temp file
    111         next if ($h->{$f}->{'file'} =~ /$ENV{'PBTMP'}/);
    112         print "$h->{$f}->{'file'}\n";
     113    # Skip the temp file
     114    next if ($h->{$f}->{'file'} =~ /$ENV{'PBTMP'}/);
     115    my $file = mr_file_read_all_link($h->{$f}->{'file'});
     116    foreach my $k (keys %$file) {
     117        $h2->{$k} = "";
     118    }
     119}
     120
     121foreach my $f (sort keys %$h2) {
     122    print "$f\n";
    113123}
    114124
Note: See TracChangeset for help on using the changeset viewer.