android cupcake源码编译问题

build/core/product_config.mk:261: WARNING: adding test OTA key

============================================

TARGET_PRODUCT=generic

TARGET_BUILD_VARIANT=eng

TARGET_SIMULATOR=

TARGET_BUILD_TYPE=release

TARGET_ARCH=arm

HOST_ARCH=x86

HOST_OS=linux

HOST_BUILD_TYPE=release

BUILD_ID=

============================================

build/core/find-jdk-tools-jar.sh: line 5: [: too many arguments

*** Build configuration changed: "generic-eng-sdk-{}" -> "generic-eng-{}"

*** Forcing "make installclean"...

*** Done with the cleaning, now starting the real build.

frameworks/policies/base/PolicyConfig.mk:22: *** No module defined for the given PRODUCT_POLICY (android.policy_phone).  Stop.

 

问题来源:javac没有加入PATH环境变量中

解决方法:将javac所在路径加入PATH环境变量

 

---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

build/core/product_config.mk:261: WARNING: adding test OTA key

============================================

TARGET_PRODUCT=generic

TARGET_BUILD_VARIANT=eng

TARGET_SIMULATOR=

TARGET_BUILD_TYPE=release

TARGET_ARCH=arm

HOST_ARCH=x86

HOST_OS=linux

HOST_BUILD_TYPE=release

BUILD_ID=

============================================

frameworks/policies/base/PolicyConfig.mk:22: *** No module defined for the given PRODUCT_POLICY (android.policy_phone).  Stop.

 

解决方法:

修改build/tools/findleaves.sh 

find "${@:0:$nargs}" $findargs -type f -name "$filename" -print |

替换成:

find "${@:1:$nargs-1}" $findargs -type f -name "$filename" -print |

 

------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

frameworks/base/tools/aidl/AST.cpp:10: error: ‘fprintf’ was not declared in this scope

 

frameworks/base/tools/aidl/Type.cpp:194: error: ‘stderr’ was not declared in this scope

 

external/srec/tools/grxmlcompile/netw_arc.h:318: error: ‘printf’ was not declared in this scope

 

解决方法:

添加头文件 #include <stdio.h>

 

development/emulator/qtools/trace_reader.cpp:1012: error: invalid conversion from ‘const char*’ to ‘char*’

 

解决方法:

添加强制转换。

 

frameworks/base/tools/localize/file_utils.cpp:74: error: ‘stderr’ was not declared in this scope

frameworks/base/tools/localize/file_utils.cpp:74: error: ‘fprintf’ was not declared in this scope

frameworks/base/tools/localize/merge_res_and_xliff.cpp:36: error: ‘printf’ was not declared in this scope

frameworks/base/tools/localize/xmb.cpp:66: error: ‘sprintf’ was not declared in this scope

frameworks/base/tools/localize/Perforce.cpp:27: error: ‘printf’ was not declared in this scope

frameworks/base/tools/localize/SourcePos.cpp:87: error: ‘fprintf’ was not declared in this scope

frameworks/base/tools/localize/Values.cpp:76: error: ‘sprintf’ was not declared in this scope

frameworks/base/tools/localize/XLIFFFile.cpp:372: error: ‘sprintf’ was not declared in this scope

frameworks/base/tools/localize/localize_test.cpp:12: error: ‘stderr’ was not declared in this scope

frameworks/base/tools/localize/merge_res_and_xliff_test.cpp:15: error: ‘stderr’ was not declared in this scope

 

解决方法:

添加头文件 #include <stdio.h>

 

development/emulator/qtools/dmtrace.cpp:166: error: invalid conversion from ‘const char*’ to ‘char*’

 

解决方法:

添加强制转换。

 

java.util.zip.ZipException: duplicate entry: hyts_Foo.c

at java.util.zip.ZipOutputStream.putNextEntry(ZipOutputStream.java:192)

at java.util.jar.JarOutputStream.putNextEntry(JarOutputStream.java:109)

at sun.tools.jar.Main.addFile(Main.java:731)

at sun.tools.jar.Main.update(Main.java:585)

at sun.tools.jar.Main.run(Main.java:220)

at sun.tools.jar.Main.main(Main.java:1167)

make: *** [out/target/common/obj/JAVA_LIBRARIES/core-tests_intermediates/javalib.jar] Error 1

make: *** Deleting file `out/target/common/obj/JAVA_LIBRARIES/core-tests_intermediates/javalib.jar'

 

解决方法:

卸载JDK6,安装JDK5

  • 0
    点赞
  • 2
    收藏
    觉得还不错? 一键收藏
  • 2
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论 2
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值