`
hongbochen1223
  • 浏览: 43621 次
文章分类
社区版块
存档分类
最新评论

SeAndroid获取以及编译过程

 
阅读更多

对于SeAndroid的学习和研究刚刚开始,还没有了解什么是真正的SeAndroid,所以也不敢妄加评判,等学习之后再好好聊聊对于SeAndroid的看法,对于她的学习我是先从编译开始的,下面就是我的获取和编译的过程。从头到尾编译了差不多得17,8个小时,因为中间有一次出现错误,改正之后重新编译的。

在64位ubuntu系统中,编译SeAndroid的过程

1:安装openjdk 1.7.x

2:http://seandroid.bitbucket.org/ 官网

git clone https://bitbucket.org/seandroid/manifests.git

mkdir seandroid-5.1.0

cd seandroid-5.1.0

repo init -u https://android.googlesource.com/platform/manifest -b android-5.1.0_r3

repo sync

mkdir .repo/local_manifests 

cp ../manifests/seandroid-5.1.0.xml .repo/local_manifests 

repo sync

3:安装所需要的库

git gnupg flex bison gperf build-essential   
zip curl libc6-dev libncurses5-dev:i386 
x11proto-core-dev   libx11-dev:i386 
libreadline6-dev:i386 g++-multilib 
mingw32 tofrodos   python-markdown 
libxml2-utils xsltproc 
zlib1g-dev:i386

4:Building for the Emulator

//PREFIX是源码根目录
export PREFIX=/path/to/your/aospclone
cd $PREFIX
source build/envsetup.sh
lunch aosp_arm-eng
make

5:编译完成之后,找到emulator,在~/.bashrc中配置 export

Export  ANDROID_PRODUCT_OUT_BIN=/home/embedded/seandroid/seandroid-5.1.0/prebuilts/android-emulator/linux-x86_64
export ANDROID_PRODUCT_OUT=/home/embedded/seandroid/seandroid-5.1.0/out/target/product/generic
export PATH=${PATH}:${ANDROID_PRODUCT_OUT_BIN}:${ANDROID_PRODUCT_OUT};

6:配置完成之后 source ~/.bashrc

7: 运行虚拟机

emulator -qemu -append androidboot.selinux=permissive

note:

//当关闭虚拟机,重新启动的时候,可能会出现下面问题
/**
 * emulator:ERROR:You did not specify a virtual
 * device name,and the system directory could
 * not be found.
 */
 ///解决办法就是

 source build/envsetup.sh
 lunch sdk-eng
 emulator
<script type="text/javascript"> $(function () { $('pre.prettyprint code').each(function () { var lines = $(this).text().split('\n').length; var $numbering = $('<ul/>').addClass('pre-numbering').hide(); $(this).addClass('has-numbering').parent().append($numbering); for (i = 1; i <= lines; i++) { $numbering.append($('<li/>').text(i)); }; $numbering.fadeIn(1700); }); }); </script>

版权声明:本文为博主原创文章,未经博主允许不得转载。

分享到:
评论

相关推荐

Global site tag (gtag.js) - Google Analytics