Push my apk to /system/app

前端 未结 14 2079
清酒与你
清酒与你 2020-12-02 07:16

How can I push my application package to Android emulator \"/system/app\" folder?

I\'ve already tried to use:
\"adb push myApk.apk /system/app\"
and it giv

14条回答
  •  眼角桃花
    2020-12-02 07:44

    The following batch file will install any apk files in the folder to the /system/app directory. It mounts the system drive as rw, then copies the files over.

    To use it, put the following code into a text editor and save it as install.bat on a Windows machine. Then double-click on the batch file to install any APK files that are in the same folder as the batch file.

    NOTE: You can't remount the system partition unless you have root on the device. I've mostly used this on the emulator which defaults to root (And was the original question), but the concept should be the same on a physical device.

    @ECHO OFF
    %~d0
    CD %~dp0
    adb root
    adb shell mount -o rw,remount -t yaffs2 /dev/block/mtdblock3 /system
    adb shell rm /system/app/SdkSetup.apk
    for /f %%a IN ('dir /b *.apk') do adb push %%a /system/app/.
    

提交回复
热议问题