Thank you @Frank .
I got building Android source code error on Ubuntu 20.04 VM.
However same steps I did on Ubuntu 18.04 worked well on my another Ubuntu 18.04 VM.
I have remove all of folder and run repo sync but get the same error message while running make -j2 otapackage
on Ubuntu 20.04 VM.
I run repo init -u https://github.com/khadas/android_manifest.git -b khadas-vims-pie
to have android source code.
Thanks and my console screen shot shown as below:
============================================
amo@ubuntu:~/workspace/vim3/bsp$ make -j2 otapackage
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=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-5.8.0-41-generic-x86_64-Ubuntu-20.04.1-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
============================================
[1/1] out/soong/.minibootstrap/minibp out/soong/.bootstrap/build.ninja
[55/56] glob prebuilts/ndk/stl.bp
[77/77] out/soong/.bootstrap/bin/soong_build out/soong/build.ninja
out/build-kvim3-cleanspec.ninja is missing, 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
out/build-kvim3.ninja is missing, 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-20210201.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 ...
/bin/bash: ifconfig: command 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: " Mon Feb 1 00:10:37 PST 2021"
builder name: " amo"
branch name: "* (no branch)"
build mode: userdebug
host name: "ubuntu"
/bin/bash: ifconfig: command not found
host IP: ""
path: "/home/amo/workspace/vim3/bsp/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'
[ 99% 1200/1201] glob vendor/amlogic/common/interfaces/tvserver/1.0/src
[ 0% 6/71947] Yacc: dtc <= external/dtc/dtc-parser.y
external/dtc/dtc-parser.y: conflicts: 3 shift/reduce
[ 0% 10/71947] host C: dtc <= external/dtc/checks.c
FAILED: out/host/linux-x86/obj/EXECUTABLES/dtc_intermediates/checks.o
/bin/bash -c "PWD=/proc/self/cwd prebuilts/clang/host/linux-x86/clang-4691093/bin/clang -I external/dtc -I out/host/linux-x86/obj/EXECUTABLES/dtc_intermediates -I out/host/linux-x86/gen/EXECUTABLES/dtc_intermediates -I libnativehelper/include_jni \$(cat out/host/linux-x86/obj/EXECUTABLES/dtc_intermediates/import_includes) -I system/core/include -I system/media/audio/include -I hardware/libhardware/include -I hardware/libhardware_legacy/include -I hardware/ril/include -I libnativehelper/include -I frameworks/native/include -I frameworks/native/opengl/include -I frameworks/av/include -c -Wa,--noexecstack -fPIC -U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=2 -fstack-protector -D__STDC_FORMAT_MACROS -D__STDC_CONSTANT_MACROS --gcc-toolchain=prebuilts/gcc/linux-x86/host/x86_64-linux-glibc2.15-4.8 --sysroot prebuilts/gcc/linux-x86/host/x86_64-linux-glibc2.15-4.8/sysroot -fstack-protector-strong -m64 -DANDROID -fmessage-length=0 -W -Wall -Wno-unused -Winit-self -Wpointer-arith -no-canonical-prefixes -DNDEBUG -UDEBUG -fno-exceptions -Wno-multichar -O2 -g -fno-strict-aliasing -fdebug-prefix-map=/proc/self/cwd= -D__compiler_offsetof=__builtin_offsetof -Werror=int-conversion -Wno-reserved-id-macro -Wno-format-pedantic -Wno-unused-command-line-argument -fcolor-diagnostics -Wno-expansion-to-defined -Wno-zero-as-null-pointer-constant -fdebug-prefix-map=\$PWD/= -target x86_64-linux-gnu -Bprebuilts/gcc/linux-x86/host/x86_64-linux-glibc2.15-4.8/x86_64-linux/bin -std=gnu99 -Wall -Werror -Wno-sign-compare -Wno-missing-field-initializers -Wno-unused-parameter -fPIE -Werror=int-to-pointer-cast -Werror=pointer-to-int-cast -Werror=address-of-temporary -Werror=return-type -Wno-tautological-constant-compare -Wno-null-pointer-arithmetic -Wno-enum-compare -Wno-enum-compare-switch -MD -MF out/host/linux-x86/obj/EXECUTABLES/dtc_intermediates/checks.d -o out/host/linux-x86/obj/EXECUTABLES/dtc_intermediates/checks.o external/dtc/checks.c"
prebuilts/clang/host/linux-x86/clang-4691093/bin/clang.real: error while loading shared libraries: libtinfo.so.5: cannot open shared object file: No such file or directory
[ 0% 11/71947] host C: dtc <= external/dtc/data.c
FAILED: out/host/linux-x86/obj/EXECUTABLES/dtc_intermediates/data.o
/bin/bash -c "PWD=/proc/self/cwd prebuilts/clang/host/linux-x86/clang-4691093/bin/clang -I external/dtc -I out/host/linux-x86/obj/EXECUTABLES/dtc_intermediates -I out/host/linux-x86/gen/EXECUTABLES/dtc_intermediates -I libnativehelper/include_jni \$(cat out/host/linux-x86/obj/EXECUTABLES/dtc_intermediates/import_includes) -I system/core/include -I system/media/audio/include -I hardware/libhardware/include -I hardware/libhardware_legacy/include -I hardware/ril/include -I libnativehelper/include -I frameworks/native/include -I frameworks/native/opengl/include -I frameworks/av/include -c -Wa,--noexecstack -fPIC -U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=2 -fstack-protector -D__STDC_FORMAT_MACROS -D__STDC_CONSTANT_MACROS --gcc-toolchain=prebuilts/gcc/linux-x86/host/x86_64-linux-glibc2.15-4.8 --sysroot prebuilts/gcc/linux-x86/host/x86_64-linux-glibc2.15-4.8/sysroot -fstack-protector-strong -m64 -DANDROID -fmessage-length=0 -W -Wall -Wno-unused -Winit-self -Wpointer-arith -no-canonical-prefixes -DNDEBUG -UDEBUG -fno-exceptions -Wno-multichar -O2 -g -fno-strict-aliasing -fdebug-prefix-map=/proc/self/cwd= -D__compiler_offsetof=__builtin_offsetof -Werror=int-conversion -Wno-reserved-id-macro -Wno-format-pedantic -Wno-unused-command-line-argument -fcolor-diagnostics -Wno-expansion-to-defined -Wno-zero-as-null-pointer-constant -fdebug-prefix-map=\$PWD/= -target x86_64-linux-gnu -Bprebuilts/gcc/linux-x86/host/x86_64-linux-glibc2.15-4.8/x86_64-linux/bin -std=gnu99 -Wall -Werror -Wno-sign-compare -Wno-missing-field-initializers -Wno-unused-parameter -fPIE -Werror=int-to-pointer-cast -Werror=pointer-to-int-cast -Werror=address-of-temporary -Werror=return-type -Wno-tautological-constant-compare -Wno-null-pointer-arithmetic -Wno-enum-compare -Wno-enum-compare-switch -MD -MF out/host/linux-x86/obj/EXECUTABLES/dtc_intermediates/data.d -o out/host/linux-x86/obj/EXECUTABLES/dtc_intermediates/data.o external/dtc/data.c"
prebuilts/clang/host/linux-x86/clang-4691093/bin/clang.real: error while loading shared libraries: libtinfo.so.5: cannot open shared object file: No such file or directory
ninja: build stopped: subcommand failed.
00:11:23 ninja failed with: exit status 1
#### failed to build some targets (02:14 (mm:ss)) ####