forked from cross-rs/cross
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
to include alexcrichton/curl-rust#137 But only for the targets affected by cross-rs#4 closes cross-rs#4
- Loading branch information
Jorge Aparicio
committed
Dec 26, 2016
1 parent
d1bc4b6
commit 038ecf4
Showing
5 changed files
with
51 additions
and
15 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
set -ex | ||
|
||
main() { | ||
local dependencies=( | ||
ca-certificates | ||
curl | ||
) | ||
|
||
apt-get update | ||
|
||
apt-get install --no-install-recommends -y ${dependencies[@]} | ||
|
||
mkdir -p /overrides /.cargo | ||
echo "paths = [" > /.cargo/config | ||
|
||
local pkg= vers= | ||
while [ $# -gt 1 ]; do | ||
pkg=$1 | ||
vers=$2 | ||
shift 2 | ||
|
||
mkdir /overrides/$pkg | ||
curl -L https://japaric.github.io/cross/$pkg-v$vers.tar.gz | \ | ||
tar -C /overrides/$pkg -xz | ||
|
||
echo "\"/overrides/$pkg\"," >> /.cargo/config | ||
done | ||
|
||
echo "]" >> /.cargo/config | ||
|
||
apt-get purge --auto-remove -y ${dependencies[@]} | ||
|
||
rm $0 | ||
} | ||
|
||
main "${@}" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters