android - 作为 : unrecognized option '-EL' while compiling android kernel on ubuntu 14

标签 android linux gcc makefile

ARCH=arm64
SUBARCH=arm64
CROSS_COMPILE=aarch64-linux-android-

下面是make的输出

# make
CHK     include/generated/uapi/linux/version.h
CHK     include/generated/utsrelease.h
CALL    scripts/checksyscalls.sh
CC      scripts/mod/empty.o
as: unrecognized option '-EL'
make[2]: *** [scripts/mod/empty.o] Error 1
make[1]: *** [scripts/mod] Error 2    
make: *** [scripts] Error 2

仍然使用 binutils (/usr/bin/as) 中的“as”而不是 /usr/bin/aarch64-linux-android-as 尽管有 gcc 版本,gcc-4.4 gcc-4.6 gcc-4.8,Ubuntu 总是安装相同的 binutils

重命名 /usr/bin/as 没有帮助 & make 失败

如何在交叉编译时让“make”使用正确的“as”。

最佳答案

在内核上放置make clean。然后编译问题就解决了。

关于android - 作为 : unrecognized option '-EL' while compiling android kernel on ubuntu 14,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/31124358/

相关文章:

java - 获取变量值android

android - 带有 Google Map V2 和 SupportMapFragment 的空白 map (不,这不是 API key 问题)

java - 错误: cannot find symbol variable toolbar

android - 如何防止我的应用程序在使用 JSON 数据时意外崩溃 "force close"并改为处理异常?

c - 如何让 GCC 在没有内置函数的情况下为大端存储生成 bswap 指令?

linux - 为 IPSec 使用 Linux 内核加密 API

c++ - Linux | C++ 中的段错误 - 由于函数 ifstream

linux - xargs 错误地将我的 src 目录复制到一个 tgt 目录

gcc - 在 C 代码 (GCC) 中定义一个程序段

c - Eclipse C/C++ 无法运行程序