don't display the "Image configuration" menu entry when there's nothing to pre-config...
authorNicolas Thill <nico@openwrt.org>
Fri, 22 Aug 2008 04:18:35 +0000 (04:18 +0000)
committerNicolas Thill <nico@openwrt.org>
Fri, 22 Aug 2008 04:18:35 +0000 (04:18 +0000)
SVN-Revision: 12366

scripts/metadata.pl

index d920f59..ce80924 100755 (executable)
@@ -472,7 +472,7 @@ sub print_package_config_category($) {
 
 sub gen_package_config() {
        parse_package_metadata($ARGV[0]) or exit 1;
-       print "menuconfig UCI_PRECONFIG\n\tbool \"Image configuration\"\n";
+       print "menuconfig UCI_PRECONFIG\n\tbool \"Image configuration\"\n" if %preconfig;
        foreach my $preconfig (keys %preconfig) {
                foreach my $cfg (keys %{$preconfig{$preconfig}}) {
                        my $conf = $preconfig{$preconfig}->{$cfg}->{id};