AOSP 6.0 Build for hammerhead - proprietary binaries

﹥>﹥吖頭↗ 提交于 2019-12-01 08:55:18

Be certain to download the Nexus 5 binaries that match the version of AOSP that you're building. For example, if you're building the most recent version of AOSP, when you initialized your repo you entered this command:

$ repo init -u https://android.googlesource.com/platform/manifest -b android-6.0.1_r72  

Take that last branch code (everything after '-b') android-6.0.1_r72 and search for it over here: https://source.android.com/source/build-numbers.html#source-code-tags-and-builds

It matches build M4B30X

Now, take that build code M4B30X and search for it over here: https://developers.google.com/android/nexus/drivers

Download the corresponding binaries:
$ cd ~/Downloads

$ wget https://dl.google.com/dl/android/aosp/broadcom-hammerhead-m4b30x-7c7b231f.tgz $ wget https://dl.google.com/dl/android/aosp/lge-hammerhead-m4b30x-74fa3aa5.tgz $ wget https://dl.google.com/dl/android/aosp/qcom-hammerhead-m4b30x-158606cf.tgz

Verify the integrity of each download:

 $ echo "01a03cf36b20ee2460d108c1d199f4b012b084368cddfbff1e40ff8270b54d6f broadcom-hammerhead-m4b30x-7c7b231f.tgz" | sha256sum -c
 $ echo "a533f4c82d430181b97ab2321acf10ab1e2b126de7bb15437c969331541af7cb lge-hammerhead-m4b30x-74fa3aa5.tgz" | sha256sum -c
 $ echo "9a2760bda79e3be7bbe7203c05273c80b0d043d9aaf15be20361e35b16ef8905 qcom-hammerhead-m4b30x-158606cf.tgz" | sha256sum -c

Extract each gzip file:

 $ tar xzvf broadcom-hammerhead-m4b30x-7c7b231f.tgz  
 $ tar xzvf lge-hammerhead-m4b30x-74fa3aa5.tgz    
 $ tar xzvf qcom-hammerhead-m4b30x-158606cf.tgz

Execute the resulting self-extracting files from the source tree's root folder(~/AOSP)

$ cd ~/AOSP
$ ~/Downloads/extract-broadcom-hammerhead.sh
$ ~/Downloads/extract-lge-hammerhead.sh
$ ~/Downloads/extract-qcom-hammerhead.sh 

After executing each file hit the Enter key once and then hit the Space bar until you reach the end of each document. At the end of each document type:

    I ACCEPT

and hit the Enter key.

To accommodate the new binaries you must initiate a full rebuild, so set the environment:
$ ./ build/envsetup.sh
$ lunch aosp_hammerhead-userdebug

And make the synthetic target 'clobber' in order to clean:

$ make clobber

Now rebuild: (If you're running a Core2Duo)

 $ make -j4  

(Or, if you're running something bigger)

$ make -j16

Uncompress the downloaded files, you will get bash files. Put all these files in the root directory of your AOSP project and execute them. You will have to accept the licenses and the binaries will be extracted in the right directory.

After this step. In the AOSP root directory, execute :

make clobber

It will clean the current build (out/**). It is needed for the make to notice the changes regarding the AOSP build official procedure.

Then you can compile again the sources.

make -j4 

(or j8/j16 regarding your CPU threads number)

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!