
* add appveyor, travis, remove libsnark as default, add push to gh * fix appveyor * change appveyor to nightly * use cargo for build job * change to build everywhere * update token, reduce targets * add more targets * add on liner script * remove rustc dep * add need_cmd * add check cmd * simple brackets * use check_cmd for curl * copy stdlib to OUT_DIR * ship stdlib in archive * install stdlib, give PATH hints after build script * clean * comment * scripts: ensure one-liner install script works with FreeBSD * remove appveyor for now * clean, remove windows, remove appveyor, remove travis test * put back cross install * fix stdlib test generation * disable tests in travis * restore test script to prevent tests to run.. * change scripts to keep same behaviour now that libsnark is disabled by default * update docs with installer * change docker to dockerhub * change repo
47 lines
1.3 KiB
Bash
Executable file
47 lines
1.3 KiB
Bash
Executable file
set -ex
|
|
|
|
main() {
|
|
local target=
|
|
if [ $TRAVIS_OS_NAME = linux ]; then
|
|
target=x86_64-unknown-linux-musl
|
|
sort=sort
|
|
else
|
|
target=x86_64-apple-darwin
|
|
sort=gsort # for `sort --sort-version`, from brew's coreutils.
|
|
fi
|
|
|
|
# Builds for iOS are done on OSX, but require the specific target to be
|
|
# installed.
|
|
case $TARGET in
|
|
aarch64-apple-ios)
|
|
rustup target install aarch64-apple-ios
|
|
;;
|
|
armv7-apple-ios)
|
|
rustup target install armv7-apple-ios
|
|
;;
|
|
armv7s-apple-ios)
|
|
rustup target install armv7s-apple-ios
|
|
;;
|
|
i386-apple-ios)
|
|
rustup target install i386-apple-ios
|
|
;;
|
|
x86_64-apple-ios)
|
|
rustup target install x86_64-apple-ios
|
|
;;
|
|
esac
|
|
|
|
# This fetches latest stable release
|
|
local tag=$(git ls-remote --tags --refs --exit-code https://github.com/japaric/cross \
|
|
| cut -d/ -f3 \
|
|
| grep -E '^v[0.1.0-9.]+$' \
|
|
| $sort --version-sort \
|
|
| tail -n1)
|
|
curl -LSfs https://japaric.github.io/trust/install.sh | \
|
|
sh -s -- \
|
|
--force \
|
|
--git japaric/cross \
|
|
--tag $tag \
|
|
--target $target
|
|
}
|
|
|
|
main
|