summaryrefslogtreecommitdiffstats
path: root/scripts
diff options
context:
space:
mode:
Diffstat (limited to 'scripts')
-rwxr-xr-xscripts/gen_deps.pl8
1 files changed, 7 insertions, 1 deletions
diff --git a/scripts/gen_deps.pl b/scripts/gen_deps.pl
index 70c07b70a..e7daf1886 100755
--- a/scripts/gen_deps.pl
+++ b/scripts/gen_deps.pl
@@ -13,6 +13,8 @@ my $src;
my $makefile;
my %conf;
my %pkg;
+my %prereq;
+my $prereq;
my %dep;
my %options;
my $opt;
@@ -33,6 +35,10 @@ while ($line = <>) {
defined $pkg{$name} or $pkg{$name} = {};
$pkg{$name}->{src} = $src;
};
+ $line =~ /^Prereq-Check:/ and !defined $prereq{$src} and do {
+ $prereq{$src} = 1;
+ $prereq .= "package-prereq += $src\n";
+ };
$line =~ /^(Build-)?Depends: \s*(.+)\s*$/ and do {
$pkg{$name}->{depends} ||= [];
foreach my $v (split /\s+/, $2) {
@@ -75,5 +81,5 @@ foreach $name (sort {uc($a) cmp uc($b)} keys %pkg) {
}
if ($line ne "") {
- print "\n$line";
+ print "\n$line\n$prereq";
}