]> git.ipfire.org Git - thirdparty/openssl.git/commitdiff
Configure: update $apitable with the recent versions
authorEugene Syromiatnikov <esyr@openssl.org>
Sat, 16 May 2026 00:35:02 +0000 (02:35 +0200)
committerEugene Syromiatnikov <esyr@openssl.org>
Tue, 19 May 2026 09:33:43 +0000 (11:33 +0200)
Fill $apitable with all the major.minor.0 versions up to the current one
in development.  Note that while 3.5 hasn't had any APIs deprecated,
it still makes sense to support passing it as an "API level".

Resolves: https://github.com/openssl/openssl/issues/31196
Reported-by: Oliver Roberts <oliver@futaura.co.uk>
Signed-off-by: Eugene Syromiatnikov <esyr@openssl.org>
Reviewed-by: Richard Levitte <levitte@openssl.org>
Reviewed-by: Matt Caswell <matt@openssl.foundation>
MergeDate: Tue May 19 09:33:49 2026
(Merged from https://github.com/openssl/openssl/pull/31198)

Configure

index 4cd67bb41edf529aa15c67e11c4981104e7fdd63..11ee059dfbe06383f90913b53d8955db2bc4050f 100755 (executable)
--- a/Configure
+++ b/Configure
@@ -222,16 +222,9 @@ our $BSDthreads="-pthread -D_THREAD_SAFE -D_REENTRANT";
 #
 # API compatibility name to version number mapping.
 #
-my $apitable = {
-    # This table expresses when API additions or changes can occur.
-    # The numbering used changes from 3.0 and on because we updated
-    # (solidified) our version numbering scheme at that point.
-
-    # From 3.0 and on, we internalise the given version number in decimal
-    # as MAJOR * 10000 + MINOR * 100 + 0
-    "3.0.0" => 30000,
-    "3.0"   => 30000,
 
+# This table expresses when API additions or changes can occur
+my $apitable = {
     # Note that before 3.0, we didn't have the same version number scheme.
     # Still, the numbering we use here covers what we need.
     "1.1.1" => 10101,
@@ -242,6 +235,19 @@ my $apitable = {
     "0.9.8" =>   908,
 };
 
+# From 3.0 and on, we internalise the given version number in decimal
+# as MAJOR * 10000 + MINOR * 100 + 0
+my @post30_versions = ([3, 0], [3, 1], [3, 2], [3, 3], [3, 4], [3, 5], [3, 6],
+                       [4, 0], [4, 1],
+                       );
+
+# The numbering used changes from 3.0 and on because we updated
+# (solidified) our version numbering scheme at that point.
+foreach (@post30_versions) {
+    my ($x, $y) = @{$_};
+    $apitable->{"$x.$y.0"} = $apitable->{"$x.$y"} = $x * 10000 + $y * 100;
+}
+
 # For OpenSSL::config::get_platform
 my %guess_opts = ();