compiletest: add ignore-hurd support and annotate some tests
authorDebian Rust Maintainers <pkg-rust-maintainers@alioth-lists.debian.net>
Thu, 13 Jun 2024 09:16:39 +0000 (11:16 +0200)
committerFabian Grünbichler <debian@fabian.gruenbichler.email>
Fri, 26 Dec 2025 19:54:51 +0000 (20:54 +0100)
These tests hang or make the box OOM

Forwarded: no

Signed-off-by: Fabian Grünbichler <git@fabian.gruenbichler.email>
Gbp-Pq: Topic upstream
Gbp-Pq: Name u-hurd-tests.patch

src/tools/compiletest/src/directives/directive_names.rs
src/tools/compiletest/src/directives/tests.rs
tests/crashes/108499.rs
tests/run-make/long-linker-command-lines/foo.rs
tests/ui/associated-consts/issue-93775.rs
tests/ui/issues/issue-74564-if-expr-stack-overflow.rs
tests/ui/threads-sendsync/mpsc_stress.rs

index 0ef84fb45949319bee9d43d9f8a5c1f57d695482..4a8387403fd6de728828e6d113cfc4256f69f6d4 100644 (file)
@@ -69,6 +69,7 @@ pub(crate) const KNOWN_DIRECTIVE_NAMES: &[&str] = &[
     "ignore-gnu",
     "ignore-haiku",
     "ignore-horizon",
+    "ignore-hurd",
     "ignore-i686-pc-windows-gnu",
     "ignore-i686-pc-windows-msvc",
     "ignore-illumos",
index 33a02eb29fd537705aaf1d7716df07322c3b1362..54687d372777162b69dca91b22a3a083e77f6da1 100644 (file)
@@ -320,6 +320,7 @@ fn ignore_target() {
     assert!(check_ignore(&config, "//@ ignore-x86_64-unknown-linux-gnu"));
     assert!(check_ignore(&config, "//@ ignore-x86_64"));
     assert!(check_ignore(&config, "//@ ignore-linux"));
+    assert!(check_ignore(&config, "//@ ignore-hurd"));
     assert!(check_ignore(&config, "//@ ignore-unix"));
     assert!(check_ignore(&config, "//@ ignore-gnu"));
     assert!(check_ignore(&config, "//@ ignore-64bit"));
index 4a0638cd59ae4b94b0b17d99369d339a325245d3..658d63121eea30261cd7e10827c6932019f90c53 100644 (file)
@@ -1,4 +1,5 @@
 //@ known-bug: #108499
+//@ ignore-hurd
 
 // at lower recursion limits the recursion limit is reached before the bug happens
 #![recursion_limit = "2000"]
index 5b30c06fac9e023b6955ac9e1f50ce5d8864d7b7..9ef0d5add4630649d72b10c76c8c60dfc05c2437 100644 (file)
@@ -33,6 +33,13 @@ fn read_linker_args(path: &Path) -> String {
     }
 }
 
+#[cfg(target_os = "hurd")]
+// Debian: test causes build to fail on hurd
+fn main() {
+    return;
+}
+
+#[cfg(not(target_os = "hurd"))]
 fn main() {
     let ok = PathBuf::from("ok");
     if env::var("YOU_ARE_A_LINKER").is_ok() {
index a9b8d10a83fbf35b574490e516919d358dd1252a..ac41a6075be15bfb51f058703abe4d61c9b08ee8 100644 (file)
@@ -7,6 +7,7 @@
 //@ build-pass
 //@ revisions: current next
 //@ ignore-compare-mode-next-solver (explicit revisions)
+//@ ignore-hurd
 //@[next] compile-flags: -Znext-solver
 
 #![recursion_limit = "1001"]
index c0ffed27e6fb4687d6bd7b2e82f65f1ddc274ce3..1e97353af06285c98f83af34040e797bafb0776a 100644 (file)
@@ -1,5 +1,6 @@
 //@ build-pass
 // ignore-tidy-filelength
+//@ ignore-hurd
 #![crate_type = "rlib"]
 
 fn banana(v: &str) -> u32 {
index fe0b47f3a842e4b1b5da4f4445186320c5c8b67a..77ce6d5f0f1c31a9378a85232527fe8e7d3796d4 100644 (file)
@@ -1,6 +1,7 @@
 //@ run-pass
 //@ compile-flags:--test
 //@ needs-threads
+//@ ignore-hurd
 
 use std::sync::atomic::{AtomicUsize, Ordering};
 use std::sync::mpsc::{channel, RecvError, RecvTimeoutError, TryRecvError};