- $line =~ /^Depends: \s*(.+)\s*$/ and do {
- my @dep = split /,\s*/, $1;
- $pkg{$name}->{depends} = \@dep;
+ $line =~ /^Provides: \s*(.+)\s*$/ and do {
+ foreach my $vpkg (split /\s+/, $1) {
+ defined $pkg{$vpkg} or $pkg{$vpkg} = {};
+ $pkg{$vpkg}->{virtual} = 1;
+ }
+ };
+ $line =~ /^Prereq-Check:/ and !defined $prereq{$src} and do {
+ $pkg{$name}->{prereq} = 1;
+ };
+ $line =~ /^(Build-)?Depends: \s*(.+)\s*$/ and do {
+ $pkg{$name}->{depends} ||= [];
+ foreach my $v (split /\s+/, $2) {
+ next if $v =~ /^[\+]?@/;
+ $v =~ s/^\+//;
+ push @{$pkg{$name}->{depends}}, $v;
+ }