TinkerBoard2-Android / manifest

12 stars 9 forks source link

missing kernel/arch/arm64/boot/Image #3

Open Turleyy opened 1 year ago

Turleyy commented 1 year ago

When I build android 11 by typing make (after following all previous instructions on android source website), it run for a while then fail: FAILED: ninja: 'kernel/arch/arm64/boot/Image', needed by 'out/target/product/Tinker_Board_2/kernel', missing and no known rule to make it When I go to that directory, there is a gitignore file: Image Image.gz So, is the Image missing or I am missing some extra steps

asusiot commented 1 year ago

hello @Turleyy the kernel.img and resource.img for rk3399 android 11 os are included in the boot.img; the kernel.img and resource.img cannot be built individually. please download the complete source codes and use the command to build the image: ./build.sh -UCKAu

Turleyy commented 1 year ago

Thanks for you reply @asusiot I did the repo sync to download the source code and followed every steps you said in here https://github.com/TinkerBoard2-Android/manifest/issues/1 But the build still failed with bunch of error: _make[4]: [drivers/media/i2c/cam_sensor/cam_imx219.o] Error 1 scripts/Makefile.build:637: recipe for target 'drivers/media/i2c/cam_sensor' failed make[3]: [drivers/media/i2c/camsensor] Error 2 scripts/Makefile.build:637: recipe for target 'drivers/media/i2c' failed make[2]: [drivers/media/i2c] Error 2 scripts/Makefile.build:637: recipe for target 'drivers/media' failed make[1]: [drivers/media] Error 2 Makefile:1201: recipe for target 'drivers' failed make: *** [drivers] Error 2

asusiot commented 1 year ago

hello @Turleyy forgot to mention that you'll need to locate to /docker_builder

./docker_builder/docker-builder-run.sh

source build/envsetup.sh

lunch WW_Tinker_Board_2-userdebug

./build.sh -UCKAu
Turleyy commented 1 year ago

hello @asusiot Yes, I did that, too. I did all the source, lunch, build in the shell of the docker, and received errors that I have listed above

asusiot commented 1 year ago

hello @Turleyy what's the environment? mac os and windows wsl are not supported, you'll need an ubuntu machine in order to compile the image

Turleyy commented 1 year ago

hello @asusiot I am running on Ubuntu 22.04

asusiot commented 1 year ago

hello @Turleyy could you try clear it then redo the compilation? rm -rf out

Turleyy commented 1 year ago

hello @asusiot I have followed your instruction and made some progress. This time it built up to 98% but still failed eventually. I don't find any error reports anywhere but some last lines:

asusiot commented 1 year ago

hello @Turleyy we've never seen this issue before. if you download the whole source code with no modification it shouldn't have this error. what changes did you make for compiling? maybe check the tools/metalava/API-LINT.md (as it suggested), too.

not from compiling android 11 os for tinker board 2s but i've looked up and found someone had a similar issue while compiling android 11 os, you will need to run make update-api in root directory before compiling

Turleyy commented 1 year ago

thanks for your support @asusiot I have not make any change yet, but seems like insufficient RAM might caused the problem. I was running on 16gb of RAM and built 2 times which failed with different error reports. After upgrading to 32gb, it built successfully, at least once for now, hope it was not because of luck. Once again thank you for spending your time and effort.

asusiot commented 1 year ago

hello @Turleyy for your reference: Google recommends at least 64 GB of RAM and doesn't test with less. Lower amounts lead to builds being OOM killed.

https://source.android.com/docs/setup/start/requirements?hl=en