diff options
author | Narayan Kamath <narayan@google.com> | 2014-07-28 18:18:26 +0100 |
---|---|---|
committer | Narayan Kamath <narayan@google.com> | 2014-07-29 09:33:02 +0000 |
commit | 43327a61eb57839429fbb064f4166a858788779c (patch) | |
tree | 7c49e3742b0c36ab60e3473e5786b8649ec407cd /services | |
parent | 73f1856f7f224dce9670b57707f65f805bb0f6b3 (diff) | |
download | frameworks_base-43327a61eb57839429fbb064f4166a858788779c.zip frameworks_base-43327a61eb57839429fbb064f4166a858788779c.tar.gz frameworks_base-43327a61eb57839429fbb064f4166a858788779c.tar.bz2 |
Fix regression in renderscript detection.
We must persist the selected (32 bit) ABI for legacy
renderscript apps so that we can launch them correctly.
bug: 16569287
Change-Id: I944acd0cf56ddb1f27337e01bca1b24cd369eb8f
Diffstat (limited to 'services')
-rw-r--r-- | services/core/java/com/android/server/pm/PackageManagerService.java | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/services/core/java/com/android/server/pm/PackageManagerService.java b/services/core/java/com/android/server/pm/PackageManagerService.java index 68ae6ff..ee6d4d0 100644 --- a/services/core/java/com/android/server/pm/PackageManagerService.java +++ b/services/core/java/com/android/server/pm/PackageManagerService.java @@ -5486,9 +5486,11 @@ public class PackageManagerService extends IPackageManager.Stub { // SDK tools. We must scan their APKs for renderscript bitcode and // not launch them if it's present. Don't bother checking on devices // that don't have 64 bit support. + boolean needsRenderScriptOverride = false; if (Build.SUPPORTED_64_BIT_ABIS.length > 0 && abiOverride == null && NativeLibraryHelper.hasRenderscriptBitcode(handle)) { abiList = Build.SUPPORTED_32_BIT_ABIS; + needsRenderScriptOverride = true; } final int copyRet; @@ -5508,6 +5510,8 @@ public class PackageManagerService extends IPackageManager.Stub { pkg.applicationInfo.primaryCpuAbi = abiList[copyRet]; } else if (copyRet == PackageManager.NO_NATIVE_LIBRARIES && abiOverride != null) { pkg.applicationInfo.primaryCpuAbi = abiOverride; + } else if (needsRenderScriptOverride) { + pkg.applicationInfo.primaryCpuAbi = abiList[0]; } } } catch (IOException ioe) { |