Skip to content

Commit

Permalink
Build linux release using musl
Browse files Browse the repository at this point in the history
  • Loading branch information
Luni-4 committed Jan 14, 2021
1 parent adf3cbc commit 79d6b86
Showing 1 changed file with 9 additions and 6 deletions.
15 changes: 9 additions & 6 deletions .taskcluster.yml
Original file line number Diff line number Diff line change
Expand Up @@ -233,14 +233,17 @@ tasks:
command:
- "/bin/bash"
- "-cx"
- "git clone --recursive --quiet ${repository} &&
- "apt-get update &&
apt-get install -y musl &&
rustup target add x86_64-unknown-linux-musl &&
git clone --recursive --quiet ${repository} &&
cd rust-code-analysis &&
git -c advice.detachedHead=false checkout --recurse-submodules ${head_rev} &&
cargo build --workspace --release &&
cargo package --all-features &&
pushd rust-code-analysis-cli && cargo package --all-features && popd &&
pushd rust-code-analysis-web && cargo package --all-features && popd &&
cd target/release &&
env CC=\"gcc\" CXX=\"g++\" cargo build --workspace --release --target x86_64-unknown-linux-musl &&
env CC=\"gcc\" CXX=\"g++\" cargo package --all-features --target x86_64-unknown-linux-musl &&
pushd rust-code-analysis-cli && env CC=\"gcc\" CXX=\"g++\" cargo package --all-features --target x86_64-unknown-linux-musl && popd &&
pushd rust-code-analysis-web && env CC=\"gcc\" CXX=\"g++\" cargo package --all-features --target x86_64-unknown-linux-musl && popd &&
cd target/x86_64-unknown-linux-musl/release &&
strip rust-code-analysis-cli rust-code-analysis-web &&
tar -zvcf /rust-code-analysis-linux-cli-x86_64.tar.gz rust-code-analysis-cli &&
tar -zvcf /rust-code-analysis-linux-web-x86_64.tar.gz rust-code-analysis-web"
Expand Down

0 comments on commit 79d6b86

Please sign in to comment.