summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPiotr Kubaj <pkubaj@FreeBSD.org>2025-09-17 13:51:50 +0200
committerPiotr Kubaj <pkubaj@FreeBSD.org>2025-09-18 06:13:21 +0200
commit48633f8f820d201253e15d76563981c88a32d2a6 (patch)
tree23b84d0a2fd69e2da1ecdfc5576aa6f1c3c52476
parentmath/R-cran-survey: Update to 4.4.8 (diff)
sysutils/bottom: fix build on ARM / POWER
error[E0308]: mismatched types --> src/collection/processes/unix/process_ext.rs:186:40 | 186 | const SIDL: u8 = assert_u8(libc::SIDL); | --------- ^^^^^^^^^^ expected `i8`, found `u8` | | | arguments to this function are incorrect | note: function defined here --> src/collection/processes/unix/process_ext.rs:182:22 | 182 | const fn assert_u8(val: i8) -> u8 { | ^^^^^^^^^ ------- error[E0308]: mismatched types --> src/collection/processes/unix/process_ext.rs:187:40 | 187 | const SRUN: u8 = assert_u8(libc::SRUN); | --------- ^^^^^^^^^^ expected `i8`, found `u8` | | | arguments to this function are incorrect | note: function defined here --> src/collection/processes/unix/process_ext.rs:182:22 | 182 | const fn assert_u8(val: i8) -> u8 { | ^^^^^^^^^ ------- error[E0308]: mismatched types --> src/collection/processes/unix/process_ext.rs:188:42 | 188 | const SSLEEP: u8 = assert_u8(libc::SSLEEP); | --------- ^^^^^^^^^^^^ expected `i8`, found `u8` | | | arguments to this function are incorrect | note: function defined here --> src/collection/processes/unix/process_ext.rs:182:22 | 182 | const fn assert_u8(val: i8) -> u8 { | ^^^^^^^^^ ------- error[E0308]: mismatched types --> src/collection/processes/unix/process_ext.rs:189:41 | 189 | const SSTOP: u8 = assert_u8(libc::SSTOP); | --------- ^^^^^^^^^^^ expected `i8`, found `u8` | | | arguments to this function are incorrect | note: function defined here --> src/collection/processes/unix/process_ext.rs:182:22 | 182 | const fn assert_u8(val: i8) -> u8 { | ^^^^^^^^^ ------- error[E0308]: mismatched types --> src/collection/processes/unix/process_ext.rs:190:41 | 190 | const SZOMB: u8 = assert_u8(libc::SZOMB); | --------- ^^^^^^^^^^^ expected `i8`, found `u8` | | | arguments to this function are incorrect | note: function defined here --> src/collection/processes/unix/process_ext.rs:182:22 | 182 | const fn assert_u8(val: i8) -> u8 { | ^^^^^^^^^ ------- error[E0308]: mismatched types --> src/collection/processes/unix/process_ext.rs:191:41 | 191 | const SWAIT: u8 = assert_u8(libc::SWAIT); | --------- ^^^^^^^^^^^ expected `i8`, found `u8` | | | arguments to this function are incorrect | note: function defined here --> src/collection/processes/unix/process_ext.rs:182:22 | 182 | const fn assert_u8(val: i8) -> u8 { | ^^^^^^^^^ ------- error[E0308]: mismatched types --> src/collection/processes/unix/process_ext.rs:192:41 | 192 | const SLOCK: u8 = assert_u8(libc::SLOCK); | --------- ^^^^^^^^^^^ expected `i8`, found `u8` | | | arguments to this function are incorrect | note: function defined here --> src/collection/processes/unix/process_ext.rs:182:22 | 182 | const fn assert_u8(val: i8) -> u8 { | ^^^^^^^^^ -------
-rw-r--r--sysutils/bottom/files/patch-src_collection_processes_unix_process__ext.rs11
1 files changed, 11 insertions, 0 deletions
diff --git a/sysutils/bottom/files/patch-src_collection_processes_unix_process__ext.rs b/sysutils/bottom/files/patch-src_collection_processes_unix_process__ext.rs
new file mode 100644
index 000000000000..ab1b26f46c4a
--- /dev/null
+++ b/sysutils/bottom/files/patch-src_collection_processes_unix_process__ext.rs
@@ -0,0 +1,11 @@
+--- src/collection/processes/unix/process_ext.rs.orig 2025-09-17 11:38:11 UTC
++++ src/collection/processes/unix/process_ext.rs
+@@ -179,7 +179,7 @@ fn convert_process_status_to_char(status: ProcessStatu
+ _ => '?'
+ }
+ } else if #[cfg(target_os = "freebsd")] {
+- const fn assert_u8(val: i8) -> u8 {
++ const fn assert_u8(val: libc::c_char) -> u8 {
+ if val < 0 { panic!("there was an invalid i8 constant that is supposed to be a char") } else { val as u8 }
+ }
+