Skip to content

Commit

Permalink
Auto merge of #343 - sagudev:uwp-ci, r=jdm
Browse files Browse the repository at this point in the history
use dtolnay/rust-toolchain for UWP toolchain

optimizes Windows workflows and hopefully bypasses `rustup` problems from #342.
  • Loading branch information
bors-servo authored Feb 19, 2023
2 parents f84c114 + fbfca2f commit 1c2924a
Showing 1 changed file with 8 additions and 6 deletions.
14 changes: 8 additions & 6 deletions .github/workflows/rust.yml
Original file line number Diff line number Diff line change
Expand Up @@ -73,12 +73,17 @@ jobs:
.\install.ps1 -RunAsAdmin
scoop install [email protected] --global
echo "C:\ProgramData\scoop\shims;C:\Users\runneradmin\scoop\shims" | Out-File -FilePath $env:GITHUB_PATH -Encoding utf8 -Append
- uses: dtolnay/[email protected]
- uses: dtolnay/rust-toolchain@stable
if: (!contains(matrix.target, 'uwp'))
- uses: dtolnay/rust-toolchain@master
if: contains(matrix.target, 'uwp')
with:
toolchain: "nightly-2023-02-02"
components: rust-src
- name: Build uwp
if: contains(matrix.target, 'uwp')
shell: cmd
env:
TOOLCHAIN: nightly-2023-02-02
MOZTOOLS_PATH: 'C:\mozilla-build\msys\bin;C:\mozilla-build\bin'
AUTOCONF: "C:/mozilla-build/msys/local/bin/autoconf-2.13"
LINKER: "lld-link.exe"
Expand All @@ -88,11 +93,8 @@ jobs:
PYTHON3: "C:\\mozilla-build\\python3\\python3.exe"
LIBCLANG_PATH: "C:\\ProgramData\\scoop\\apps\\llvm\\current\\lib"
run: |
rustup install ${{ env.TOOLCHAIN }}
rustup default ${{ env.TOOLCHAIN }}
rustup component add rust-src --toolchain ${{ env.TOOLCHAIN }}-x86_64-pc-windows-msvc
rustc --version --verbose
cargo +${{ env.TOOLCHAIN }} build --verbose ${{ matrix.features }} -Z build-std=std,panic_abort --target ${{ matrix.target }}
cargo build --verbose ${{ matrix.features }} -Z build-std=std,panic_abort --target ${{ matrix.target }}
- name: Build Windows
if: contains(matrix.target, 'uwp') != true
shell: cmd
Expand Down

0 comments on commit 1c2924a

Please sign in to comment.