Followed guide here: https://source.android.com/setup/build/building-kernels
mkdir android-kernel && cd android-kernel
repo init -u https://android.googlesource.com/kernel/manifest -b android-msm-bonito-4.9-android11-qpr2
repo sync
build/build.sh
It runs for ~7min then fails @
Creating initramfs: build/build.sh: line 967: mkbootfs: command not found
I found the mkbootfs
binary, in many locations actually, and all of them, when executed, say "command not found"!
- I tried
chmod 777
&chmod +x
, but same issue. - Tried
sudo
as well. - I tried adding
$HOME/android/aosp-kernel/build/build-tools/path/linux-x86
to myPATH
but same results.
build\build.sh
Line 967 is not where the mkbootfs
cmd is, but it does appear on line 980:
mkbootfs "${INITRAMFS_STAGING_DIR}" >"${MODULES_STAGING_DIR}/initramfs.cpio"
What is the expected result when mkbootfs
is run without parameters??
I'd think this would be easy. For some reason, I can't find anything helpful on the net.
Please help.
file mkbootfs
on the binary to see for what platform it has been compiled.