4 # Check that the various config.sh-clones have (at least) all the
5 # same symbols as the top-level config_h.SH so that the (potentially)
6 # needed symbols are not lagging after how Configure thinks the world
9 # VMS is not handled here, due to their own rather elaborate DCL scripting.
14 my $MASTER_CFG = "config_h.SH";
18 # This list contains both 5.8.x and 5.9.x files,
19 # we check from MANIFEST whether they are expected to be present.
20 "Cross/config.sh-arm-linux",
25 "plan9/config_sh.sample",
26 "vos/config.alpha.def",
37 if (open(my $fh, $fn)) {
43 die "$0: Failed to open '$fn' for reading: $!\n";
47 sub config_h_SH_reader {
50 return if 1../^echo \"Extracting \$CONFIG_H/;
51 while (/[^\\]\$(\w+)/g) {
53 next if $v =~ /^(CONFIG_H|CONFIG_SH)$/;
59 read_file($MASTER_CFG,
60 config_h_SH_reader(\%MASTER_CFG));
66 $MANIFEST{$1}++ if /^(.+?)\t/;
69 my @MASTER_CFG = sort keys %MASTER_CFG;
73 for my $v (@MASTER_CFG) {
74 print "$fn: missing '$v'\n" unless exists $cfg->{$v};
79 unless (exists $MANIFEST{$cfg}) {
80 print "[skipping not-expected '$cfg']\n";
86 return if /^\#/ || /^\s*$/;
89 # $foo='bar' # VOS 5.8.x specialty
90 # $foo=bar # VOS 5.8.x specialty
91 if (/^\$?(\w+)='(.*)'$/) {
94 elsif (/^\$?(\w+)=(.*)$/) {
100 check_cfg($cfg, \%cfg);