android 4.1.1源码下载 -编译方法

android 4.1源码下载方法

                                    转载http://www.oschina.net/question/565065_65773

1、安装repo ,执行命令如下:

 

$ curl https://dl-ssl.google.com/dl/googlesource/git-repo/repo > ~/bin/repo  
 
$ chmod +x ~/bin/repo  
 

 

2、初始化 repo ,执行命令如下:

$ repo init -u https://android.googlesource.com/platform/manifest -b android-4.1.1_r1  
 

3、下载源代码,命令如下:


$ repo sync
 

4.编译源代码

初始化脚本

$ source build/envsetup.sh
$ lunch full-eng
第二个命令的参数可以参考官网,说明很详细,你想生成什么样的文件,就设定什么样的参数

http://source.android.com/source/building.html


编译代码:

$ make -jN
其中N参数代表你计算机的线程参数,数字越大,编译速度越快,但是要看你计算机支持到什么地步



5.运行emulator:

编译成功后,运行模拟器

$ emulator

如果找不到命令,那么重新输入:

$ source build/envsetup.sh

$ lunch full-eng
再运行
$ emulator

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

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值