Build fail in VIM4

Hello Khadas community
Currently I am trying build images for khadas vim4. I have followed all the steps from khadas documentaion Building Android Source Code | Khadas Documentation but getting error


@Chandrakant The code of VIM4 has not been uploaded to GitHub. It is estimated that they will be released in these two days. So where did your code come from?

I used following command for repo init
$ repo init -u GitHub - khadas/android_manifest: AOSP for Khadas VIMs & Edge -b khadas-vim4-r-fc

@Chandrakant That is a very early 32-bit SDK, which we will not maintain in the future. The 64 bit SDK may be uploaded in these two days. I can now help you with the compilation problem. Please provide complete compilation steps and logs.

$ repo init -u GitHub - khadas/android_manifest: AOSP for Khadas VIMs & Edge -b khadas-vim4-r-fc
$ repo sync -j4
$ cd bootloader/uboot
$ ./mk kvim4 --avb2 --vab$
$ ./mk kvim4 -v 5.4 -j4
$ cd …/…/
$ . build/envsetup.sh
$ lunch kvim4-userdebug
$ make -j4

@Chandrakant
1,Ensure that the downloaded code is correct, and check whether there are errors during downloading the code?
2,Install Toolchains | Khadas Documentation, Have you configured the tool chain according to this document?
3,Please provide the corresponding compiled complete log.

khadasvim4$ repo sync -j4
Fetching: 100% (769/769), done in 2m25.682s
Garbage collecting:  6% [3 jobs] (47/769) started android_vendor_amlogic_common_kernel_prebuilts_gcc_linux-x86_aarch64_aarch64-linux-android-4Garbage collecting:  6% [4 jobs] (51/769) finished android_vendor_amlogic_common_kernel_prebuilts_gcc_linux-x86_aarch64_aarch64-linux-android-Garbage collecting: 100% (769/769), done in 1.547s
external/ppp/: discarding 1 commits
external/e2fsprogs/: discarding 1 commits
hardware/libhardware/: discarding 1 commits
frameworks/opt/net/wifi/: discarding 1 commits
packages/apps/Bluetooth/: discarding 1 commits
packages/apps/Gallery2/: discarding 1 commits
frameworks/av/: discarding 9 commits
packages/apps/Camera2/: discarding 3 commits
packages/providers/TvProvider/: discarding 2 commits
system/media/: discarding 2 commits
external/skia/: discarding 1 commits
Checking out: 100% (769/769), done in 1.479s
repo sync has finished successfully.

khadasvim4/bootloader/uboot$ ./mk kvim4 --avb2 --vab

fip/_tmp/bb1st.usb.bin.signed 0 512
fip/_tmp/blob-bl2e.usb.bin.signed 512 152
fip/_tmp/blob-bl2x.bin.signed 664 136
fip/_tmp/ddr-fip.bin 800 512
fip/_tmp/device-fip.bin.signed 1312 5032
output file are generated in build/ folder
Bootloader build done!

khadasvim4/bootloader/uboot$ ./mk kvim4 -v 5.4 -j4

fip/_tmp/bb1st.usb.bin.signed 0 512
fip/_tmp/blob-bl2e.usb.bin.signed 512 152
fip/_tmp/blob-bl2x.bin.signed 664 136
fip/_tmp/ddr-fip.bin 800 512
fip/_tmp/device-fip.bin.signed 1312 5032
output file are generated in build/ folder
Bootloader build done!

khadasvim4$ lunch kvim4-userdebug
device/khadas/common/tuner/tuner.mk:25: warning: TUNER_MODULE is cxd2856
device/khadas/common/video_algorithm/hdr10_tmo/hdr10_tmo.mk:22: warning: HDR10_TMO_MODULE is true
device/khadas/common/video_algorithm/dnlp/dnlp.mk:22: warning: DNLP_MODULE is true
device/khadas/common/ldim/ldim.mk:22: warning: LDIM_FW_MODULE is true
device/khadas/common/speech/speech.mk:23: warning: because speech does not support kernel 5.4, So set SPEECH_MODULE to false here
vendor/amlogic/common/wifi_bt/bluetooth/configs/bluetooth.mk:26: warning: BLUETOOTH_MODULE is multibt
vendor/amlogic/common/wifi_bt/bluetooth/configs/bluetooth.mk:30: warning: BLUETOOTH_INF is not set
device/khadas/kvim4/kvim4.mk:394: warning: Params: is_reference_project=[false],need_tv_feature=[true], is_android_tv=[false];  Patch Finish.
mkdir: Needs 1 argument (see "mkdir --help")
/bin/bash: VENDOR-PATH-PH: command not found
/bin/bash: /usr/icu/: No such file or directory
device/khadas/common/core_amlogic.mk:161: warning: BOARD_COMPILE_ATV is false
device/khadas/common/dolby_ms12/dolby_ms12.mk:16: warning: 'Dolby MS12 2.4 will be installed'
device/khadas/common/products/tv/t7/device.mk:114: warning: 'using audio_policy_configuration_ms12_dtshd.xml'
device/khadas/common/sepolicy.mk:1: warning: current build platform is 11

============================================
PLATFORM_VERSION_CODENAME=REL
PLATFORM_VERSION=11
TARGET_PRODUCT=kvim4
TARGET_BUILD_VARIANT=userdebug
TARGET_BUILD_TYPE=release
TARGET_ARCH=arm
TARGET_ARCH_VARIANT=armv7-a-neon
TARGET_CPU_VARIANT=cortex-a9
HOST_ARCH=x86_64
HOST_2ND_ARCH=x86
HOST_OS=linux
HOST_OS_EXTRA=Linux-4.15.0-180-generic-x86_64-Ubuntu-18.04-LTS
HOST_CROSS_OS=windows
HOST_CROSS_ARCH=x86
HOST_CROSS_2ND_ARCH=x86_64
HOST_BUILD_TYPE=release
BUILD_ID=RQ3A.210805.001.A1
OUT_DIR=out
PRODUCT_SOONG_NAMESPACES=device/khadas/common hardware/amlogic vendor/amlogic/common vendor/amlogic/kvim4
============================================


khadasvim4$ make -j4

hello mtk
qcabt
hello qca
hello qca test
[  0% 196/74371] build out/target/product/kvim4/obj/PACKAGING/depmod_vendor_stripped_intermediates/8723bu.ko
FAILED: out/target/product/kvim4/obj/PACKAGING/depmod_vendor_stripped_intermediates/8723bu.ko
/bin/bash -c "prebuilts/clang/host/linux-x86/clang-r383902b1/bin/llvm-strip -o out/target/product/kvim4/obj/PACKAGING/depmod_vendor_stripped_intermediates/8723bu.ko --strip-debug device/khadas/kvim4-kernel/5.4/lib/modules/8723bu.ko"
prebuilts/clang/host/linux-x86/clang-r383902b1/bin/llvm-strip: error: 'device/khadas/kvim4-kernel/5.4/lib/modules/8723bu.ko': The file was not recognized as a valid object file
20:09:41 ninja failed with: exit status 1

#### failed to build some targets (43 seconds) ####


@Chandrakant The red box indicates that there is an error in code synchronization. You also need to execute the synchronization code command.

So what is solution for it ?

repo sync -j4

Re execute the synchronization code command until no error is reported.

@Chandrakant I know the reason. The compilation error is caused by not getting the large file correctly.

The above steps need to be performed.

In addition, the 64 bit SDK has been released. Please check the download code description.

Its compiled fine with 64-bit & lfs pull steps, thanks.