Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

What is the original-package AndroidManifest attribute used for?

I used apktool to extract the manifest of the default browser on Jelly Bean and this line appeared in the manifest--

  <manifest ... package="com.google.android.browser">
    <original-package android:name="com.android.browser" />
    ...
  </manifest>

Any idea what this is used for? The

like image 267
Matthew Avatar asked Aug 22 '12 02:08

Matthew


1 Answers

Check out attrs_manifest.xml in android/platform_frameworks_base source:

<!-- Private tag to declare the original package name that this package is
     based on.  Only used for packages installed in the system image.  If
     given, and different than the actual package name, and the given
     original package was previously installed on the device but the new
     one was not, then the data for the old one will be renamed to be
     for the new package.

     <p>This appears as a child tag of the root
     {@link #AndroidManifest manifest} tag. -->
<declare-styleable name="AndroidManifestOriginalPackage" parent="AndroidManifest">
    <attr name="name" />
</declare-styleable>

The comments should answer your question.

like image 155
yorkw Avatar answered Oct 19 '22 01:10

yorkw