Lowercase configuration arguments on VMS
authorRichard Levitte <levitte@openssl.org>
Tue, 16 Feb 2016 15:07:05 +0000 (16:07 +0100)
committerRichard Levitte <levitte@openssl.org>
Tue, 16 Feb 2016 15:10:06 +0000 (16:10 +0100)
Depending on user preferences, Configure might get something like
--PREFIX=blah just as well as --prefix=blah, or "SHARED" just as well
as "shared".  On VMS, let's therefore lowercase at least the portion
of the argument before a possible equal sign.

For good measure, we lowercase the arguments to be checked in
config.com as well.  The original argument is sent on to Configure,
however.

Reviewed-by: Andy Polyakov <appro@openssl.org>
Configure
config.com

index 1077371a35517f1aa9f81a8a1a64c22739591336..9a4a9a9dd0dea1bdcc3bdef06f009fdbdad45bae 100755 (executable)
--- a/Configure
+++ b/Configure
@@ -501,6 +501,13 @@ $config{perlargv} = [ @argvcopy ];
 my %unsupported_options = ();
 foreach (@argvcopy)
        {
+       # VMS is a case insensitive environment, and depending on settings
+       # out of our control, we may receive options uppercased.  Let's
+       # downcase at least the part before any equal sign.
+       if ($^O eq "VMS")
+               {
+               s/^([^=]*)/lc($1)/e;
+               }
        s /^-no-/no-/; # some people just can't read the instructions
 
        # rewrite some options in "enable-..." form
index 1beb74a2582e377cb821fcd45f8a9425d3d82477..b43acfaac4be713bf48569a8770e0ae04ff5a509 100644 (file)
@@ -17,24 +17,24 @@ $   P_index = 0
 $      LOOP1:
 $          P_index = P_index + 1
 $          IF P_index .GT. 8 THEN GOTO ENDLOOP1
-$          P1 = F$EDIT(P1,"TRIM")
-$          IF P1 .EQS. "HELP" THEN GOTO USAGE
-$          IF P1 .EQS. "32"
+$          P = F$EDIT(P1,"TRIM,LOWERCASE")
+$          IF P .EQS. "help" THEN GOTO USAGE
+$          IF P .EQS. "32"
 $          THEN
 $              pointer_size = "-P32"
-$              P1 = ""
+$              P = ""
 $          ENDIF
-$          IF P1 .EQS. "64"
+$          IF P .EQS. "64"
 $          THEN
 $              pointer_size = "-P64"
-$              P1 = ""
+$              P = ""
 $          ENDIF
-$          IF P1 .EQS. "DEBUG"
+$          IF P .EQS. "debug"
 $          THEN
 $              debug = "--debug"
-$              P1 = ""
+$              P = ""
 $          ENDIF
-$          IF P1 .NES. "" THEN -
+$          IF P .NES. "" THEN -
               collected_args = collected_args + " " + P1
 $          P1 = P2
 $          P2 = P3