Skip to content

Commit a6294e1

Browse files
authored
Update spirv-tools (#351)
* Split android into separate job * Bump spirv-tools to 0.3.1
1 parent 51038a6 commit a6294e1

File tree

3 files changed

+19
-25
lines changed

3 files changed

+19
-25
lines changed

.github/workflows/ci.yaml

Lines changed: 14 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,8 @@ jobs:
1818
target: x86_64-pc-windows-msvc
1919
- os: macOS-latest
2020
target: x86_64-apple-darwin
21+
- os: ubuntu-latest
22+
target: aarch64-linux-android
2123
runs-on: ${{ matrix.os }}
2224
env:
2325
spirv_tools_version: "20200928"
@@ -53,33 +55,25 @@ jobs:
5355
- name: cargo fetch --locked
5456
run: cargo fetch --locked --target ${{ matrix.target }}
5557
- name: Run tests
58+
if: ${{ matrix.target != 'aarch64-linux-android' }}
5659
shell: bash
5760
run: .github/workflows/test.sh ${{ runner.os }}
5861

59-
- name: Install cargo-apk
60-
run: cargo install cargo-apk
61-
62-
- if: runner.os == 'Windows'
63-
name: Create symlink to Android SDK/NDK without spaces
62+
- name: Build WGPU Example for Android
63+
if: ${{ matrix.target == 'aarch64-linux-android' }}
64+
shell: bash
6465
run: |
65-
$oldAndroidPath = $env:ANDROID_HOME
66-
$sdk_root = "C:\Android"
67-
New-Item -Path $sdk_root -ItemType SymbolicLink -Value $oldAndroidPath
68-
69-
echo "ANDROID_SDK_ROOT=$sdk_root" >> $env:GITHUB_ENV
70-
echo "ANDROID_NDK_ROOT=$sdk_root\ndk-bundle" >> $env:GITHUB_ENV
66+
echo "::group::Install cargo-apk"
67+
cargo install cargo-apk
68+
echo "::endgroup::"
7169
72-
# Update legacy path for ndk-build:
73-
echo "ANDROID_HOME=$sdk_root" >> $env:GITHUB_ENV
74-
75-
# Unset legacy paths:
76-
echo "ANDROID_NDK_HOME=" >> $env:GITHUB_ENV
77-
echo "ANDROID_NDK_PATH=" >> $env:GITHUB_ENV
78-
79-
- name: Compile WGPU example for Android
80-
run: |
70+
echo "::group::Add aarch64-linux-android target"
8171
rustup target add aarch64-linux-android
72+
echo "::endgroup::"
73+
74+
echo "::group::Build WGPU example for Android"
8275
cargo apk build --manifest-path examples/runners/wgpu/Cargo.toml --features use-installed-tools --no-default-features
76+
echo "::endgroup::"
8377
8478
lint:
8579
name: Lint

Cargo.lock

Lines changed: 4 additions & 4 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

crates/rustc_codegen_spirv/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ rspirv = { git = "https://github.com/gfx-rs/rspirv.git", rev = "01ca0d2e5b667a0e
3333
rustc-demangle = "0.1.18"
3434
serde = { version = "1.0", features = ["derive"] }
3535
serde_json = "1.0"
36-
spirv-tools = { version = "0.2.0", default-features = false }
36+
spirv-tools = { version = "0.3.0", default-features = false }
3737
tar = "0.4.30"
3838
topological-sort = "0.1"
3939

0 commit comments

Comments
 (0)