mkdtimg: No such file or directory

Showing results for 
Show  only  | Search instead for 
Did you mean: 

mkdtimg: No such file or directory

Contributor III

Hello I am trying to build the android OS for the evk_7ulp-userdebug, or specifically

./ -j1 2>&1 | tee build-log.txt

This is my second time with the same error. Currently I am on ubuntu 18. Except for the version I have been following the instructions here

and checking for differences here

The only two package differences I have are 

liblzo2-devlzop was  changed to liblzo2-dev

and libz-dev was changed to zlib1g-dev

Doesn't look like there are any other posts missing this specific file so any help is greatly appreciated. 

Starting ninja...
[ 13% 11529/87697] build out/target/product/evk_7ulp/dtbo-no-footer-imx7ulp.img

FAILED: out/target/product/evk_7ulp/dtbo-no-footer-imx7ulp.img
/bin/bash -c "for dtsplat in imx7ulp:imx7ulp-evkb.dtb imx7ulp-mipi:imx7ulp-evkb-rm68200-wxga.dtb; do DTS_PLATFORM=\`echo \$dtsplat | cut -d':' -f1\`; DTB_NAME=\`echo \$dtsplat | cut -d':' -f2\`; DTB=\`echo out/target/product/evk_7ulp/obj/KERNEL_OBJ/arch/arm/boot/dts//\${DTB_NAME}\`; DTBO_IMG_NO_FOOTER=\`echo out/target/product/evk_7ulp/dtbo-no-footer-\${DTS_PLATFORM}.img\`; out/host/linux-x86/bin/mkdtimg create \$DTBO_IMG_NO_FOOTER \$DTB; done"
/bin/bash: out/host/linux-x86/bin/mkdtimg: No such file or directory
/bin/bash: out/host/linux-x86/bin/mkdtimg: No such file or directory
ninja: build stopped: subcommand failed.
16:57:34 ninja failed with: exit status 1

#### failed to build some targets (05:27 (mm:ss)) ####


My entire build log is attached. Thank you

Labels (1)
Tags (2)
0 Kudos
4 Replies

Contributor I

编译aosp 源码之后,mkdtimg在 out/host/linux-x86/bin 里面。
After compiling aosp source code, mkdtimg is in out/host/linux-x86/bin

export PATH=/your path/out/host/linux-x86/bin


0 Kudos

NXP TechSupport
NXP TechSupport

Hello meb99,

For this error you must erase the entire android and reinstall again, this error won´t happens if you download correctly the android.



0 Kudos

Contributor III

I appreciate the response. I have now done this 4 times. I just re-downloaded everything from scratch, including a fresh ubuntu install for sanity, and tried this on ubuntu 20 for fun. I got to the exact same point. So I have done this on ubuntu 16, 18, and 20 twice. And I always get the same error.


I havn't successfully finished a build yet, but I was able to get past that error by copying ./prebuilts/misc/linux-x86/libufdt/mkdtimg to out/host/linux-x86/bin/mkdtimg

I am starting to feel like there might be a bug unless there is something I am just missing in all my builds.

0 Kudos

Contributor III

One update. I realized that what looks like the bin directory with the missing file is located in 


instead of 


tried just copying the entire directory to where it is looking for and I get the same error even though it is definitely present. 

0 Kudos