编译正点原子LINUXB报错make: arm-linux-gnueabihf-gcc:命令未找到

编译正点原子LINUXB报错make: arm-linux-gnueabihf-gcc:命令未找到

    • 1.报错内容
    • 2.解决办法
    • 3./bin/sh: 1: lzop: not found
    • 4.编译成功

1.报错内容

make: arm-linux-gnueabihf-gcc:命令未找到
  CHK     include/config/kernel.release
  CHK     include/generated/uapi/linux/version.h
  CC      scripts/mod/empty.o
/bin/sh: 1: arm-linux-gnueabihf-gcc: not found
make[2]: *** [scripts/mod/empty.o] 错误 127
make[2]: *** 正在等待未完成的任务....
  CC      scripts/mod/devicetable-offsets.s
/bin/sh: 1: arm-linux-gnueabihf-gcc: not found
make[2]: *** [scripts/mod/devicetable-offsets.s] 错误 127
  CHK     include/generated/utsrelease.h
make[1]: *** [scripts/mod] 错误 2
make: *** [scripts] 错误 2
make: *** 正在等待未完成的任务.

2.解决办法

需要在 Makefile 添加完整路径内容:
在这里插入图片描述

ARCH            ?= arm
CROSS_COMPILE	?= /usr/local/arm/gcc-linaro-4.9.4-2017.01-x86_64_arm-linux-gnueabihf/bin/arm-linux-gnueabihf-

3./bin/sh: 1: lzop: not found

/bin/sh: 1: lzop: not found
make[2]: *** [arch/arm/boot/compressed/piggy.lzo] 错误 1
make[1]: *** [arch/arm/boot/compressed/vmlinux] 错误 2
make: *** [zImage] 错误 2
make: *** 正在等待未完成的任务....
  MODPOST 77 modules
make: INTERNAL: Exiting with 17 jobserver tokens available; should be 16!

解决办法:

sudo apt-get install lzop

4.编译成功

  SHIPPED arch/arm/boot/compressed/lib1funcs.S
  SHIPPED arch/arm/boot/compressed/ashldi3.S
  SHIPPED arch/arm/boot/compressed/bswapsdi2.S
  AS      arch/arm/boot/compressed/hyp-stub.o
  AS      arch/arm/boot/compressed/lib1funcs.o
  AS      arch/arm/boot/compressed/ashldi3.o
  AS      arch/arm/boot/compressed/bswapsdi2.o
  AS      arch/arm/boot/compressed/piggy.lzo.o
  LD      arch/arm/boot/compressed/vmlinux
  OBJCOPY arch/arm/boot/zImage
  Kernel: arch/arm/boot/zImage is ready

你可能感兴趣的:(arm开发,linux,运维)