1

我一直在关注这个链接Android kernel compile and test with Android Emulator来编译 android 源代码。

但是在尝试使用编译源代码时

make ARCH=arm CROSS_COMPILE=/home/lares/prebuilt/linux-x86/toolchain/arm-eabi-4.2.1/bin/arm-eabi-

我收到此错误。

lares@lares-Inspiron-1545:~/android_kernel$ make ARCH=arm CROSS_COMPILE=/home/lares/prebuilt/linux-x86/toolchain/arm-eabi-4.2.1/bin/arm-eabi-
    make: execvp: /home/lares/prebuilt/linux-x86/toolchain/arm-eabi-4.2.1/bin/arm-eabi-gcc: Permission denied
    scripts/kconfig/conf -s arch/arm/Kconfig
    make[2]: execvp: scripts/kconfig/conf: Permission denied
    make[2]: *** [silentoldconfig] Error 127
    make[1]: *** [silentoldconfig] Error 2
      CHK     include/linux/version.h
    make[1]: `include/asm-arm/mach-types.h' is up to date.
    make: *** No rule to make target `include/config/auto.conf', needed by `include/config/kernel.release'.  Stop.

通过将权限分配给适当的目录来解决这个问题后,我得到了这个。

lares@lares-Inspiron-1545:~/android_kernel$ make ARCH=arm  CROSS_COMPILE=/home/lares/prebuilt/linux-x86/toolchain/arm-eabi-4.2.1/bin/arm-eabi-
    scripts/kconfig/conf -s arch/arm/Kconfig
      CHK     include/linux/version.h
    make[1]: `include/asm-arm/mach-types.h' is up to date.
      CHK     include/linux/utsrelease.h
      UPD     include/linux/utsrelease.h
      SYMLINK include/asm -> include/asm-arm
      CC      kernel/bounds.s
    arm-eabi-gcc: error trying to exec 'cc1': execvp: No such file or directory
    make[1]: *** [kernel/bounds.s] Error 1
    make: *** [prepare0] Error 2

有人可以帮我吗?

4

1 回答 1

1

部分(或全部)路径的权限/home/lares/prebuilt/linux-x86/toolchain/arm-eabi-4.2.1/bin/arm-eabi-gcc未设置为读取加执行。

如果您具有 root 访问权限,请检查每个路径组件并进行适当调整。否则,请让您的系统管理员修复它。

作为最初的问题,其他交叉开发工具(包括头文件和库)存在其他权限问题的可能性相当高。

于 2011-07-12T21:54:00.263 回答