am 2e86809b: Merge "Native libraries on SD" into gingerbread

Merge commit '2e86809b6c79375d23c0975914efc3b66e89ac90' into gingerbread-plus-aosp

* commit '2e86809b6c79375d23c0975914efc3b66e89ac90':
  Native libraries on SD
This commit is contained in:
Kenny Root
2010-08-30 15:21:17 -07:00
committed by Android Git Automerger
2 changed files with 3 additions and 0 deletions

View File

@@ -1392,8 +1392,10 @@ public class PackageManagerTests extends AndroidTestCase {
assertNotNull(info);
if ((moveFlags & PackageManager.MOVE_INTERNAL) != 0) {
assertTrue((info.flags & ApplicationInfo.FLAG_EXTERNAL_STORAGE) == 0);
assertTrue(info.nativeLibraryDir.startsWith(info.dataDir));
} else if ((moveFlags & PackageManager.MOVE_EXTERNAL_MEDIA) != 0){
assertTrue((info.flags & ApplicationInfo.FLAG_EXTERNAL_STORAGE) != 0);
assertTrue(info.nativeLibraryDir.startsWith(SECURE_CONTAINERS_PREFIX));
}
}
} catch (NameNotFoundException e) {

View File

@@ -9833,6 +9833,7 @@ class PackageManagerService extends IPackageManager.Stub {
ps.codePathString = ps.codePath.getPath();
ps.resourcePath = new File(pkg.applicationInfo.publicSourceDir);
ps.resourcePathString = ps.resourcePath.getPath();
ps.nativeLibraryPathString = newNativePath;
// Set the application info flag correctly.
if ((mp.flags & PackageManager.INSTALL_EXTERNAL) != 0) {
pkg.applicationInfo.flags |= ApplicationInfo.FLAG_EXTERNAL_STORAGE;