Skip to content

FindOpenSSL: Set version variables for version >= 3.0.0

James Calo requested to merge SagaraBattousai/cmake:FindOpenSSL3_applink into master

Set "OPENSSL_VERSION_MAJOR", "OPENSSL_VERSION_MINOR" and "OPENSSL_VERSION_FIX" to the correct values when using OpenSSL version >= 3.0.0 which uses a new format. The current code doesn't transfer these values to the aforementioned veriables. This causes issues with if statements that should pass later on but do not due to the absence of these variables.

Alternativly, changing the if statement on line 677 (previously line 670 before the changes) could use ${OPENSSL_VERSION} instead of {OPENSSL_VERSION_MAJOR}.{OPENSSL_VERSION_MINOR}.${OPENSSL_VERSION_FIX}.

It may be necessary to use "if guards" to check if each of the three variables are aready set. However, as it stands, that is not currently necessary.

Edited by Brad King

Merge request reports