Corrupted system.img on Nexus 5X

185 views
Skip to first unread message

Pawel

unread,
Jun 8, 2016, 3:53:55 PM6/8/16
to Android Building
Hi,

I've downloaded android-6.0.1_r45 on my Mac, added both lge and qcom vendor images into the source tree, then build it and flash my nexus 5x.
However it gets stack on google logo. Reflashing vendor.img to original one from mtc19v allow to start device, but still it is corrupted (only few aps, wifi doesn't work, etc.)

I looked into the out directory and seems like system.img is very small comparing to original source (555M vs 1.9G)
-rw-r--r--  1 staff  staff    11M Jun  8 20:12 out/target/product/bullhead/boot.img
-rw-r--r--  1 staff  staff   5.6M Jun  8 20:25 out/target/product/bullhead/cache.img
-rw-r--r--  1 staff  staff   2.1M Jun  8 20:12 out/target/product/bullhead/ramdisk-recovery.img
-rw-r--r--  1 staff  staff   1.2M Jun  8 20:12 out/target/product/bullhead/ramdisk.img
-rw-r--r--  1 staff  staff    12M Jun  8 20:12 out/target/product/bullhead/recovery.img
-rw-r--r--  1 staff  staff   555M Jun  8 21:16 out/target/product/bullhead/system.img

-rw-r--r--  1 staff  staff   135M Jun  8 20:25 out/target/product/bullhead/userdata.img
-rw-r--r--  1 staff  staff   193M Jun  8 18:55 out/target/product/bullhead/vendor.img


Am I doing something wrong? Did I missed some step? Following it's my step by step try:

repo init -u https://android.googlesource.com/platform/manifest -b android-6.0.1_r45
repo sync
#add 10.11 to build/core/combo/mac_version.mk
#add darwin to Correct Case-insesitives in build/core/main.mk
#extend Xmx for Jack in build/core/config.mk
export PATH=/Library/Java/JavaVirtualMachines/jdk1.7.0_79.jdk/Contents/Home/bin:$PATH
export USE_CCACHE=1
source build
/envsetup.sh
lunch aosp_bullhead
-userdebug
make
-j4


Daniel Micay

unread,
Jun 9, 2016, 8:48:27 AM6/9/16
to Android Building
You need https://github.com/anestisb/android-prepare-vendor for proper Nexus 9, 5X and 6P builds. You're missing all of the proprietary blobs for /system and verified boot won't work if you don't generate your own vendor image, although you probably aren't signing the build and using a locked bootloader anyway.

Pawel

unread,
Jun 9, 2016, 10:01:23 AM6/9/16
to Android Building
You're right: no own vendor image neither signing binaries. I've downloaded and extracted blobs from https://developers.google.com/android/nexus/blobs-preview. Isn't it sufficient?
Anyway, I'll try with android-prepare-vendor.

Pawel

unread,
Jun 12, 2016, 12:51:17 AM6/12/16
to Android Building
Thanks a lot for your hint. I've tried as you suggested - apply output from android-prepare-vendor into the source tree. It allows me to flash and start device!

However I see few issues there:
1. I have a message screen "Android System. There's an internal problem with you device... ". I guess it's due to lack of signing keys. Is it correct?
2. Wifi doesn't work. It can connect to a router, but complains about 'no Internet'. I've changed sleeping mode to never, but it doesn't help.
3. There no Google Play app. Correct me if I'm wrong, but I expected to found that app even when buillding AOSP.

Daniel Micay

unread,
Jun 13, 2016, 10:39:29 AM6/13/16
to Android Building
Play isn't part of AOSP.

The other problems might be caused by only flashing system.img instead of all the OS images (boot, recovery, vendor, system).
Reply all
Reply to author
Forward
0 new messages