Skip to content

Commit 83cdb56

Browse files
authored
Merge pull request #123 from rust-mobile/rib/pr/msrv-1.68-v2
Bump MSRV to 1.68
2 parents 865cc6a + 942053d commit 83cdb56

File tree

4 files changed

+8
-20
lines changed

4 files changed

+8
-20
lines changed

.github/workflows/ci.yml

Lines changed: 3 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -16,9 +16,8 @@ jobs:
1616
strategy:
1717
fail-fast: false
1818
matrix:
19-
# XXX: We are currently constrained by Winit's MSRV policy + CI system
20-
# See Cargo.toml for details
21-
rust_version: [1.64.0, stable]
19+
# See top README for MSRV policy
20+
rust_version: [1.68.0, stable]
2221
steps:
2322
- uses: actions/checkout@v3
2423

@@ -35,10 +34,7 @@ jobs:
3534
i686-linux-android
3635
3736
- name: Install cargo-ndk
38-
# XXX: We have to use an old version of cargo-ndk that supports the
39-
# libgcc linker workaround for rust < 1.68 because Winit's CI system
40-
# currently requires this crate to be buildable with 1.64
41-
run: cargo install cargo-ndk --version "^2"
37+
run: cargo install cargo-ndk
4238

4339
- name: Build game-activity
4440
working-directory: android-activity

android-activity/Cargo.toml

Lines changed: 5 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -10,18 +10,12 @@ documentation = "https://docs.rs/android-activity"
1010
description = "Glue for building Rust applications on Android with NativeActivity or GameActivity"
1111
license = "MIT OR Apache-2.0"
1212

13-
# XXX: Even though we have our own MSRV policy that says we only promise to
14-
# support stable releases over the last three months we actually end up
15-
# constrained by the MSRV policy of Winit, which is currently based on
16-
# supporting Alacritty on Debian Sid, and requires a > 10 month old Rust version
13+
# 1.68 was when Rust last updated the Android NDK version used to build the
14+
# standard library which avoids needing the -lunwind workaround in build tools.
1715
#
18-
# This Winit policiy is unfortunately in conflict with what makes sense for
19-
# Android because versions below 1.68 for Android requires awkward toolchain
20-
# linker workarounds, and can't even be compiled with newer versions of
21-
# `cargo ndk` that removed these linker workarounds.
22-
#
23-
# TODO: Open a PR for Winit's CI to test Android builds using a newer toolchain.
24-
rust-version = "1.64"
16+
# We depend on cargo-ndk for building which has dropped support for the above
17+
# linker workaround.
18+
rust-version = "1.68.0"
2519

2620
[features]
2721
# Note: we don't enable any backend by default since features

android-activity/src/game_activity/mod.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -909,7 +909,6 @@ extern "Rust" {
909909
// `app_main` function. This is run on a dedicated thread spawned
910910
// by android_native_app_glue.
911911
#[no_mangle]
912-
#[allow(unused_unsafe)] // Otherwise rust 1.64 moans about using unsafe{} in unsafe functions
913912
pub unsafe extern "C" fn _rust_glue_entry(native_app: *mut ffi::android_app) {
914913
abort_on_panic(|| {
915914
// Maybe make this stdout/stderr redirection an optional / opt-in feature?...

android-activity/src/native_activity/glue.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -828,7 +828,6 @@ unsafe extern "C" fn on_content_rect_changed(
828828

829829
/// This is the native entrypoint for our cdylib library that `ANativeActivity` will look for via `dlsym`
830830
#[no_mangle]
831-
#[allow(unused_unsafe)] // Otherwise rust 1.64 moans about using unsafe{} in unsafe functions
832831
extern "C" fn ANativeActivity_onCreate(
833832
activity: *mut ndk_sys::ANativeActivity,
834833
saved_state: *const libc::c_void,

0 commit comments

Comments
 (0)