I am building android-11.0.0_r4 for the reference board DragonBoard 845c. I have setup my build by executing source build/envsetup.sh and then lunch db845c-userdebug followed by make -j24. I am getting the following build error:

[ 99% 24669/24682] Target system fs image: out/target/product/db845c/obj/PACKAGING/systemimage_intermediates/system.img FAILED: out/target/product/db845c/obj/PACKAGING/systemimage_intermediates/system.img /bin/bash -c "(if [ -d out/target/product/db845c/system/vendor ] && [ ! -h out/target/product/db845c/system/vendor ]; then echo 'Non-symlink out/target/product/db845c/system/vendor detected!' 1>&2; echo 'You cannot install files to out/target/product/db845c/system/vendor while building a separate vendor.img!' 1>&2; exit 1; fi ) && (ln -sf /vendor out/target/product/db845c/system/vendor ) && (if [ -d out/target/product/db845c/system/system_ext ] && [ ! -h out/target/product/db845c/system/system_ext ]; then echo 'Non-symlink out/target/product/db845c/system/system_ext detected!' 1>&2; echo 'You cannot install files to out/target/product/db845c/system/system_ext while building a separate system_ext.img!' 1>&2; exit 1; fi ) && (ln -sf /system_ext out/target/product/db845c/system/system_ext ) && (mkdir -p out/target/product/db845c/obj/PACKAGING/systemimage_intermediates/ out/target/product/db845c/obj/PACKAGING/systemimage_intermediates && rm -rf out/target/product/db845c/obj/PACKAGING/systemimage_intermediates/system_image_info.txt ) && (echo \"system_fs_type=ext4\" >> out/target/product/db845c/obj/PACKAGING/systemimage_intermediates/system_image_info.txt ) && (echo \"system_selinux_fc=out/target/product/db845c/obj/ETC/file_contexts.bin_intermediates/file_contexts.bin\" >> out/target/product/db845c/obj/PACKAGING/systemimage_intermediates/system_image_info.txt ) && (echo \"ext_mkuserimg=mkuserimg_mke2fs\" >> out/target/product/db845c/obj/PACKAGING/systemimage_intermediates/system_image_info.txt ) && (echo \"fs_type=ext4\" >> out/target/product/db845c/obj/PACKAGING/systemimage_intermediates/system_image_info.txt ) && (echo \"extfs_sparse_flag=-s\" >> out/target/product/db845c/obj/PACKAGING/systemimage_intermediates/system_image_info.txt ) && (echo \"squashfs_sparse_flag=-s\" >> out/target/product/db845c/obj/PACKAGING/systemimage_intermediates/system_image_info.txt ) && (echo \"f2fs_sparse_flag=-S\" >> out/target/product/db845c/obj/PACKAGING/systemimage_intermediates/system_image_info.txt ) && (echo \"root_dir=out/target/product/db845c/root\" >> out/target/product/db845c/obj/PACKAGING/systemimage_intermediates/system_image_info.txt ) && (echo \"use_dynamic_partition_size=true\" >> out/target/product/db845c/obj/PACKAGING/systemimage_intermediates/system_image_info.txt ) && (echo \"skip_fsck=true\" >> out/target/product/db845c/obj/PACKAGING/systemimage_intermediates/system_image_info.txt ) && (PATH=out/host/linux-x86/bin/:system/extras/ext4_utils/:\$PATH out/host/linux-x86/bin/build_image out/target/product/db845c/system out/target/product/db845c/obj/PACKAGING/systemimage_intermediates/system_image_info.txt out/target/product/db845c/obj/PACKAGING/systemimage_intermediates/system.img out/target/product/db845c/system || ( mkdir -p \${DIST_DIR}; cp out/target/product/db845c/installed-files.txt \${DIST_DIR}/installed-files-rescued.txt; exit 1 ) )" 2022-01-03 08:32:35 - build_image.py - ERROR : Failed to build out/target/product/db845c/obj/PACKAGING/systemimage_intermediates/system.img from out/target/product/db845c/system Out of space? Out of inodes? The tree size of /home/rftest/UWB/dragon/out/soong/.temp/tmpGp99Zy is 1169788928 bytes (1115 MB), with reserved space of 0 bytes (0 MB). The max image size for filesystem files is 1186566144 bytes (1131 MB), out of a total partition size of 1186566144 bytes (1131 MB).

I have searched for answers and have noted that the max image size is 1186566144 bytes (1131 MB) while the file size of /home/rftest/UWB/dragon/out/soong/.temp/tmpGp99Zy is 1169788928 bytes (1115 MB) which is less than the max image size. I have tried to redirect the output of the build by - export OUT_DIR_COMMON_BASE=/ext4/path/to/builds but this has not fixed the issue.

how do I fix this error

*** UPDATE 1/4/2022 ***
I solved this issue after viewing Android AOSP build failing in build_image.py for android-10.0.0_r39

I added BOARD_USERDATAIMAGE_FILE_SYSTEM_TYPE := ext4 to my /home/dragon/device/linaro/dragonboard/db845c/BoardConfig.mk then did a make clean and make -j24 for a successful build

0

There are 0 best solutions below