Revert "Add OPENSSL_VERSION_AT_LEAST"
authorDr. Matthias St. Pierre <Matthias.St.Pierre@ncp-e.com>
Mon, 16 Apr 2018 13:19:14 +0000 (15:19 +0200)
committerDr. Matthias St. Pierre <Matthias.St.Pierre@ncp-e.com>
Mon, 16 Apr 2018 16:44:37 +0000 (18:44 +0200)
Fixes #5961

This reverts commit d8adfdcd2e5de23f3e1d1a1d10c2fda6f4a65c4a.

The macros OPENSSL_MAKE_VERSION() and OPENSSL_VERSION_AT_LEAST() contain
errors and don't work as designed. Apart from that, their introduction
should be held back until a decision has been mad about the future
versioning scheme.

Reviewed-by: Rich Salz <rsalz@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/5968)

doc/crypto/OPENSSL_VERSION_NUMBER.pod
doc/ssl/ssl.pod
include/openssl/opensslv.h

index f50faec772d5428073422c88800994f5450ff146..f5429d217e524f8f424fc2c16be23418da39b54e 100644 (file)
@@ -47,11 +47,6 @@ number was therefore 0x0090581f.
 
 OpenSSL_version_num() returns the version number.
 
-The macro OPENSSL_VERSION_AT_LEAST(major,minor) can be used at compile
-time test if the current version is at least as new as the version provided.
-The arguments major, minor and fix correspond to the version information
-as given above.
-
 OpenSSL_version() returns different strings depending on B<t>:
 
 =over 4
index 4d919072ea38ed6b1095659cfffa4d408d4153c2..7307a2b584e120a175407da313ecbc42767ba821 100644 (file)
@@ -91,12 +91,6 @@ includes both more private SSL headers and headers from the B<crypto> library.
 Whenever you need hard-core details on the internals of the SSL API, look
 inside this header file.
 
-OPENSSL_VERSION_AT_LEAST(major,minor) can be
-used in C<#if> statements in order to determine which version of the library is
-being used. This can be used to either enable optional features at compile
-time, or work around issues with a previous version.
-See L<OPENSSL_VERSION_NUMBER(3)>.
-
 =item B<ssl2.h>
 
 Unused. Present for backwards compatibility only.
index 3532521f15d609f5415c4ca1828dd25e91b07e31..7221a45e2f27dfe96bd363235cdf9a4e3c61296e 100644 (file)
@@ -46,11 +46,6 @@ extern "C" {
 #  define OPENSSL_VERSION_TEXT    "OpenSSL 1.1.0i-dev  xx XXX xxxx"
 # endif
 
-#define OPENSSL_MAKE_VERSION(maj,min,fix,patch) ((0x10000000L)+((maj&0xff)<<20)+((min&0xff)<<12)+((fix&0xff)<<4)+patch)
-
-/* use this for #if tests, should never depend upon fix/patch */
-#define OPENSSL_VERSION_AT_LEAST(maj,min) (OPENSSL_MAKE_VERSION(maj,min, 0, 0) >= OPENSSL_VERSION_NUMBER)
-
 /*-
  * The macros below are to be used for shared library (.so, .dll, ...)
  * versioning.  That kind of versioning works a bit differently between