Khadas vim3 source code building Issue.

Hi,
I’m trying to build source code for VIM3 and I’m getting some issues after running the same command which is suggested in this link Building Android Source Code | Khadas Documentation.
when i run this below command I’m getting this error, So please see the log and suggest some solutions.

1. $ cd bootloader/uboot
2. $ ./mk kvim3

Clean up
make[1]: /opt/toolchains/gcc-linaro-aarch64-none-elf-4.8-2013.11_linux/bin/aarch64-none-elf-gcc: Command not found
/bin/sh: 1: /opt/toolchains/gcc-linaro-aarch64-none-elf-4.8-2013.11_linux/bin/aarch64-none-elf-gcc: not found
dirname: missing operand
Try 'dirname --help' for more information.
select bl33: 
Compile config: kvim3
make[1]: /opt/toolchains/gcc-linaro-aarch64-none-elf-4.8-2013.11_linux/bin/aarch64-none-elf-gcc: Command not found
/bin/sh: 1: /opt/toolchains/gcc-linaro-aarch64-none-elf-4.8-2013.11_linux/bin/aarch64-none-elf-gcc: not found
dirname: missing operand
Try 'dirname --help' for more information.
  HOSTCC  scripts/basic/fixdep
  GEN     ./Makefile
  HOSTCC  scripts/kconfig/conf.o
  SHIPPED scripts/kconfig/zconf.tab.c
  SHIPPED scripts/kconfig/zconf.lex.c
  SHIPPED scripts/kconfig/zconf.hash.c
  HOSTCC  scripts/kconfig/zconf.tab.o
  HOSTLD  scripts/kconfig/conf
#
# configuration written to .config
#
*****Compile tools*****
parse build done
export CONFIG_SYSTEM_AS_ROOT
Build uboot...Please Wait...systemroot...null...
make[1]: /opt/toolchains/gcc-linaro-aarch64-none-elf-4.8-2013.11_linux/bin/aarch64-none-elf-gcc: Command not found
/bin/sh: 1: /opt/toolchains/gcc-linaro-aarch64-none-elf-4.8-2013.11_linux/bin/aarch64-none-elf-gcc: not found
dirname: missing operand
Try 'dirname --help' for more information.
  GEN     ./Makefile
scripts/kconfig/conf --silentoldconfig Kconfig
  CHK     include/config.h
  UPD     include/config.h
  GEN     include/autoconf.mk
/bin/sh: 1: /opt/toolchains/gcc-linaro-aarch64-none-elf-4.8-2013.11_linux/bin/aarch64-none-elf-gcc: not found
  GEN     include/autoconf.mk.dep
/bin/sh: 1: /opt/toolchains/gcc-linaro-aarch64-none-elf-4.8-2013.11_linux/bin/aarch64-none-elf-gcc: not found
../scripts/Makefile.autoconf:64: recipe for target 'include/autoconf.mk' failed
make[3]: *** [include/autoconf.mk] Error 1
make[3]: *** Waiting for unfinished jobs....
../scripts/Makefile.autoconf:40: recipe for target 'include/autoconf.mk.dep' failed
make[3]: *** [include/autoconf.mk.dep] Error 1
../Makefile:480: recipe for target 'silentoldconfig' failed
make[2]: *** [silentoldconfig] Error 1
make[1]: *** No rule to make target 'include/config/auto.conf', needed by 'include/config/uboot.release'.  Stop.
Makefile:147: recipe for target 'sub-make' failed
make: *** [sub-make] Error 2
Error: U-boot build failed... abort

You need to install the toolchains.

Thank you for your reply…
I already install the toolchains from same link but still I’m getting the same issue.

Clean up
make[1]: /opt/toolchains/gcc-linaro-aarch64-none-elf-4.8-2013.11_linux/bin/aarch64-none-elf-gcc: Command not found
/bin/sh: 1: /opt/toolchains/gcc-linaro-aarch64-none-elf-4.8-2013.11_linux/bin/aarch64-none-elf-gcc: not found
dirname: missing operand
Try 'dirname --help' for more information.
  CLEAN   scripts/basic
  CLEAN   scripts/kconfig
  CLEAN   include/config include/generated
  CLEAN   .config include/config.h
select bl33: 
Compile config: kvim3
make[1]: /opt/toolchains/gcc-linaro-aarch64-none-elf-4.8-2013.11_linux/bin/aarch64-none-elf-gcc: Command not found
/bin/sh: 1: /opt/toolchains/gcc-linaro-aarch64-none-elf-4.8-2013.11_linux/bin/aarch64-none-elf-gcc: not found
dirname: missing operand
Try 'dirname --help' for more information.
  HOSTCC  scripts/basic/fixdep
  GEN     ./Makefile
  HOSTCC  scripts/kconfig/conf.o
  SHIPPED scripts/kconfig/zconf.tab.c
  SHIPPED scripts/kconfig/zconf.lex.c
  SHIPPED scripts/kconfig/zconf.hash.c
  HOSTCC  scripts/kconfig/zconf.tab.o
  HOSTLD  scripts/kconfig/conf
#
# configuration written to .config
#
*****Compile tools*****
parse build done
export CONFIG_SYSTEM_AS_ROOT
Build uboot...Please Wait...systemroot...null...
make[1]: /opt/toolchains/gcc-linaro-aarch64-none-elf-4.8-2013.11_linux/bin/aarch64-none-elf-gcc: Command not found
/bin/sh: 1: /opt/toolchains/gcc-linaro-aarch64-none-elf-4.8-2013.11_linux/bin/aarch64-none-elf-gcc: not found
dirname: missing operand
Try 'dirname --help' for more information.
  GEN     ./Makefile
scripts/kconfig/conf --silentoldconfig Kconfig
  CHK     include/config.h
  UPD     include/config.h
  GEN     include/autoconf.mk
/bin/sh: 1: /opt/toolchains/gcc-linaro-aarch64-none-elf-4.8-2013.11_linux/bin/aarch64-none-elf-gcc: not found
  GEN     include/autoconf.mk.dep
/bin/sh: 1: /opt/toolchains/gcc-linaro-aarch64-none-elf-4.8-2013.11_linux/bin/aarch64-none-elf-gcc: not found
../scripts/Makefile.autoconf:64: recipe for target 'include/autoconf.mk' failed
make[3]: *** [include/autoconf.mk] Error 1
make[3]: *** Waiting for unfinished jobs....
../scripts/Makefile.autoconf:40: recipe for target 'include/autoconf.mk.dep' failed
make[3]: *** [include/autoconf.mk.dep] Error 1
../Makefile:480: recipe for target 'silentoldconfig' failed
make[2]: *** [silentoldconfig] Error 1
make[1]: *** No rule to make target 'include/config/auto.conf', needed by 'include/config/uboot.release'.  Stop.
Makefile:147: recipe for target 'sub-make' failed
make: *** [sub-make] Error 2
Error: U-boot build failed... abort

Hello @Terry @goenjoy @jasonl

Please help.

You need to check the path /opt/toolchains/

# cd /opt/toolchains/
# ls -la

Hi Terry
above problem are resolve but now I’m getting new issue please suggest some solution for this build fail error.

hardware/amlogic/wifi/configs/wifi.mk:43: warning: WIFI_MOUDLE is multiwifi
hardware/amlogic/wifi/configs/wifi.mk:47: warning: WIFI_BUILD_IN is false
hardware/amlogic/bluetooth/configs/bluetooth.mk:20: warning: BLUETOOTH_MODULE is BCMBT
hardware/amlogic/bluetooth/configs/bluetooth.mk:24: warning: BLUETOOTH_INF is not set
============================================
PLATFORM_VERSION_CODENAME=REL
PLATFORM_VERSION=9
TARGET_PRODUCT=kvim3
TARGET_BUILD_VARIANT=eng
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.4.0-206-generic-x86_64-Ubuntu-16.04.7-LTS
HOST_CROSS_OS=windows
HOST_CROSS_ARCH=x86
HOST_CROSS_2ND_ARCH=x86_64
HOST_BUILD_TYPE=release
BUILD_ID=PPR1.180610.011
OUT_DIR=out
============================================
ninja: no work to do.
ninja: no work to do.
device/khadas/kvim3/preinstall/preinstall.mk was modified, regenerating...
hardware/amlogic/wifi/configs/wifi.mk:43: warning: WIFI_MOUDLE is multiwifi
hardware/amlogic/wifi/configs/wifi.mk:47: warning: WIFI_BUILD_IN is false
hardware/amlogic/bluetooth/configs/bluetooth.mk:20: warning: BLUETOOTH_MODULE is BCMBT
hardware/amlogic/bluetooth/configs/bluetooth.mk:24: warning: BLUETOOTH_INF is not set
device/khadas/kvim3/preinstall/preinstall.mk was modified, regenerating...
hardware/amlogic/wifi/configs/wifi.mk:43: warning: WIFI_MOUDLE is multiwifi
hardware/amlogic/wifi/configs/wifi.mk:47: warning: WIFI_BUILD_IN is false
hardware/amlogic/bluetooth/configs/bluetooth.mk:20: warning: BLUETOOTH_MODULE is BCMBT
hardware/amlogic/bluetooth/configs/bluetooth.mk:24: warning: BLUETOOTH_INF is not set
[5/954] including build/make/Android.mk ...
device/khadas/common/factory.mk:184: warning: echo "radio add dt and bootloader"
device/khadas/common/factory.mk:322: warning: will keep out/target/product/kvim3/update.img
device/khadas/common/factory.mk:465: warning: will keep out/target/product/kvim3/kvim3-fastboot-flashall-20210416.zip
[314/954] including hardware/amlogic/audio/Android.mk ...
"---------ott audio mode, compiler configure 2 channels output by default--------"
[317/954] including hardware/amlogic/camera/Android.mk ...
eth0: error fetching interface information: Device not found
************************************************************
pdk or not:    
target board:  g12b
git version:   "620d8d5f125aad285e53c797f48ee0e32fd774fb"
uncomment:     0 files
last changed:  "Date:   Sat Nov 7 17:50:25 2020 +0800"
build time:    " Fri Apr 16 14:22:43 IST 2021"
builder name:  " anushanker"
branch name:   "* (no branch)"
build mode:    eng
host name:     "anushanker-dell"
eth0: error fetching interface information: Device not found
host IP:       ""
path:          "/home/anushanker/git_lfs/git-lfs-2.3.4/WORKING_DIRECTORY/hardware/amlogic/camera/v3/fake-pipeline2/tests"
************************************************************
[321/954] including hardware/amlogic/gralloc/Android.mk ...
hardware/amlogic/gralloc/Android.mk:79: warning: "the value of GPU_ARCH is bifrost"
hardware/amlogic/gralloc/Android.mk:135: warning: "the value of BOARD_RESOLUTION_RATIO is 1080"
hardware/amlogic/gralloc/Android.mk:141: warning: "the value of HWC_PRIMARY_DISP_SUPPORT_AFBC is false"
hardware/amlogic/gralloc/Android.mk:142: warning: "the value of HWC_EXTEND_DISP_SUPPORT_AFBC is true"
hardware/amlogic/gralloc/Android.mk:154: warning: "the value of GPU_TYPE is gondul"
[323/954] including hardware/amlogic/hwcomposer/Android.mk ...
"Build HWC 2.0"
[537/954] including system/sepolicy/Android.mk ...
system/sepolicy/Android.mk:79: warning: BOARD_SEPOLICY_VERS not specified, assuming current platform version
[908/954] including vendor/amlogic/common/LibTsPlayer/Android.mk ...
vendor/amlogic/common/LibTsPlayer/jni/compat/media_control/Android.mk:27: warning: 9
vendor/amlogic/common/LibTsPlayer/jni/compat/media_control/Android.mk:98: warning: 9
vendor/amlogic/common/LibTsPlayer/jni/test/Android.mk:5: warning: Kitkat
vendor/amlogic/common/LibTsPlayer/jni/test/Android.mk:6: warning: vendor/amlogic/common/LibTsPlayer/jni/test
[919/954] including vendor/amlogic/common/apps/NativeImagePlaye/Android.mk ...
vendor/amlogic/common/apps/NativeImagePlaye/jni/Android.mk:10: warning: libnativehelper/include_jni
[928/954] including vendor/amlogic/common/external/DTVKit/android-inputsource/Android.mk ...
vendor/amlogic/common/external/DTVKit/android-inputsource/logicdtvkit/src/jni/Android.mk:10: warning: libnativehelper/include_jni
build/make/core/java_common.mk:183: warning: vendor/amlogic/common/external/DTVKit/android-inputsource/app/src/main/Android.mk: inputsource: Unused source files: vendor/amlogic/common/external/DTVKit/android-inputsource/app/src/main/droidlogic/java
inputsource: platform 'amlogic'
[940/954] including vendor/amlogic/common/frameworks/Android.mk ...
vendor/amlogic/common/frameworks/core/jni/screencontrol/Android.mk:7: warning: libnativehelper/include_jni
vendor/amlogic/common/frameworks/core/jni/systemcontrol/Android.mk:10: warning: libnativehelper/include_jni
[941/954] including vendor/amlogic/common/gpu-lib/Android.mk ...
"the value of BOARD_INSTALL_VULKAN is "
TARGET_PRODUCT is kvim3
[946/954] including vendor/amlogic/common/prebuilt/Android.mk ...
"no bootaccelerate source code, add prebuilts"
"no exoplayer source code, add prebuilts"
[952/954] including vendor/amlogic/common/tv/tvserver/Android.mk ...
"have hardware/amlogic/media"
"have hardware/amlogic/media"
[954/954] including vendor/widevine/Android.mk ...
device/khadas/kvim3/Kernel.mk:174: warning: overriding commands for target `out/target/product/kvim3/obj/lib_vendor/mali.ko'
vendor/amlogic/common//gpu/gpu-v2.mk:23: warning: ignoring old commands for target `out/target/product/kvim3/obj/lib_vendor/mali.ko'
build/make/core/base_rules.mk:412: warning: overriding commands for target `out/target/product/kvim3/system/usr/icu/icudt60l.dat'
build/make/core/base_rules.mk:412: warning: ignoring old commands for target `out/target/product/kvim3/system/usr/icu/icudt60l.dat'
build/make/core/base_rules.mk:412: warning: overriding commands for target `out/host/linux-x86/usr/icu/icudt60l.dat'
build/make/core/base_rules.mk:412: warning: ignoring old commands for target `out/host/linux-x86/usr/icu/icudt60l.dat'
build/make/core/Makefile:28: warning: overriding commands for target `out/target/product/kvim3/obj/lib_vendor/ddr_window_64.ko'
device/khadas/kvim3/Kernel.mk:174: warning: ignoring old commands for target `out/target/product/kvim3/obj/lib_vendor/ddr_window_64.ko'
build/make/core/Makefile:28: warning: overriding commands for target `out/target/product/kvim3/vendor/etc/init/android.hardware.wifi@1.0-service.rc'
build/make/core/base_rules.mk:426: warning: ignoring old commands for target `out/target/product/kvim3/vendor/etc/init/android.hardware.wifi@1.0-service.rc'
[  0% 8/24746] build out/target/product/kvim3/obj/KERNEL_OBJ/.config
make: Entering directory '/home/anushanker/git_lfs/git-lfs-2.3.4/WORKING_DIRECTORY/common'
make[1]: Entering directory '/home/anushanker/git_lfs/git-lfs-2.3.4/WORKING_DIRECTORY/out/target/product/kvim3/obj/KERNEL_OBJ'
  GEN     ./Makefile
arch/arm/configs/kvim_a32_defconfig:498:warning: unexpected data: GONFIG_GPIOLIB=y
arch/arm/configs/kvim_a32_defconfig:499:warning: unexpected data: GONFIG_OF_GPIO=y
#
# configuration written to .config
#
make[1]: Leaving directory '/home/anushanker/git_lfs/git-lfs-2.3.4/WORKING_DIRECTORY/out/target/product/kvim3/obj/KERNEL_OBJ'
make: Leaving directory '/home/anushanker/git_lfs/git-lfs-2.3.4/WORKING_DIRECTORY/common'
[  0% 173/24746] make Image
FAILED: out/target/product/kvim3/obj/KERNEL_OBJ/arch/arm/boot/uImage 
/bin/bash -c "(make -j4 -C common O=../out/target/product/kvim3/obj/KERNEL_OBJ ARCH=arm CROSS_COMPILE=/opt/toolchains/gcc-linaro-6.3.1-2017.02-x86_64_arm-linux-gnueabihf/bin/arm-linux-gnueabihf- modules uImage ) && (make -j4 KERNEL_ARCH=arm CROSS_COMPILE=/opt/toolchains/gcc-linaro-6.3.1-2017.02-x86_64_arm-linux-gnueabihf/bin/arm-linux-gnueabihf- -f hardware/amlogic/wifi/configs/wifi_driver.mk multiwifi ) && (make -j4 KERNEL_ARCH=arm CROSS_COMPILE=/opt/toolchains/gcc-linaro-6.3.1-2017.02-x86_64_arm-linux-gnueabihf/bin/arm-linux-gnueabihf- -f hardware/amlogic/bluetooth/configs/bluetooth_driver.mk BLUETOOTH_INF= BCMBT ) && (: ) && (rm out/target/product/kvim3/obj/tb_modules -rf ) && (mkdir -p out/target/product/kvim3/obj/tb_modules ) && (cp hardware/amlogic/tb_modules/* out/target/product/kvim3/obj/tb_modules/ -airf ) && (echo \"make Amlogic TB Detect module KERNEL_ARCH is arm\" ) && (make -j4 -C \$(pwd)/out/target/product/kvim3/obj/KERNEL_OBJ M=\$(pwd)/out/target/product/kvim3/obj/tb_modules/ ARCH=arm CROSS_COMPILE=/opt/toolchains/gcc-linaro-6.3.1-2017.02-x86_64_arm-linux-gnueabihf/bin/arm-linux-gnueabihf- CONFIG_TB_DETECT=m modules ) && (mkdir -p out/target/product/kvim3/obj/lib_vendor ) && (rm out/target/product/kvim3/obj/lib_vendor/tb_detect.ko -f ) && (cp out/target/product/kvim3/obj/tb_modules/tb_detect.ko out/target/product/kvim3/obj/lib_vendor/tb_detect.ko -airf ) && (echo \"make Amlogic TB Detect module finished current dir is \$(pwd)\" ) && (mkdir -p out/target/product/kvim3/root/boot ) && (mkdir -p out/target/product/kvim3/obj/lib_vendor ) && (cp out/target/product/kvim3/obj/KERNEL_OBJ/drivers/usb/dwc3/dwc3.ko out/target/product/kvim3/obj/lib_vendor/ ; true ) && (cp out/target/product/kvim3/obj/KERNEL_OBJ/drivers/amlogic/usb/dwc_otg/310/dwc_otg.ko out/target/product/kvim3/obj/lib_vendor/ ; true ) && (PATH=\$(cd ./; pwd):\$PATH make -j4 -C /home/anushanker/git_lfs/git-lfs-2.3.4/WORKING_DIRECTORY/out/target/product/kvim3/obj/KERNEL_OBJ M=/home/anushanker/git_lfs/git-lfs-2.3.4/WORKING_DIRECTORY/out/target/product/kvim3/obj/media_modules ARCH=arm CROSS_COMPILE=/opt/toolchains/gcc-linaro-6.3.1-2017.02-x86_64_arm-linux-gnueabihf/bin/arm-linux-gnueabihf- CONFIG_AMLOGIC_MEDIA_VDEC_MPEG12=m CONFIG_AMLOGIC_MEDIA_VDEC_MPEG2_MULTI=m CONFIG_AMLOGIC_MEDIA_VDEC_MPEG4=m CONFIG_AMLOGIC_MEDIA_VDEC_MPEG4_MULTI=m CONFIG_AMLOGIC_MEDIA_VDEC_VC1=m CONFIG_AMLOGIC_MEDIA_VDEC_H264=m CONFIG_AMLOGIC_MEDIA_VDEC_H264_MULTI=m CONFIG_AMLOGIC_MEDIA_VDEC_H264_MVC=m CONFIG_AMLOGIC_MEDIA_VDEC_H265=m CONFIG_AMLOGIC_MEDIA_VDEC_VP9=m CONFIG_AMLOGIC_MEDIA_VDEC_MJPEG=m CONFIG_AMLOGIC_MEDIA_VDEC_MJPEG_MULTI=m CONFIG_AMLOGIC_MEDIA_VDEC_REAL=m CONFIG_AMLOGIC_MEDIA_VDEC_AVS=m CONFIG_AMLOGIC_MEDIA_VDEC_AVS_MULTI=m CONFIG_AMLOGIC_MEDIA_VDEC_AVS2=m CONFIG_AMLOGIC_MEDIA_VENC_H264=m CONFIG_AMLOGIC_MEDIA_VENC_H265=m EXTRA_CFLAGS+=-I./hardware/amlogic/media_modules/drivers/include modules; find /home/anushanker/git_lfs/git-lfs-2.3.4/WORKING_DIRECTORY/out/target/product/kvim3/obj/media_modules -name \"*.ko\" | PATH=\$(cd ./; pwd):\$PATH xargs -i cp {} /home/anushanker/git_lfs/git-lfs-2.3.4/WORKING_DIRECTORY/out/target/product/kvim3/obj/lib_vendor ) && (make -j4 -C /home/anushanker/git_lfs/git-lfs-2.3.4/WORKING_DIRECTORY/out/target/product/kvim3/obj/KERNEL_OBJ M=/home/anushanker/git_lfs/git-lfs-2.3.4/WORKING_DIRECTORY/out/target/product/kvim3/obj/npu_modules ARCH=arm CROSS_COMPILE=/opt/toolchains/gcc-linaro-6.3.1-2017.02-x86_64_arm-linux-gnueabihf/bin/arm-linux-gnueabihf- modules; find /home/anushanker/git_lfs/git-lfs-2.3.4/WORKING_DIRECTORY/out/target/product/kvim3/obj/npu_modules -name \"*.ko\" | xargs -i cp {} /home/anushanker/git_lfs/git-lfs-2.3.4/WORKING_DIRECTORY/out/target/product/kvim3/obj/lib_vendor ) && (make -j4 -C /home/anushanker/git_lfs/git-lfs-2.3.4/WORKING_DIRECTORY/out/target/product/kvim3/obj/KERNEL_OBJ M=/home/anushanker/git_lfs/git-lfs-2.3.4/WORKING_DIRECTORY/out/target/product/kvim3/obj/arm_isp_modules/v4l2_dev ARCH=arm CROSS_COMPILE=/opt/toolchains/gcc-linaro-6.3.1-2017.02-x86_64_arm-linux-gnueabihf/bin/arm-linux-gnueabihf- modules ) && (make -j4 -C /home/anushanker/git_lfs/git-lfs-2.3.4/WORKING_DIRECTORY/out/target/product/kvim3/obj/KERNEL_OBJ M=/home/anushanker/git_lfs/git-lfs-2.3.4/WORKING_DIRECTORY/out/target/product/kvim3/obj/arm_isp_modules/subdev/iq ARCH=arm CROSS_COMPILE=/opt/toolchains/gcc-linaro-6.3.1-2017.02-x86_64_arm-linux-gnueabihf/bin/arm-linux-gnueabihf- modules ) && (make -j4 -C /home/anushanker/git_lfs/git-lfs-2.3.4/WORKING_DIRECTORY/out/target/product/kvim3/obj/KERNEL_OBJ M=/home/anushanker/git_lfs/git-lfs-2.3.4/WORKING_DIRECTORY/out/target/product/kvim3/obj/arm_isp_modules/subdev/lens ARCH=arm CROSS_COMPILE=/opt/toolchains/gcc-linaro-6.3.1-2017.02-x86_64_arm-linux-gnueabihf/bin/arm-linux-gnueabihf- modules ) && (make -j4 -C /home/anushanker/git_lfs/git-lfs-2.3.4/WORKING_DIRECTORY/out/target/product/kvim3/obj/KERNEL_OBJ M=/home/anushanker/git_lfs/git-lfs-2.3.4/WORKING_DIRECTORY/out/target/product/kvim3/obj/arm_isp_modules/subdev/sensor ARCH=arm CROSS_COMPILE=/opt/toolchains/gcc-linaro-6.3.1-2017.02-x86_64_arm-linux-gnueabihf/bin/arm-linux-gnueabihf- modules ) && (find /home/anushanker/git_lfs/git-lfs-2.3.4/WORKING_DIRECTORY/out/target/product/kvim3/obj/arm_isp_modules -name *.ko | xargs -i cp {} /home/anushanker/git_lfs/git-lfs-2.3.4/WORKING_DIRECTORY/out/target/product/kvim3/obj/lib_vendor ) && (mkdir -p out/target/product/kvim3/vendor/lib/modules/ ) && (cp out/target/product/kvim3/obj/lib_vendor/* out/target/product/kvim3/vendor/lib/modules/ )"
make: Entering directory '/home/anushanker/git_lfs/git-lfs-2.3.4/WORKING_DIRECTORY/common'
make[1]: Entering directory '/home/anushanker/git_lfs/git-lfs-2.3.4/WORKING_DIRECTORY/out/target/product/kvim3/obj/KERNEL_OBJ'
  GEN     ./Makefile
scripts/kconfig/conf  --silentoldconfig Kconfig
  CHK     include/config/kernel.release
  CHK     include/config/kernel.release_full
  GEN     ./Makefile
  CHK     include/generated/uapi/linux/version.h
  CHK     scripts/mod/devicetable-offsets.h
  Using /home/anushanker/git_lfs/git-lfs-2.3.4/WORKING_DIRECTORY/common as source for kernel
  CHK     include/generated/utsrelease.h
  CHK     include/generated/timeconst.h
  CHK     include/generated/bounds.h
  CHK     include/generated/asm-offsets.h
  CALL    /home/anushanker/git_lfs/git-lfs-2.3.4/WORKING_DIRECTORY/common/scripts/checksyscalls.sh
  CHK     include/generated/compile.h
  GZIP    kernel/config_data.gz
  CHK     kernel/config_data.h
  Building modules, stage 2.
  Kernel: arch/arm/boot/Image is ready
  MODPOST 7 modules
  Kernel: arch/arm/boot/zImage is ready
  UIMAGE  arch/arm/boot/uImage
"mkimage" command not found - U-Boot images will not be built
/home/anushanker/git_lfs/git-lfs-2.3.4/WORKING_DIRECTORY/common/arch/arm/boot/Makefile:101: recipe for target 'arch/arm/boot/uImage' failed
make[2]: *** [arch/arm/boot/uImage] Error 1
arch/arm/Makefile:336: recipe for target 'uImage' failed
make[1]: *** [uImage] Error 2
make[1]: *** Waiting for unfinished jobs....
make[1]: Leaving directory '/home/anushanker/git_lfs/git-lfs-2.3.4/WORKING_DIRECTORY/out/target/product/kvim3/obj/KERNEL_OBJ'
Makefile:152: recipe for target 'sub-make' failed
make: *** [sub-make] Error 2
make: Leaving directory '/home/anushanker/git_lfs/git-lfs-2.3.4/WORKING_DIRECTORY/common'
[  0% 176/24746] //frameworks/base/core/jni:libandroid_runtime clang++ android/graphics/Bitmap.cpp
ninja: build stopped: subcommand failed.
14:25:19 ninja failed with: exit status 1

#### failed to build some targets (04:40 (mm:ss)) ####

@Saquib This kind of compilation error, forum netizens must have encountered, in fact, you can solve it yourself in the Forum Search.

sudo apt-get install u-boot-tools