PackageManager: Restrict system packages to protected storage

Don't allow packages signed with the platform key to be
installed into user (or app) controlled storage

Change-Id: I7390b3bdf5289411f7a335c69635bed9f74bbfb3
Add support for allow-permission extension.
This will grant a sharedUserId arbitrary permissions as defined by XML files
in /system/etc/permissions.

Change-Id: I4c0be56173b89621c4cc7ae589715a030931e8d5
PackageManager: allow build-time disabling of components

Allow components to be specified as disabled at build time
(applied on boot).

This allows stock OTA components to be marked as disabled in
CM builds.

Change-Id: I6e4499cc40a779792a5ea97a10137399dad7d69f
Updating ActivityIntentResolver so that queryIntents doesn't return protected applications.

Any calls from System UID(1000) are not filtered

Change-Id: I037cddaf91b6943b8cc837c5b046cf320c4caa5f
RE: CM11 Themes: Common overlay for sharing resources. [1/2]

This patch will allow themes to contain common resources
which can be shared by all overlays.

Common resources will reside in assets/overlays/common and
can be referenced by other overlays.

Common resources will be referenced using the common package
name, i.e. To reference the common drawable some_drawable for
com.example.theme the theme designer would use
"@*common:drawable/some_drawable"

Change-Id: I395b6bd5eae91b00265a8e9221856ef7bf5d115a

Conflicts:
	core/java/android/app/ResourcesManager.java
	core/java/android/content/pm/ThemeUtils.java
	core/java/android/content/res/AssetManager.java
	services/java/com/android/server/pm/Installer.java
	services/java/com/android/server/pm/PackageManagerService.java
RE: Cleanup themes that fail to install

Themes which fail to install due to aapt or idmap errors
would not be properly cleaned up. This caused subsequent installs
to give a INSTALL_FAILED_UID_CHANGED (-24) error.

This patch also adds install error codes specifically for themes.

Change-Id: Ie03b92ca0a7dec8c4a5e3725b717943d36abb349

Conflicts:
	services/java/com/android/server/pm/PackageManagerService.java
CM11 Themes: Add themeChange config change to manifest

Change-Id: Ia84c0089a79637906e4f75fa38a56e8ff3b21a2b

Conflicts:
	core/res/res/values/attrs_manifest.xml
Merge tag 'android-4.4.4_r1' into kk-4.4

Android 4.4.4 Release 1

Author: cphelps76