From ef93fbbc9d208d5dbf7658fe79d373931d0b2480 Mon Sep 17 00:00:00 2001 From: Vastargazing Date: Thu, 30 Apr 2026 10:24:54 +0300 Subject: [PATCH] tests/run-make/print-cfg: add Android target_env case Android targets must not inherit `target_env="gnu"` from the Linux GNU base. Cover this in the existing print-cfg run-make test so a future target-spec refactor cannot silently re-introduce it. --- tests/run-make/print-cfg/rmake.rs | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/tests/run-make/print-cfg/rmake.rs b/tests/run-make/print-cfg/rmake.rs index a5df237b7fddc..b516bb1508ec4 100644 --- a/tests/run-make/print-cfg/rmake.rs +++ b/tests/run-make/print-cfg/rmake.rs @@ -48,6 +48,12 @@ fn main() { includes: &["unix", "target_abi=\"eabihf\""], disallow: &["windows"], }); + // Regression test for #90834: Android must not have `target_env="gnu"`. + check(PrintCfg { + target: "i686-linux-android", + includes: &["unix", "target_os=\"android\""], + disallow: &["windows", "target_env=\"gnu\""], + }); } fn check(PrintCfg { target, includes, disallow }: PrintCfg) {