如何只编译android的一部分

ifeq ($(MAKECMDGOALS),help)
dont_bother := true
endif
ifeq ($(MAKECMDGOALS),out)
dont_bother := true
endif

.PHONY: help
help:
	@echo
	@echo "Common make targets:"
	@echo "----------------------------------------------------------------------------------"
	@echo "droid                   Default target"
	@echo "clean                   (aka clobber) equivalent to rm -rf out/"
	@echo "snod                    Quickly rebuild the system image from built packages"
	@echo "offline-sdk-docs        Generate the HTML for the developer SDK docs"
	@echo "doc-comment-check-docs  Check HTML doc links & validity, without generating HTML"
	@echo "libandroid_runtime      All the JNI framework stuff"
	@echo "framework               All the java framework stuff"
	@echo "services                The system server (Java) and friends"
	@echo "help                    You're reading it right now"

.PHONY: out
out:
	@echo "I'm sure you're nice and all, but no thanks."

android Help.mk


执行make help

Common make targets:
----------------------------------------------------------------------------------
droid                   Default target
clean                   (aka clobber) equivalent to rm -rf out/
snod                    Quickly rebuild the system image from built packages
offline-sdk-docs        Generate the HTML for the developer SDK docs
doc-comment-check-docs  Check HTML doc links & validity, without generating HTML
libandroid_runtime      All the JNI framework stuff
framework               All the java framework stuff
services                The system server (Java) and friends
help                    You're reading it right now

从这我们可以知道,android在编译的时候是可以只编译一部分的,这样对android的整个系统理解得更进一步

1、如果只想编译jni相关部分

可以执行make libandroid_runtime

2、如果只想编译java相关部分

可以执行make framework

3、如果只想编译services相关部分

可以执行make services

其它类似;

4、当然还有一它 些工具可能用得更多

像mmm

    mm


  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值