Bug 1582195 - Provide a job to build lucetc r=froydnj

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

--HG--
extra : moz-landing-system : lando
This commit is contained in:
Ricky Stewart 2019-11-05 16:30:24 +00:00
Родитель 43cc243866
Коммит 0bc04914ab
3 изменённых файлов: 39 добавлений и 0 удалений

Просмотреть файл

@ -435,3 +435,10 @@ cmake:
artifact-name: cmake.tar.zst artifact-name: cmake.tar.zst
strip-components: 1 strip-components: 1
add-prefix: cmake/ add-prefix: cmake/
lucetc-source:
description: lucetc source code
fetch:
type: git
repo: https://github.com/PLSysSec/lucet_sandbox_compiler/
revision: 5c22392b5b1aaa60e915c75e92b57391e1e61e6d

Просмотреть файл

@ -175,3 +175,19 @@ wrench-deps:
- android-rs-glue - android-rs-glue
toolchain: toolchain:
- linux64-rust-1.37 # whatever m-c is built with - linux64-rust-1.37 # whatever m-c is built with
lucetc:
description: "lucetc build process"
treeherder:
symbol: TL(lucetc)
run:
script: build-lucetc.sh
toolchain-artifact: public/build/lucetc.tar.xz
fetches:
fetch:
- cmake
- lucetc-source
toolchain:
- linux64-binutils
- linux64-clang
- linux64-rust

Просмотреть файл

@ -0,0 +1,16 @@
#!/bin/bash
set -x -e -v
cd $MOZ_FETCHES_DIR/lucet_sandbox_compiler
export PATH=$MOZ_FETCHES_DIR/binutils/bin:$MOZ_FETCHES_DIR/clang/bin:$PATH:$MOZ_FETCHES_DIR/rustc/bin:$MOZ_FETCHES_DIR/cmake/bin
export CC=$MOZ_FETCHES_DIR/clang/bin/clang
export CFLAGS="-L$MOZ_FETCHES_DIR/clang/lib"
export CXXFLAGS=$CFLAGS
export CXX=$MOZ_FETCHES_DIR/clang/bin/clang++
export AR=$MOZ_FETCHES_DIR/clang/bin/llvm-ar
export RUSTFLAGS="-C linker=$CXX -C link-arg=$CXXFLAGS"
make build
mkdir -p $UPLOAD_DIR
tar --xz -cf $UPLOAD_DIR/lucetc.tar.xz target/release/lucetc