aboutsummaryrefslogtreecommitdiffstats
path: root/scripts/gen_deps.pl
diff options
context:
space:
mode:
authorFelix Fietkau <nbd@openwrt.org>2006-10-17 19:01:08 +0000
committerFelix Fietkau <nbd@openwrt.org>2006-10-17 19:01:08 +0000
commit00becd7842aa53f3fccf59527d68003bd25b9040 (patch)
treecd076dd1b34416689de1e65934a7f94c59aa937b /scripts/gen_deps.pl
parentbed6afa8df27eaed53d35fd0eae9f16ec745eb27 (diff)
downloadupstream-00becd7842aa53f3fccf59527d68003bd25b9040.tar.gz
upstream-00becd7842aa53f3fccf59527d68003bd25b9040.tar.bz2
upstream-00becd7842aa53f3fccf59527d68003bd25b9040.zip
add PROVIDES option, currently only used for menuconfig
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@5194 3c298f89-4303-0410-b956-a3cf2f4a3e73
Diffstat (limited to 'scripts/gen_deps.pl')
-rwxr-xr-xscripts/gen_deps.pl8
1 files changed, 8 insertions, 0 deletions
diff --git a/scripts/gen_deps.pl b/scripts/gen_deps.pl
index 745d31c7d0..af206f0047 100755
--- a/scripts/gen_deps.pl
+++ b/scripts/gen_deps.pl
@@ -34,6 +34,12 @@ while ($line = <>) {
defined $pkg{$name} or $pkg{$name} = {};
$pkg{$name}->{src} = $src;
};
+ $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;
};
@@ -52,6 +58,7 @@ $line="";
foreach $name (sort {uc($a) cmp uc($b)} keys %pkg) {
my $config;
+ next if defined $pkg{$name}->{virtual};
if ($options{SDK}) {
$conf{$pkg{$name}->{src}} or do {
$config = 'm';
@@ -69,6 +76,7 @@ foreach $name (sort {uc($a) cmp uc($b)} keys %pkg) {
my $depline = "";
foreach my $dep (@{$pkg{$name}->{depends}}) {
my $idx;
+ next if defined $pkg{$dep}->{virtual};
if (defined $pkg{$dep}->{src}) {
($pkg{$name}->{src} ne $pkg{$dep}->{src}) and $idx = $pkg{$dep}->{src};
} elsif (defined($pkg{$dep}) && !$options{SDK}) {