Skip to content

Commit

Permalink
Added Cache, improved LLVM install
Browse files Browse the repository at this point in the history
  • Loading branch information
syrusakbary committed Aug 10, 2019
1 parent a82907e commit 59a7f21
Show file tree
Hide file tree
Showing 2 changed files with 22 additions and 8 deletions.
17 changes: 10 additions & 7 deletions .azure/install-llvm.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,9 @@ steps:
else
curl -O https://releases.llvm.org/8.0.0/clang+llvm-8.0.0-x86_64-apple-darwin.tar.xz
tar xf clang+llvm-8.0.0-x86_64-apple-darwin.tar.xz
export LLVM_SYS_80_PREFIX="`pwd`/clang+llvm-8.0.0-x86_64-apple-darwin/"
echo "##vso[task.prependpath]$LLVM_SYS_80_PREFIX/bin"
export LLVM_PATH="`pwd`/clang+llvm-8.0.0-x86_64-apple-darwin/"
echo "##vso[task.prependpath]$LLVM_PATH/bin"
echo "##vso[task.setvariable variable=LLVM_SYS_80_PREFIX]$LLVM_PATH"
fi
displayName: "Install LLVM (macOS)"
condition: eq(variables['Agent.OS'], 'Darwin')
Expand All @@ -21,8 +22,9 @@ steps:
else
curl -O https://releases.llvm.org/8.0.0/clang+llvm-8.0.0-x86_64-linux-gnu-ubuntu-16.04.tar.xz
tar xf clang+llvm-8.0.0-x86_64-linux-gnu-ubuntu-16.04.tar.xz
export LLVM_SYS_80_PREFIX="`pwd`/clang+llvm-8.0.0-x86_64-linux-gnu-ubuntu-16.04/"
echo "##vso[task.prependpath]$LLVM_SYS_80_PREFIX/bin"
export LLVM_PATH="`pwd`/clang+llvm-8.0.0-x86_64-linux-gnu-ubuntu-16.04/"
echo "##vso[task.prependpath]$LLVM_PATH/bin"
echo "##vso[task.setvariable variable=LLVM_SYS_80_PREFIX]$LLVM_PATH"
fi
displayName: "Install LLVM (Linux)"
condition: eq(variables['Agent.OS'], 'Linux')
Expand All @@ -33,9 +35,10 @@ steps:
echo `command -v cmake` `llvm-config --version` installed
else
curl -O https://github.com/wasmerio/windows-llvm-build/releases/download/v8.0.0/llvm-8.0.0-install.zip
unzip llvm-8.0.0-install.zip
export LLVM_SYS_80_PREFIX="`pwd`/llvm-8.0.0-install/"
echo "##vso[task.prependpath]$LLVM_SYS_80_PREFIX/bin"
7z x llvm-8.0.0-install.zip
export LLVM_PATH="`pwd`/llvm-8.0.0-install/"
echo "##vso[task.prependpath]$LLVM_PATH/bin"
echo "##vso[task.setvariable variable=LLVM_SYS_80_PREFIX]$LLVM_PATH"
# chocolatey install cmake --installargs 'ADD_CMAKE_TO_PATH=System'
fi
displayName: "Install LLVM (Windows)"
Expand Down
13 changes: 12 additions & 1 deletion azure-pipelines.yml
Original file line number Diff line number Diff line change
Expand Up @@ -35,12 +35,23 @@ jobs:
pool:
vmImage: $(imageName)

steps:
variables:
CARGO_TARGET_FOLDER: $(Pipeline.Workspace)/target

steps:
- checkout: self
submodules: true
- template: .azure/install-rust.yml
- template: .azure/install-cmake.yml
- template: .azure/install-llvm.yml
- task: CacheBeta@0
inputs:
key: |
cargo
$(Agent.OS)
$(Build.SourcesDirectory)/Cargo.lock
path: $(CARGO_TARGET_FOLDER)
displayName: Cache Cargo Target
- bash: make check
displayName: Check with Flags
- bash: make test
Expand Down

0 comments on commit 59a7f21

Please sign in to comment.