2 #***************************************************************************
4 # Project ___| | | | _ \| |
6 # | (__| |_| | _ <| |___
7 # \___|\___/|_| \_\_____|
9 # Copyright (C) Daniel Stenberg, <daniel@haxx.se>, et al.
11 # This software is licensed as described in the file COPYING, which
12 # you should have received as part of this distribution. The terms
13 # are also available at https://curl.se/docs/copyright.html.
15 # You may opt to use, copy, modify, merge, publish, distribute and/or sell
16 # copies of the Software, and permit persons to whom the Software is
17 # furnished to do so, under the terms of the COPYING file.
19 # This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY
20 # KIND, either express or implied.
22 # SPDX-License-Identifier: curl
24 ###########################################################################
31 # we may get the dir root pointed out
32 my $root=$ARGV[0] || ".";
34 my %error; # from the include file
35 my %docs; # from libcurl-errors.3
38 open(my $f, "<", "$root/docs/libcurl/libcurl-errors.3");
40 if($_ =~ /^.IP \"(CURL[EM]_[^ \t\"]*)/) {
42 if($symbol =~ /OBSOLETE/) {
53 sub getincludeerrors {
54 open(my $f, "<", "$root/docs/libcurl/symbols-in-versions");
56 if($_ =~ /^(CURL[EM]_[^ \t]*)[ \t]*([0-9.]+)[ \t]*(.*)/) {
57 my ($symbol, $added, $rest) = ($1,$2,$3);
58 if($rest =~ /^([0-9.]+)/) {
62 $error{$symbol}=$added;
72 for(sort keys %error) {
73 if($error{$_} && !$docs{$_}) {
74 print "$_ is not in libcurl-errors.3\n";
78 for(sort keys %docs) {
79 if($docs{$_} && !$error{$_}) {
80 print "$_ is not in symbols-in-versions\n";