Fix native-lib dir assignment & updating

The per-package /system/lib/* feature introduced bugs in the
native library path handling during app upgrade installs.  The
crux of the fix is that when recalulating the desired native
library directory, the basis for the calculation needs to be
the scanned APK's location rather than the extant package
settings entry -- because that entry refers to the pre-upgrade
state of the application, not the new state.

Bug 14233983

(cherry picked from commit 353e39a973dbbadce82fee2f83ad194e04a47449)

Change-Id: I26f17a596ca2cd7f963955c0642548c15138ae26
1 file changed