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 sync3:安装所需要的库
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:i3864: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=permissivenote:
//当关闭虚拟机,重新启动的时候,可能会出现下面问题
/**
 * 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 
                    
                     
                    
                 
                    
                
 
                
            
         
         浙公网安备 33010602011771号
浙公网安备 33010602011771号