Ads 468x60px

##EasyReadMore##

18 7月, 2018

下載 Android BSP source

Installing required packages:

For Ubuntu >= 15.04
Run the following:

sudo apt-get update
sudo apt-get install openjdk-8-jdk
sudo apt-get install git-core gnupg flex bison gperf build-essential zip curl zlib1g-dev gcc-multilib g++-multilib libc6-dev-i386 lib32ncurses5-dev x11proto-core-dev libx11-dev libxml2-utils xsltproc unzip

On Ubuntu 14.04
  You will need a 64-bit version of Ubuntu. Ubuntu 14.04 is  recommended.
 
  sudo apt-get install git-core gnupg flex bison gperf build- essential zip curl zlib1g-dev gcc-multilib g++-multilib libc6-dev- i386 lib32ncurses5-dev x11proto-core-dev libx11-dev lib32z-dev  libgl1-mesa-dev libxml2-utils xsltproc unzip
Note: To use SELinux tools for policy analysis, also install the  python-networkx package.
  Note: If you are using LDAP and want to run ART host tests, also  install the libnss-sss:i386 package.
 
  On Ubuntu 12.04
  You may use Ubuntu 12.04 to build older versions of Android.  Version 12.04 is not supported on master or recent releases.
 
  sudo apt-get install git gnupg flex bison gperf build-essential zip  curl libc6-dev libncurses5-dev:i386 x11proto-core-dev libx11- dev:i386 libreadline6-dev:i386 libgl1-mesa-glx:i386 libgl1-mesa-dev  g++-multilib mingw32 tofrodos python-markdown libxml2-utils  xsltproc zlib1g-dev:i386
  sudo ln -s /usr/lib/i386-linux-gnu/mesa/libGL.so.1 /usr/lib/i386- linux-gnu/libGL.so
On Ubuntu 10.04 -- 11.10
  Building on Ubuntu 10.04-11.10 is no longer supported, but may be  useful for building older releases of AOSP.
 
  sudo apt-get install git gnupg flex bison gperf build-essential zip  curl zlib1g-dev libc6-dev lib32ncurses5-dev ia32-libs x11proto-core- dev libx11-dev lib32readline5-dev lib32z-dev libgl1-mesa-dev g++- multilib mingw32 tofrodos python-markdown libxml2-utils xsltproc
  On Ubuntu 10.10:
 
  sudo ln -s /usr/lib32/mesa/libGL.so.1 /usr/lib32/mesa/libGL.so
  On Ubuntu 11.10:
sudo apt-get install libx11-dev:i386
Establishing a Build Environment  |  Android Open Source Project - https://goo.gl/Yw2UdP

Installing Repo:

mkdir ~/bin
PATH=~/bin:$PATH
  curl https://storage.googleapis.com/git-repo-downloads/repo > ~/bin/ repo
  chmod a+x ~/bin/repo

Initializing a Repo client:

mkdir ~/android
  cd ~/android
  repo init -u https://android.googlesource.com/platform/manifest
  repo init -u https://android.googlesource.com/platform/manifest -b  android-4.0.1_r1
  repo sync

錯誤處理:

fatal: Cannot get https://gerrit.googlesource.com/git-repo/clone.bundle
上面的方式是将repo添加到環境變量,但是repo運行時,仍然會去google服務器請求最新版本,解決方式是在本地環境變量中指定repo服務器地址
repo的運行過程中會嘗試訪問官方的git源更新自己,如果想使用tuna的鏡像源進行更新,可以将如下内容>復制到你的~/.bashrc裡
export REPO_URL='https://mirrors.tuna.tsinghua.edu.cn/git/git-repo/'
并重啟終端模拟器。
repo init報錯Cannot get https://gerrit.googlesource.com/git-repo/clone.bundle - CSDN博客 - https://goo.gl/rmxZKk

0 意見:

張貼留言

 
Blogger Templates