diff options
author | Daniel Stenberg <daniel@haxx.se> | 2021-04-15 12:11:41 +0200 |
---|---|---|
committer | Daniel Stenberg <daniel@haxx.se> | 2021-04-22 23:19:47 +0200 |
commit | 4708f29f1c01a33e3808db5b8adfa4cd596d8067 (patch) | |
tree | 08515a36fa800baecca3bd86770f85dc58bec039 /tests/disable-scan.pl | |
parent | 54e747501626b81149b1b44949119d365db82004 (diff) | |
download | curl-4708f29f1c01a33e3808db5b8adfa4cd596d8067.tar.gz |
tests/disable-scan.pl: also scan all m4 files
Fixes test 1165 when functions are moved from configure.ac to files in
m4/
Diffstat (limited to 'tests/disable-scan.pl')
-rwxr-xr-x | tests/disable-scan.pl | 16 |
1 files changed, 14 insertions, 2 deletions
diff --git a/tests/disable-scan.pl b/tests/disable-scan.pl index 64a181aca..65f5b03cb 100755 --- a/tests/disable-scan.pl +++ b/tests/disable-scan.pl @@ -36,8 +36,9 @@ my %docs; my $root=$ARGV[0] || "."; my $DOCS="CURL-DISABLE.md"; -sub scan_configure { - open S, "<$root/configure.ac"; +sub scanconf { + my ($f)=@_; + open S, "<$f"; while(<S>) { if(/(CURL_DISABLE_[A-Z_]+)/g) { my ($sym)=($1); @@ -47,6 +48,17 @@ sub scan_configure { close S; } +sub scan_configure { + opendir(my $m, "$root/m4") || die "Can't opendir $root/m4: $!"; + my @m4 = grep { /\.m4$/ } readdir($m); + closedir $m; + scanconf("$root/configure.ac"); + # scan all m4 files too + for my $e (@m4) { + scanconf("$root/m4/$e"); + } +} + sub scan_file { my ($source)=@_; open F, "<$source"; |