您的位置:首页 > 移动开发 > Android开发

android cupcake源码编译问题

2010-08-30 22:27 429 查看
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
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: