make framework 等等命令的使用



如果framework改动,全部mak,并且再升级太耗时间,学了一个方式,可以节省时间

pateo@pateo-B86N53X:/work/project/a1205d$ . build/envsetup.sh
including device/fsl/imx5x/vendorsetup.sh
including device/pateo/a1030d/vendorsetup.sh
including device/pateo/a1205d/vendorsetup.sh
including device/pateo/vanilla/vendorsetup.sh
pateo@pateo-B86N53X:/work/project/a1205d$ choosecombo Device release a1205d user
Build for the simulator or the device?
     1. Device
     2. Simulator

Which would you like? [1] Device


Build type choices are:
     1. release
     2. debug

Which would you like? [1] release


Which product would you like? [a1205d] a1205d


Variant choices are:
     1. user
     2. userdebug
     3. eng
Which would you like? [eng] user

============================================
PLATFORM_VERSION_CODENAME=REL
PLATFORM_VERSION=2.3.4
TARGET_PRODUCT=a1205d
TARGET_BUILD_VARIANT=user
TARGET_SIMULATOR=false
TARGET_BUILD_TYPE=release
TARGET_BUILD_APPS=
TARGET_ARCH=arm
HOST_ARCH=x86
HOST_OS=linux
HOST_BUILD_TYPE=release
BUILD_ID=R10.3.2_3
============================================

pateo@pateo-B86N53X:/work/project/a1205d$ make framework

aapt: warning: **** string 'volum_walkietalkie_new' has no default or required localization for 'mdpi' in frameworks/base/core/res/res
aapt: warning: **** string 'volum_walkietalkie_new' has no default or required localization for 'nodpi' in frameworks/base/core/res/res
Install: out/target/product/a1205d/system/framework/framework-res.apk
Install: out/target/product/a1205d/system/framework/framework.jar
pateo@pateo-B86N53X:/work/project/a1205d$ 
pateo@pateo-B86N53X:/work/project/a1205d$ 

利用adb命令把这两个文件push到/system/framework下面,所以想测试这个新模块,则需要先杀掉所有使用该模块的进程,进程重启重新加载模块,就时候就是修改后的文件了,类似的命令还有很多,可以查阅网上资料



pateo@pateo-B86N53X:/work/project/a1205d$ adb push out/target/product/a1205d/system/framework/framework-res.apk /system/framework
1265 KB/s (9659062 bytes in 7.452s)
pateo@pateo-B86N53X:/work/project/a1205d$ adb push out/target/product/a1205d/system/framework/framework.jar /system/framework
1261 KB/s (2992615 bytes in 2.317s)

==============================================================================================================


pateo@pateo-B86N53X:/work/project/DLS-Auto-F6_a1001eh$ mmm frameworks/base/
============================================
PLATFORM_VERSION_CODENAME=REL
PLATFORM_VERSION=4.0.4
TARGET_PRODUCT=a1001eh
TARGET_BUILD_VARIANT=eng
TARGET_BUILD_TYPE=release
TARGET_BUILD_APPS=
TARGET_ARCH=arm
TARGET_ARCH_VARIANT=armv7-a-neon
HOST_ARCH=x86
HOST_OS=linux
HOST_BUILD_TYPE=release
BUILD_ID=UNKNOWN
BUILD_NUMBER=2301
============================================
No private recovery resources for TARGET_DEVICE a1001eh
make:进入目录'/work/project/DLS-Auto-F6_a1001eh'
target Java: framework (out/target/common/obj/JAVA_LIBRARIES/framework_intermediates/classes)
注意:某些输入文件使用或覆盖了已过时的 API。
注意:要了解详细信息,请使用 -Xlint:deprecation 重新编译。
注意:某些输入文件使用了未经检查或不安全的操作。
注意:要了解详细信息,请使用 -Xlint:unchecked 重新编译。
Copying: out/target/common/obj/JAVA_LIBRARIES/framework_intermediates/classes-jarjar.jar
Copying: out/target/common/obj/JAVA_LIBRARIES/framework_intermediates/emma_out/lib/classes-jarjar.jar
Copying: out/target/common/obj/JAVA_LIBRARIES/framework_intermediates/classes.jar
Copying: out/target/common/obj/JAVA_LIBRARIES/framework_intermediates/noproguard.classes.jar
target Dex: framework
Copying: out/target/common/obj/JAVA_LIBRARIES/framework_intermediates/noproguard.classes.dex
target Jar: framework (out/target/common/obj/JAVA_LIBRARIES/framework_intermediates/javalib.jar)
 'out/target/common/obj/JAVA_LIBRARIES/framework_intermediates/classes.dex' as 'classes.dex'...
Install: out/target/product/a1001eh/system/framework/framework.jar
Notice file: frameworks/base/NOTICE -- out/target/product/a1001eh/obj/NOTICE_FILES/src//system/framework/ext.jar.txt
Install: out/target/product/a1001eh/system/framework/ext.jar
make:离开目录“/work/project/DLS-Auto-F6_a1001eh”
pateo@pateo-B86N53X:/work/project/DLS-Auto-F6_a1001eh$ mmm frameworks/base/core
No Android.mk in frameworks/base/core.
pateo@pateo-B86N53X:/work/project/DLS-Auto-F6_a1001eh$ mmm frameworks/base/core
No Android.mk in frameworks/base/core.
pateo@pateo-B86N53X:/work/project/DLS-Auto-F6_a1001eh$ 
pateo@pateo-B86N53X:/work/project/DLS-Auto-F6_a1001eh$ 
pateo@pateo-B86N53X:/work/project/DLS-Auto-F6_a1001eh$ 
pateo@pateo-B86N53X:/work/project/DLS-Auto-F6_a1001eh$ mmm frameworks/base/core/java/
No Android.mk in frameworks/base/core/java.
pateo@pateo-B86N53X:/work/project/DLS-Auto-F6_a1001eh$ 



root@android:/system # cd framework/                                           
root@android:/system/framework # ls
am.jar
android.policy.jar
android.test.runner.jar
apache-xml.jar
bmgr.jar
bouncycastle.jar
bu.jar
com.android.location.provider.jar
core-junit.jar
core.jar
dls.jar
dls.policy.jar
dls.widget.jar
ext.jar
filterfw.jar
framework-res.apk
framework.jar
ime.jar
input.jar
ivtbluetooth.jar
javax.obex.jar
monkey.jar
pm.jar
services.jar
svc.jar
root@android:/system/framework # 


pateo@pateo-B86N53X:/work/project/DLS-Auto-F6_a1001eh/frameworks/base$ adb shell
root@android:/ # mount -o rw,remount -t yaffs2 /dev/block/mtdblock3 /system
root@android:/ # chmod 777 /system
root@android:/ # cd system
root@android:/system # chmod 777 framework/                                    
root@android:/system # 



pateo@pateo-B86N53X:/work/project/DLS-Auto-F6_a1001eh$ adb push out/target/product/a1001eh/system/framework/framework.jar /system/framework/
570 KB/s (3989923 bytes in 6.825s)
pateo@pateo-B86N53X:/work/project/DLS-Auto-F6_a1001eh$ adb shell sync
pateo@pateo-B86N53X:/work/project/DLS-Auto-F6_a1001eh$


你可能感兴趣的:(Framework)