<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: How to pack and pre-install a Prebuilt APK? in i.MX Processors</title>
    <link>https://community.nxp.com/t5/i-MX-Processors/How-to-pack-and-pre-install-a-Prebuilt-APK/m-p/1409379#M186664</link>
    <description>&lt;P&gt;Hi&lt;/P&gt;&lt;P&gt;We were also facing the same. When we looked into the frameworks side&amp;nbsp;there are some changes which prevents installing the apps from /data/app, (// If we don't allow this change, any newer,&lt;BR /&gt;// user-installed version of the application will be ignored.)&lt;/P&gt;&lt;P&gt;file name:&amp;nbsp;services/core/java/com/android/server/pm/PackageManagerService.java&lt;/P&gt;&lt;P&gt;else {&lt;BR /&gt;12221 throw new PackageManagerException(INSTALL_FAILED_INVALID_INSTALL_LOCATION,&lt;BR /&gt;12222 "Application package " + pkg.packageName&lt;BR /&gt;12223 + " not found; ignoring.");&lt;BR /&gt;12224 }&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;we can try neglect this part and try installing the data apps&lt;/P&gt;</description>
    <pubDate>Mon, 07 Feb 2022 04:22:50 GMT</pubDate>
    <dc:creator>skrishnan08</dc:creator>
    <dc:date>2022-02-07T04:22:50Z</dc:date>
    <item>
      <title>How to pack and pre-install a Prebuilt APK?</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/How-to-pack-and-pre-install-a-Prebuilt-APK/m-p/298971#M37437</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi All,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; Our project is based on Andorid ICS(i.MX6 Solo). All hardware/software development is almost done and now we are preparing to finalize the firmware image for mp.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; However, we are stuck in packing and pre-installing a Prebuilt APK which is provided by a software partner. After making whole BSP, we can see the APK file is existing in /myandroid/out/target/product/sabresd_6dq/data/app folder, but NOT in the installed-files.txt, neither in the system.img.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; Below is the content of the Android.mk:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;LOCAL_PATH := $(call my-dir)&lt;/P&gt;&lt;P&gt;include $(CLEAR_VARS)&lt;/P&gt;&lt;P&gt;LOCAL_MODULE := myAPP&lt;/P&gt;&lt;P&gt;LOCAL_SRC_FILES := $(LOCAL_MODULE).apk&lt;/P&gt;&lt;P&gt;LOCAL_MODULE_SUFFIX := $(COMMON_ANDROID_PACKAGE_SUFFIX)&lt;/P&gt;&lt;P&gt;LOCAL_MODULE_CLASS := APPS&lt;/P&gt;&lt;P&gt;LOCAL_CERTIFICATE := PRESIGNED&lt;/P&gt;&lt;P&gt;#LOCAL_MODULE_PATH := $(TARGET_OUT)/app&lt;/P&gt;&lt;P&gt;LOCAL_MODULE_PATH := $(TARGET_OUT_DATA_APPS)&lt;/P&gt;&lt;P&gt;LOCAL_MODULE_TAGS := optional&lt;/P&gt;&lt;P&gt;include $(BUILD_PREBUILT)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; And we have added below into /myandroid/devices/fsl/imx6/imx6.mk:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;PRODUCT_PACKAGES += \&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; myAPP&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; The same APK file can be manually installed after enabling Android setup-&amp;gt;security-&amp;gt;unknown source, not sure if we should enable this feature by default, if so, how can we do it in Android BSP? &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; And due to the privilege reason, we cannot put the APK into /system/app level. All opinions and comments are more than welcome. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; BTW, we are going to apply the same on another product line which is based on Andorid 4.3 (i.MX6 Sololite), please also kind advise us if the configuration is different for ICS and JB! &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; Thanks in advance!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;-tftu&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 19 Mar 2014 07:17:32 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/How-to-pack-and-pre-install-a-Prebuilt-APK/m-p/298971#M37437</guid>
      <dc:creator>tftu</dc:creator>
      <dc:date>2014-03-19T07:17:32Z</dc:date>
    </item>
    <item>
      <title>Re: How to pack and pre-install a Prebuilt APK?</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/How-to-pack-and-pre-install-a-Prebuilt-APK/m-p/298972#M37438</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Still looking for the solution, anybody?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;-tftu&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 13 May 2014 07:02:33 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/How-to-pack-and-pre-install-a-Prebuilt-APK/m-p/298972#M37438</guid>
      <dc:creator>tftu</dc:creator>
      <dc:date>2014-05-13T07:02:33Z</dc:date>
    </item>
    <item>
      <title>Re: How to pack and pre-install a Prebuilt APK?</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/How-to-pack-and-pre-install-a-Prebuilt-APK/m-p/298973#M37439</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I have same problem, anybody can help on this?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Tony Lee&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 24 Jan 2018 07:07:26 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/How-to-pack-and-pre-install-a-Prebuilt-APK/m-p/298973#M37439</guid>
      <dc:creator>tony2_lee</dc:creator>
      <dc:date>2018-01-24T07:07:26Z</dc:date>
    </item>
    <item>
      <title>Re: How to pack and pre-install a Prebuilt APK?</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/How-to-pack-and-pre-install-a-Prebuilt-APK/m-p/1409379#M186664</link>
      <description>&lt;P&gt;Hi&lt;/P&gt;&lt;P&gt;We were also facing the same. When we looked into the frameworks side&amp;nbsp;there are some changes which prevents installing the apps from /data/app, (// If we don't allow this change, any newer,&lt;BR /&gt;// user-installed version of the application will be ignored.)&lt;/P&gt;&lt;P&gt;file name:&amp;nbsp;services/core/java/com/android/server/pm/PackageManagerService.java&lt;/P&gt;&lt;P&gt;else {&lt;BR /&gt;12221 throw new PackageManagerException(INSTALL_FAILED_INVALID_INSTALL_LOCATION,&lt;BR /&gt;12222 "Application package " + pkg.packageName&lt;BR /&gt;12223 + " not found; ignoring.");&lt;BR /&gt;12224 }&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;we can try neglect this part and try installing the data apps&lt;/P&gt;</description>
      <pubDate>Mon, 07 Feb 2022 04:22:50 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/How-to-pack-and-pre-install-a-Prebuilt-APK/m-p/1409379#M186664</guid>
      <dc:creator>skrishnan08</dc:creator>
      <dc:date>2022-02-07T04:22:50Z</dc:date>
    </item>
  </channel>
</rss>

