我尝试从https://github.com/peyo-hd/device_brcm_rpi2为 Raspberry Pi 2 构建 android 内核,但在构建 dtbs 时遇到以下构建错误:
$ ARCH=arm CROSS_COMPILE=arm-linux-gnueabihf- make dtbs
CHK include/config/kernel.release
CHK include/generated/uapi/linux/version.h
CHK include/generated/utsrelease.h
make[1]: `include/generated/mach-types.h' is up to date.
CHK include/generated/bounds.h
CHK include/generated/timeconst.h
CHK include/generated/asm-offsets.h
CALL scripts/checksyscalls.sh
DTC arch/arm/boot/dts/overlays/vc4-kms-v3d-overlay.dtb
arch/arm/boot/dts/overlays/vc4-kms-v3d-overlay.dts:8:39: fatal error: dt-bindings/clock/bcm2835.h: No such file or directory
compilation terminated.
make[2]: *** [arch/arm/boot/dts/overlays/vc4-kms-v3d-overlay.dtb] Error 1
make[1]: *** [arch/arm/boot/dts/overlays] Error 2
make: *** [dtbs] Error 2
知道我已经使用以下方法成功构建了 zImage:
$ ARCH=arm CROSS_COMPILE=arm-linux-gnueabihf- make zImage