小编use*_*101的帖子

Bamboo Agent:找不到Build Tools修订版23.0.3

我使用Linux代理池来构建我的应用程序.偶尔会出现代理导致构建失败并出现错误:

FAILURE: Build failed with an exception.
What went wrong:
Execution failed for task ':ComponentThatReqBuildToolsRev23.0.3:preBuild'.
> failed to find Build Tools revision 23.0.3
Run Code Online (Sandbox Code Playgroud)

因为我的构建代理是远程的(android预安装/ opt/android-sdk-linux/tools/android),我无法预安装平台工具,构建工具等所以我的项目中包含了一个makefile.签出代码后,它调用makefile中的方法:

#!/bin/bash
git submodule init
git submodule update
make updateSDK
# EOF
Run Code Online (Sandbox Code Playgroud)

makefile中的方法是:

PACKAGES = "tools,platform-tools,build-tools-21.1.2,android-22,build-tools-23.0.3,android-21,extra-android-support,extra-android-m2repository,extra-google-m2repository,extra-google,google_play_services"

updateSDK:
    (sleep 5 && while [ 1 ]; do sleep 1; echo y; done) \
        | android --clear-cache update sdk --no-ui --all \
        --filter $(PACKAGES)
Run Code Online (Sandbox Code Playgroud)

在成功的案例中,Bamboo的日志显示:

Refresh Sources:
Fetching https://dl.google.com/android/repository/addons_list-2.xml
Validate XML
Parse XML
Fetched Add-ons List successfully
Refresh Sources …
Run Code Online (Sandbox Code Playgroud)

android makefile bamboo android-build android-sdk-manager

6
推荐指数
0
解决办法
397
查看次数