File tree 4 files changed +22
-4
lines changed 4 files changed +22
-4
lines changed Original file line number Diff line number Diff line change 16
16
strategy :
17
17
fail-fast : false
18
18
matrix :
19
- # See top README for MSRV policy
20
- rust_version : [1.68.0, stable]
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]
21
22
steps :
22
23
- uses : actions/checkout@v3
23
24
34
35
i686-linux-android
35
36
36
37
- name : Install cargo-ndk
37
- run : cargo 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"
38
42
39
43
- name : Setup Java
40
44
uses : actions/setup-java@v3
Original file line number Diff line number Diff line change @@ -9,7 +9,19 @@ repository = "https://github.com/rust-mobile/android-activity"
9
9
documentation = " https://docs.rs/android-activity"
10
10
description = " Glue for building Rust applications on Android with NativeActivity or GameActivity"
11
11
license = " MIT OR Apache-2.0"
12
- rust-version = " 1.68.0"
12
+
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
17
+ #
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"
13
25
14
26
[features ]
15
27
# Note: we don't enable any backend by default since features
Original file line number Diff line number Diff line change @@ -759,6 +759,7 @@ extern "Rust" {
759
759
// `app_main` function. This is run on a dedicated thread spawned
760
760
// by android_native_app_glue.
761
761
#[ no_mangle]
762
+ #[ allow( unused_unsafe) ] // Otherwise rust 1.64 moans about using unsafe{} in unsafe functions
762
763
pub unsafe extern "C" fn _rust_glue_entry ( native_app : * mut ffi:: android_app ) {
763
764
abort_on_panic ( || {
764
765
// Maybe make this stdout/stderr redirection an optional / opt-in feature?...
Original file line number Diff line number Diff line change @@ -828,6 +828,7 @@ unsafe extern "C" fn on_content_rect_changed(
828
828
829
829
/// This is the native entrypoint for our cdylib library that `ANativeActivity` will look for via `dlsym`
830
830
#[ no_mangle]
831
+ #[ allow( unused_unsafe) ] // Otherwise rust 1.64 moans about using unsafe{} in unsafe functions
831
832
extern "C" fn ANativeActivity_onCreate (
832
833
activity : * mut ndk_sys:: ANativeActivity ,
833
834
saved_state : * const libc:: c_void ,
You can’t perform that action at this time.
0 commit comments