Skip to content

Commit

Permalink
Disable cross on x86_64 targets
Browse files Browse the repository at this point in the history
  • Loading branch information
Amanieu committed Mar 7, 2024
1 parent 56f6c0b commit 309c473
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 2 deletions.
2 changes: 0 additions & 2 deletions .github/workflows/rust.yml
Original file line number Diff line number Diff line change
Expand Up @@ -43,8 +43,6 @@ jobs:
- env:
TARGET: ${{ matrix.target }}
CHANNEL: ${{ matrix.channel }}
CROSS: ${{ matrix.target != 'x86_64-unknown-linux-gnu' && '1' || '0' }}
NO_STD: ${{ matrix.target == 'thumbv6m-none-eabi' && '1' || '0' }}
run: sh ci/run.sh
strategy:
matrix:
Expand Down
15 changes: 15 additions & 0 deletions ci/run.sh
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,21 @@ set -ex

: "${TARGET?The TARGET environment variable must be set.}"

case "${TARGET}" in
x86_64-unknown-linux-gnu|x86_64-apple-darwin|x86_64-pc-windows-msvc)
CROSS=0
NO_STD=0
;;
thumbv6m-none-eabi)
CROSS=1
NO_STD=1
;;
*)
CROSS=1
NO_STD=0
;;
esac

CARGO=cargo
if [ "${CROSS}" = "1" ]; then
export CARGO_NET_RETRY=5
Expand Down

0 comments on commit 309c473

Please sign in to comment.