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",
36 if (open(my $fh, $fn)) {
42 die "$0: Failed to open '$fn' for reading: $!\n";
46 sub config_h_SH_reader {
49 return if 1../^echo \"Extracting \$CONFIG_H/;
50 while (/[^\\]\$(\w+)/g) {
52 next if $v =~ /^(CONFIG_H|CONFIG_SH)$/;
58 read_file($MASTER_CFG,
59 config_h_SH_reader(\%MASTER_CFG));
65 $MANIFEST{$1}++ if /^(.+?)\t/;
68 my @MASTER_CFG = sort keys %MASTER_CFG;
72 for my $v (@MASTER_CFG) {
73 print "$fn: missing '$v'\n" unless exists $cfg->{$v};
78 unless (exists $MANIFEST{$cfg}) {
79 print "[skipping not-expected '$cfg']\n";
85 return if /^\#/ || /^\s*$/;
88 # $foo='bar' # VOS 5.8.x specialty
89 # $foo=bar # VOS 5.8.x specialty
90 if (/^\$?(\w+)='(.*)'$/) {
93 elsif (/^\$?(\w+)=(.*)$/) {
99 check_cfg($cfg, \%cfg);