diff options
author | Kenny Root <kroot@google.com> | 2010-08-26 10:13:11 -0700 |
---|---|---|
committer | Kenny Root <kroot@google.com> | 2010-08-27 16:40:06 -0700 |
commit | 85387d7ba36e56b291cbde87acb5a5b2200fe01c (patch) | |
tree | adea29b181a25c2ffd8ecaebded62fb4d2dc1a93 /core/java/android/app/LoadedApk.java | |
parent | 4f8c2f26bfd9de8c8a31369dbedd415c7d6d9699 (diff) | |
download | frameworks_base-85387d7ba36e56b291cbde87acb5a5b2200fe01c.zip frameworks_base-85387d7ba36e56b291cbde87acb5a5b2200fe01c.tar.gz frameworks_base-85387d7ba36e56b291cbde87acb5a5b2200fe01c.tar.bz2 |
Allow native shared libraries in ASEC containers
This change moves the native library handling earlier in the package
installation process so that it may be inserted into ASEC containers
before they are finalized in the DefaultContainerService.
Note that native libraries on SD card requires that vold mount ASEC
containers without the "noexec" flag on the mount point.
Change-Id: Ib34b1886bf6f94b99bb7b3781db6e9b5a58807ba
Diffstat (limited to 'core/java/android/app/LoadedApk.java')
-rw-r--r-- | core/java/android/app/LoadedApk.java | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/core/java/android/app/LoadedApk.java b/core/java/android/app/LoadedApk.java index 0f98152..0644f96 100644 --- a/core/java/android/app/LoadedApk.java +++ b/core/java/android/app/LoadedApk.java @@ -72,6 +72,7 @@ final class LoadedApk { private final String mResDir; private final String[] mSharedLibraries; private final String mDataDir; + private final String mLibDir; private final File mDataDirFile; private final ClassLoader mBaseClassLoader; private final boolean mSecurityViolation; @@ -108,6 +109,7 @@ final class LoadedApk { mSharedLibraries = aInfo.sharedLibraryFiles; mDataDir = aInfo.dataDir; mDataDirFile = mDataDir != null ? new File(mDataDir) : null; + mLibDir = aInfo.nativeLibraryDir; mBaseClassLoader = baseLoader; mSecurityViolation = securityViolation; mIncludeCode = includeCode; @@ -140,6 +142,7 @@ final class LoadedApk { mSharedLibraries = null; mDataDir = null; mDataDirFile = null; + mLibDir = null; mBaseClassLoader = null; mSecurityViolation = false; mIncludeCode = true; @@ -279,11 +282,12 @@ final class LoadedApk { * create the class loader. */ - if (ActivityThread.localLOGV) Slog.v(ActivityThread.TAG, "Class path: " + zip); + if (ActivityThread.localLOGV) + Slog.v(ActivityThread.TAG, "Class path: " + zip + ", JNI path: " + mLibDir); mClassLoader = ApplicationLoaders.getDefault().getClassLoader( - zip, mDataDir, mBaseClassLoader); + zip, mLibDir, mBaseClassLoader); initializeJavaContextClassLoader(); } else { if (mBaseClassLoader == null) { |