Fail the Configure script with no Configurations
authorWill Sackfield <will.sackfield@gmail.com>
Wed, 29 Nov 2023 00:57:49 +0000 (19:57 -0500)
committerTomas Mraz <tomas@openssl.org>
Mon, 8 Jan 2024 13:17:16 +0000 (14:17 +0100)
* Print a message about why the failure is
happening.
* Send the usage information.

Reviewed-by: Richard Levitte <levitte@openssl.org>
Reviewed-by: Matt Caswell <matt@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/22855)

Configure

index cca1ac8d162ee448778411a30b37cdba5c3397fa..846a427cff8a17837fdd0de438cac361b760ff03 100755 (executable)
--- a/Configure
+++ b/Configure
@@ -385,6 +385,12 @@ if (defined env($local_config_envname)) {
     }
 }
 
+# Fail if no configuration is apparent
+if (!%table) {
+    print "Failed to find any os/compiler configurations. Please make sure the Configurations directory is included.\n";
+    &usage;
+}
+
 # Save away perl command information
 $config{perl_cmd} = $^X;
 $config{perl_version} = $Config{version};