天天看點

Aosp8.1 build/JDK8 aosp_arm-eng

Host  Linux/64bit x86-64  Ubutu or RHEL7.x 

1. set git proxy 

[email protected]:~/Google/android-8.1.0_r1_OPM1.171019.011$ git config  --global  -l 

[email protected]

user.name=Lake

core.editor=vim

color.ui=auto

alias.logall=log --graph  --pretty=oneline  --all    --abbrev-commit    --decorate

alias.lg=log --color --graph --pretty=format:'%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr) %C(bold blue)<%an>%Creset' --abbrev-commit

push.default=matching

https.proxy=10.24.1.1:8080

http.proxy=10.24.1.1:8080

or

try Mirror from https://aosp.tuna.tsinghua.edu.cn/

2. repo sync

curl https://storage.googleapis.com/git-repo-downloads/repo > ~/bin/repo

  chmod a+x ~/bin/repo

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

  repo  sync  -j32 

3. JDK8

Make sure your java/javac is new version 1.8

[email protected]:~/Google/android-8.1.0_r1_OPM1.171019.011$ java -version 

openjdk version "1.8.0_65"

OpenJDK Runtime Environment (build 1.8.0_65-b17)

OpenJDK 64-Bit Server VM (build 25.65-b01, mixed mode)

[email protected]:~/Google/android-8.1.0_r1_OPM1.171019.011$ javac -version 

javac 1.8.0_65

[email protected]:~/Google/android-8.1.0_r1_OPM1.171019.011$ 

4.  Build 

[email protected]:~/Google/android-8.1.0_r1_OPM1.171019.011$  source  build/envsetup.sh 

[email protected]:~/Google/android-8.1.0_r1_OPM1.171019.011$   lunch   

Lunch menu... pick a combo:

     1. aosp_arm-eng   <<<<<<<< ARM 32 bit 

     2. aosp_arm64-eng  <<<<<<<< ARM 64 bit 

  make  -j32

5. Try emulator  

[email protected]:~/Google/android-8.1.0_r1_OPM1.171019.011$  which emulator 

/home/lake/Google/android-8.1.0_r1_OPM1.171019.011/prebuilts/android-emulator/linux-x86_64/emulator

lake@localhost:~/Google/android-8.1.0_r1_OPM1.171019.011$ which adb 

/home/lake/Google/android-8.1.0_r1_OPM1.171019.011/out/host/linux-x86/bin/adb

[email protected]:~/Google/android-8.1.0_r1_OPM1.171019.011$ 

6. la[email protected]:~/Google/android-8.1.0_r1_OPM1.171019.011$ emulator

Wait for Android GUI  .........  > 10 minutes 

7. Check through adb 

lake@localhost:~/Google/android-8.1.0_r1_OPM1.171019.011$ adb  shell

generic:/ # cat  /proc/version 

cLinux version 3.18.74+ ([email protected]) (gcc version 4.8 (GCC) ) #1 SMP PREEMPT Thu Oct 12 17:14:21 UTC 2017

generic:/ # cat /proc/cmdline 

qemu=1 androidboot.hardware=ranchu keep_bootcon earlyprintk=ttyAMA0 android.qemud=1 console=0 android.checkjni=1 qemu.gles=1 qemu.opengles.version=196608 cma=262M ndns=2 ramoops.mem_address=0xff018000 ramoops.mem_size=0x10000 memmap=0x10000$0xff018000 ndns=2

generic:/ # 

generic:/ # 

generic:/ # getprop  |grep vers

[gsm.version.ril-impl]: [android reference-ril 1.0]

[ro.build.version.all_codenames]: [REL]

[ro.build.version.base_os]: []

[ro.build.version.codename]: [REL]

[ro.build.version.incremental]: [eng.lake.20180620.003212]

[ro.build.version.preview_sdk]: [0]

[ro.build.version.release]: [8.1.0]

[ro.build.version.sdk]: [27]

[ro.build.version.security_patch]: [2017-12-05]

[ro.kernel.qemu.opengles.version]: [196608]

[ro.property_service.version]: [2]

generic:/ # 

generic:/ # 

generic:/ # getprop  |grep build                                                                                                     

[ro.bootimage.build.date]: [Wed Jun 20 00:32:12 EDT 2018]

[ro.bootimage.build.date.utc]: [1529469132]

[ro.bootimage.build.fingerprint]: [Android/aosp_arm/generic:8.1.0/OPM1.171019.011/lake06200032:eng/test-keys]

[ro.build.characteristics]: [emulator]

[ro.build.date]: [Wed Jun 20 00:32:12 EDT 2018]

[ro.build.date.utc]: [1529469132]

[ro.build.description]: [aosp_arm-eng 8.1.0 OPM1.171019.011 eng.lake.20180620.003212 test-keys]

[ro.build.display.id]: [aosp_arm-eng 8.1.0 OPM1.171019.011 eng.lake.20180620.003212 test-keys]

[ro.build.fingerprint]: [Android/aosp_arm/generic:8.1.0/OPM1.171019.011/lake06200032:eng/test-keys]

[ro.build.flavor]: [aosp_arm-eng]

[ro.build.host]: [localhost.localdomain]

[ro.build.id]: [OPM1.171019.011]

[ro.build.product]: [generic]

[ro.build.tags]: [test-keys]

[ro.build.type]: [eng]

[ro.build.user]: [lake]

[ro.build.version.all_codenames]: [REL]

[ro.build.version.base_os]: []

[ro.build.version.codename]: [REL]

[ro.build.version.incremental]: [eng.lake.20180620.003212]

[ro.build.version.preview_sdk]: [0]

[ro.build.version.release]: [8.1.0]

[ro.build.version.sdk]: [27]

[ro.build.version.security_patch]: [2017-12-05]

[ro.vendor.build.date]: [Wed Jun 20 00:32:12 EDT 2018]

[ro.vendor.build.date.utc]: [1529469132]

[ro.vendor.build.fingerprint]: [Android/aosp_arm/generic:8.1.0/OPM1.171019.011/lake06200032:eng/test-keys]

generic:/ # 

Aosp8.1 build/JDK8 aosp_arm-eng