diff options
author | Marco d'Itri <md@linux.it> | 2019-06-23 15:54:27 +0200 |
---|---|---|
committer | Marco d'Itri <md@linux.it> | 2019-06-28 01:44:58 +0200 |
commit | bfc8c6bf9ccb6c43f3ef46d218c9cf0f9a85319a (patch) | |
tree | 6703e79730418d4f07e9b81d94822ac669ea78c4 | |
parent | 9bdb9bc7b6c2770fbd46d1d26b04ed1369c1859f (diff) | |
download | whois-bfc8c6bf9ccb6c43f3ef46d218c9cf0f9a85319a.tar.gz |
Automatically generate the IDSTRING
-rwxr-xr-x | make_version_h.pl | 5 | ||||
-rw-r--r-- | whois.h | 4 |
2 files changed, 5 insertions, 4 deletions
diff --git a/make_version_h.pl b/make_version_h.pl index 06c7841..51a8f76 100755 --- a/make_version_h.pl +++ b/make_version_h.pl @@ -17,8 +17,13 @@ $ver =~ s/ ( ~bpo\d+\+\d+ | \+b\d+ | ~deb\d+.* | ubuntu\d+ | \+dyson\d+ ) $//x; # The version number must not deviate from this format or the -V option # to RIPE-like servers will break. If needed, update the previous regexp. +# This may not be true anymore in 2019. die "Invalid version number in $changelog!\n" unless $ver =~ /^ \d+\.\d+ ( \.\d+ )? $/x; +# This is the version number used in the help messages. print qq|#define VERSION "$ver"\n|; +# This is the string sent to RIPE-like servers as the argument of -V. +print qq|#define IDSTRING "Md$ver"\n|; + @@ -3,10 +3,6 @@ /* 6bone referto: extension */ #define REFERTO_FORMAT "%% referto: whois -h %255s -p %15s %1021[^\n\r]" -/* String sent to RIPE servers - MUST NOT BE LONGER THAN FIVE CHARACTERS! */ -/* Do *NOT* change it if you don't know what you are doing! */ -#define IDSTRING "Md5.2" - #define HIDE_TO_THE_END -3 #define HIDE_DISABLED -2 #define HIDE_NOT_STARTED -1 |