库解析为没有project.properties文件的路径

use*_*490 12 ant android jenkins actionbarsherlock

我无法使用Jenkins构建项目并引用Sherlock项目库.

我可以在我的本地系统上使用ant构建项目.问题似乎是在构建服务器上引用Sherlock库.

我将环境变量传递给ant,其中包含Sherlock库项目的相对路径:

android.library.reference.1=../../buildlibraries/androidlibraries/sherlock/library
Run Code Online (Sandbox Code Playgroud)

我收到了这个错误.

**BUILD FAILED**
/SDK/android-sdk-macosx/tools/ant/build.xml:595: 
The following error occurred while executing this line:
/SDK/android-sdk-macosx/tools/ant/build.xml:571: 
../../buildlibraries/androidlibraries/sherlock/library resolve to a path with 
no project.properties file for project /Users/Jenkins/buildlibraries/androidlibraries/sherlock/library
Run Code Online (Sandbox Code Playgroud)

我检查了那个位置确实存在project.properties文件.

它具有以下属性:

android.library=true
# Project target.
target=android-14
Run Code Online (Sandbox Code Playgroud)

use*_*490 3

我通过编辑和签入具有相同属性的 project.properties 文件解决了这个问题:android.library.reference.1=../../buildlibraries/androidlibraries/sherlock/library

我不知道为什么它有效。为什么 ant 会关心该属性是由 Jenkins 传入还是在项目的属性文件中声明?

现在,我的 project.properties 文件中有两条路径:一条用于本地构建,一条用于 Jenkins 上的构建。