Ensure libssl uses the new library context aware CT code
[openssl.git] / Configurations / 15-android.conf
index 7b496a4529bd3072663fa08515125711d8bf81a7..d3b2ff6a1c4c559767799de5e3b402c70d8c8a56 100644 (file)
 
             my $ndk_var;
             my $ndk;
-            foreach (qw(ANDROID_NDK_HOME ANDROID_NDK)) {
+            foreach (qw(ANDROID_NDK_ROOT ANDROID_NDK)) {
                 $ndk_var = $_;
                 $ndk = $ENV{$ndk_var};
                 last if defined $ndk;
             }
-            die "\$ANDROID_NDK_HOME is not defined"  if (!$ndk);
+            die "\$ANDROID_NDK_ROOT is not defined"  if (!$ndk);
             if (!-d "$ndk/platforms" && !-f "$ndk/AndroidVersion.txt") {
                 # $ndk/platforms is traditional "all-inclusive" NDK, while
                 # $ndk/AndroidVersion.txt is so-called standalone toolchain
                 # tailored for specific target down to API level.
-                die "\$ANDROID_NDK_HOME=$ndk is invalid";
+                die "\$ANDROID_NDK_ROOT=$ndk is invalid";
             }
             $ndk = canonpath($ndk);
 
@@ -168,7 +168,8 @@ my %targets = (
         cppflags         => add(sub { android_ndk()->{cppflags} }),
         cxxflags         => add(sub { android_ndk()->{cflags} }),
         bn_ops           => sub { android_ndk()->{bn_ops} },
-        bin_cflags       => "-pie",
+        bin_cflags       => "-fPIE",
+        bin_lflags       => "-pie",
         enable           => [ ],
     },
     "android-arm" => {
@@ -199,18 +200,22 @@ my %targets = (
         # -march and/or -mfloat-abi flags. NDK defaults to armv5te.
         # Newer NDK versions reportedly require additional -latomic.
         #
-        inherit_from     => [ "android", asm("armv4_asm") ],
+        inherit_from     => [ "android" ],
         bn_ops           => add("RC4_CHAR"),
+        asm_arch         => 'armv4',
+        perlasm_scheme   => "void",
     },
     "android-arm64" => {
-        inherit_from     => [ "android", asm("aarch64_asm") ],
+        inherit_from     => [ "android" ],
         bn_ops           => add("RC4_CHAR"),
+        asm_arch         => 'aarch64',
         perlasm_scheme   => "linux64",
     },
 
     "android-mips" => {
-        inherit_from     => [ "android", asm("mips32_asm") ],
+        inherit_from     => [ "android" ],
         bn_ops           => add("RC4_CHAR"),
+        asm_arch         => 'mips32',
         perlasm_scheme   => "o32",
     },
     "android-mips64" => {
@@ -223,25 +228,28 @@ my %targets = (
         # with previous MIPS ISA versions, in sense that unlike
         # prior versions original MIPS binary code will fail.
         #
-        inherit_from     => [ "android", asm("mips64_asm") ],
+        inherit_from     => [ "android" ],
         bn_ops           => add("RC4_CHAR"),
+        asm_arch         => 'mips64',
         perlasm_scheme   => "64",
     },
 
     "android-x86" => {
-        inherit_from     => [ "android", asm("x86_asm") ],
+        inherit_from     => [ "android" ],
         CFLAGS           => add(picker(release => "-fomit-frame-pointer")),
         bn_ops           => add("RC4_INT"),
+        asm_arch         => 'x86',
         perlasm_scheme   => "android",
     },
     "android-x86_64" => {
-        inherit_from     => [ "android", asm("x86_64_asm") ],
+        inherit_from     => [ "android" ],
         bn_ops           => add("RC4_INT"),
+        asm_arch         => 'x86_64',
         perlasm_scheme   => "elf",
     },
 
     ####################################################################
-    # Backward compatible targets, (might) requre $CROSS_SYSROOT
+    # Backward compatible targets, (might) require $CROSS_SYSROOT
     #
     "android-armeabi" => {
         inherit_from     => [ "android-arm" ],