Bug 1532284 - Build wrench on Android. r=glandium

Depends on D22377

Differential Revision: https://phabricator.services.mozilla.com/D22378

--HG--
extra : moz-landing-system : lando
This commit is contained in:
Kartikaya Gupta 2019-03-08 00:37:46 +00:00
parent b4182026be
commit 1889f4e164
3 changed files with 42 additions and 0 deletions

View File

@ -23,6 +23,7 @@ apt-get install -y \
libfontconfig1-dev \
libgl1-mesa-dev \
libx11-dev \
openjdk-8-jdk \
pkg-config \
python \
python-mako \

View File

@ -235,3 +235,37 @@ jobs:
- 'gfx/wr/**'
- 'taskcluster/scripts/misc/tooltool-download.sh'
- 'taskcluster/scripts/misc/wrench-windows-tests.sh'
wrench-android-build:
description: Build wrench for Android
worker-type: aws-provisioner-v1/gecko-{level}-b-android
worker:
max-run-time: 5400
docker-image: {in-tree: webrender}
artifacts:
- type: file
name: public/build/wrench-debug.apk
path: /builds/worker/checkouts/gecko/gfx/wr/target/android-artifacts/app/build/outputs/apk/app-debug.apk
run:
using: run-task
command: >-
cd $GECKO_PATH &&
./mach artifact toolchain -v $MOZ_TOOLCHAINS &&
export PATH=$PATH:$PWD/rustc/bin:$PWD/android-gradle-dependencies/gradle-dist/bin &&
export ANDROID_HOME=$PWD/android-sdk-linux &&
export NDK_HOME=$PWD/android-ndk &&
mv wrench-deps/{vendor,.cargo,cargo-apk} gfx/wr &&
cd gfx/wr/wrench &&
../cargo-apk/bin/cargo-apk build --frozen --verbose
toolchains:
- android-gradle-dependencies
- android-ndk-linux
- android-sdk-linux
- linux64-rust-android
- wrench-deps
treeherder:
platform: android-4-0-armv7-api16/debug
symbol: WR(B)
when:
files-changed:
- 'gfx/wr/**'

View File

@ -19,6 +19,13 @@ mkdir .cargo
cargo vendor --relative-path --sync ./Cargo.lock > .cargo/config
mkdir wrench-deps
mv vendor .cargo wrench-deps/
mkdir wrench-deps/cargo-apk
# Until there's a version of cargo-apk published on crates.io that has
# https://github.com/tomaka/android-rs-glue/pull/205 and
# https://github.com/tomaka/android-rs-glue/pull/171 (see also
# https://github.com/tomaka/android-rs-glue/issues/204), we need to use
# an unpublished version.
cargo install --git https://github.com/staktrace/android-rs-glue --rev 6b2be25bd536a453e233cd7aea9d22974db63a49 --root wrench-deps/cargo-apk cargo-apk
tar caf wrench-deps.tar.bz2 wrench-deps
mkdir -p $UPLOAD_DIR