MAC编译Android源码 prebuilts/misc/darwin-x86/bison/bison出错

错误提示:

[  0% 438/72411] //external/one-true-awk:awk yacc awkgram.y

FAILED: out/soong/.intermediates/external/one-true-awk/awk/android_arm64_armv8-a_core/gen/yacc/external/one-true-awk/awkgram.c out/soong/.intermediates/external/one-true-awk/awk/android_arm64_armv8-a_core/gen/yacc/external/one-true-awk/awkgram.h 

BISON_PKGDATADIR=external/bison/data prebuilts/misc/darwin-x86/bison/bison -d  --defines=out/soong/.intermediates/external/one-true-awk/awk/android_arm64_armv8-a_core/gen/yacc/external/one-true-awk/awkgram.h -o out/soong/.intermediates/external/one-true-awk/awk/android_arm64_armv8-a_core/gen/yacc/external/one-true-awk/awkgram.c external/one-true-awk/awkgram.y

[  0% 441/72411] //system/libvintf:ass...tf clang++ assemble_vintf.cpp [darwin]

ninja: build stopped: subcommand failed.

11:01:56 ninja failed with: exit status 1


解决方法:

1、brew install bison

2、rm //prebuilts/misc/darwin-x86/bison/bison

3、建立软连接

sudo ln -s /usr/local/Cellar/bison/3.0.4_1/bin/bison /Volumes/android/code/prebuilts/misc/darwin-x86/bison/bison

4、重新make


参考地址:

https://groups.google.com/forum/?fromgroups#!topic/android-building/D1-c5lZ9Oco

你可能感兴趣的:(AOSP)