File: relax-linux-raw-sys.patch

package info (click to toggle)
rust-rustix 1.0.8-2
  • links: PTS, VCS
  • area: main
  • in suites: experimental
  • size: 3,332 kB
  • sloc: makefile: 2
file content (56 lines) | stat: -rw-r--r-- 3,490 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
Description: Bump linux-raw-sys to v0.10
 linux-raw-sys 0.10 updated its API to linux 6.14. Starting from linux 6.11,
 `statx`'s `__spare1` field got renamed to `stx_dio_read_offset_align` and
 became a non-dummy field. The change does not break the ABI, but rustix's
 `fs` feature tests expect it to exist with the old name, which it does not.
 For consistency with linux-raw-sys 0.10, we rename the field and change its
 type (in a way that does not break the ABI), but we still keep it pub(crate)
 like the old field to also avoid changing the API.
 See also https://github.com/bytecodealliance/rustix/pull/1467.
Author: NoisyCoil <noisycoil@tutanota.com>
Forwarded: not-needed
Last-Update: 2025-08-02
---
This patch header follows DEP-3: http://dep.debian.net/deps/dep3/
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -192,7 +192,7 @@
 version = "3.5.0"
 
 [target.'cfg(all(any(target_os = "android", target_os = "linux"), any(rustix_use_libc, miri, not(all(target_os = "linux", any(target_endian = "little", any(target_arch = "s390x", target_arch = "powerpc")), any(target_arch = "arm", all(target_arch = "aarch64", target_pointer_width = "64"), target_arch = "riscv64", all(rustix_use_experimental_asm, target_arch = "powerpc"), all(rustix_use_experimental_asm, target_arch = "powerpc64"), all(rustix_use_experimental_asm, target_arch = "s390x"), all(rustix_use_experimental_asm, target_arch = "mips"), all(rustix_use_experimental_asm, target_arch = "mips32r6"), all(rustix_use_experimental_asm, target_arch = "mips64"), all(rustix_use_experimental_asm, target_arch = "mips64r6"), target_arch = "x86", all(target_arch = "x86_64", target_pointer_width = "64")))))))'.dependencies.linux-raw-sys]
-version = "0.9.2"
+version = "0.10"
 features = [
     "general",
     "ioctl",
@@ -215,7 +215,7 @@
 package = "errno"
 
 [target.'cfg(all(not(rustix_use_libc), not(miri), target_os = "linux", any(target_endian = "little", any(target_arch = "s390x", target_arch = "powerpc")), any(target_arch = "arm", all(target_arch = "aarch64", target_pointer_width = "64"), target_arch = "riscv64", all(rustix_use_experimental_asm, target_arch = "powerpc"), all(rustix_use_experimental_asm, target_arch = "powerpc64"), all(rustix_use_experimental_asm, target_arch = "s390x"), all(rustix_use_experimental_asm, target_arch = "mips"), all(rustix_use_experimental_asm, target_arch = "mips32r6"), all(rustix_use_experimental_asm, target_arch = "mips64"), all(rustix_use_experimental_asm, target_arch = "mips64r6"), target_arch = "x86", all(target_arch = "x86_64", target_pointer_width = "64"))))'.dependencies.linux-raw-sys]
-version = "0.9.2"
+version = "0.10"
 features = [
     "general",
     "errno",
--- a/src/fs/constants.rs
+++ b/src/fs/constants.rs
@@ -347,7 +347,7 @@
             #[cfg(not(libc))] // not in libc yet
             check_renamed_struct_field!(Statx, statx, stx_atomic_write_segments_max);
             #[cfg(linux_raw)]
-            check_renamed_struct_field!(Statx, statx, __spare1);
+            check_renamed_struct_field!(Statx, statx, stx_dio_read_offset_align);
             #[cfg(linux_raw)]
             check_renamed_struct_field!(Statx, statx, __spare3);
         }
--- a/src/fs/statx.rs
+++ b/src/fs/statx.rs
@@ -44,7 +44,7 @@
     pub stx_atomic_write_unit_min: u32,
     pub stx_atomic_write_unit_max: u32,
     pub stx_atomic_write_segments_max: u32,
-    pub(crate) __spare1: [u32; 1],
+    pub(crate) stx_dio_read_offset_align: u32,
     pub(crate) __spare3: [u64; 9],
 }