summaryrefslogtreecommitdiffstats
path: root/debian/patches/u-fix-rustix-for-sparc64.patch
blob: 88995cd5b543e6118f43a3ee19b1f1610279ebb3 (plain)
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
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
--- rustc-1.64.0+dfsg1.orig/vendor/rustix/src/imp/libc/process/types.rs
+++ rustc-1.64.0+dfsg1/vendor/rustix/src/imp/libc/process/types.rs
@@ -199,7 +199,12 @@ pub enum Signal {
         target_os = "openbsd",
         all(
             any(target_os = "android", target_os = "linux"),
-            any(target_arch = "mips", target_arch = "mips64"),
+            any(
+                target_arch = "mips",
+                target_arch = "mips64",
+                target_arch = "sparc",
+                target_arch = "sparc64"
+            ),
         )
     )))]
     Stkflt = c::SIGSTKFLT,
@@ -276,7 +281,12 @@ impl Signal {
                 target_os = "openbsd",
                 all(
                     any(target_os = "android", target_os = "linux"),
-                    any(target_arch = "mips", target_arch = "mips64"),
+                    any(
+                        target_arch = "mips",
+                        target_arch = "mips64",
+                        target_arch = "sparc",
+                        target_arch = "sparc64"
+                    ),
                 )
             )))]
             c::SIGSTKFLT => Some(Self::Stkflt),
--- rustc-1.64.0+dfsg1.orig/vendor/rustix/src/imp/libc/termios/types.rs
+++ rustc-1.64.0+dfsg1/vendor/rustix/src/imp/libc/termios/types.rs
@@ -704,6 +704,8 @@ pub const B2000000: Speed = c::B2000000;
 
 /// `B2500000`
 #[cfg(not(any(
+    target_arch = "sparc",
+    target_arch = "sparc64",
     target_os = "dragonfly",
     target_os = "freebsd",
     target_os = "ios",
@@ -715,6 +717,8 @@ pub const B2500000: Speed = c::B2500000;
 
 /// `B3000000`
 #[cfg(not(any(
+    target_arch = "sparc",
+    target_arch = "sparc64",
     target_os = "dragonfly",
     target_os = "freebsd",
     target_os = "ios",
@@ -726,6 +730,8 @@ pub const B3000000: Speed = c::B3000000;
 
 /// `B3500000`
 #[cfg(not(any(
+    target_arch = "sparc",
+    target_arch = "sparc64",
     target_os = "dragonfly",
     target_os = "freebsd",
     target_os = "ios",
@@ -737,6 +743,8 @@ pub const B3500000: Speed = c::B3500000;
 
 /// `B4000000`
 #[cfg(not(any(
+    target_arch = "sparc",
+    target_arch = "sparc64",
     target_os = "dragonfly",
     target_os = "freebsd",
     target_os = "ios",
--- rustc-1.64.0+dfsg1.orig/vendor/rustix/src/imp/linux_raw/termios/types.rs
+++ rustc-1.64.0+dfsg1/vendor/rustix/src/imp/linux_raw/termios/types.rs
@@ -338,15 +338,19 @@ pub const B1500000: Speed = linux_raw_sy
 pub const B2000000: Speed = linux_raw_sys::general::B2000000;
 
 /// `B2500000`
+#[cfg(not(any(target_arch = "sparc", target_arch = "sparc64",)))]
 pub const B2500000: Speed = linux_raw_sys::general::B2500000;
 
 /// `B3000000`
+#[cfg(not(any(target_arch = "sparc", target_arch = "sparc64",)))]
 pub const B3000000: Speed = linux_raw_sys::general::B3000000;
 
 /// `B3500000`
+#[cfg(not(any(target_arch = "sparc", target_arch = "sparc64",)))]
 pub const B3500000: Speed = linux_raw_sys::general::B3500000;
 
 /// `B4000000`
+#[cfg(not(any(target_arch = "sparc", target_arch = "sparc64",)))]
 pub const B4000000: Speed = linux_raw_sys::general::B4000000;
 
 /// `CSIZE`
--- rustc-1.64.0+dfsg1.orig/vendor/rustix/src/termios/constants.rs
+++ rustc-1.64.0+dfsg1/vendor/rustix/src/termios/constants.rs
@@ -45,6 +45,8 @@ pub use imp::termios::types::B2000000;
 )))]
 pub use imp::termios::types::B2500000;
 #[cfg(not(any(
+    target_arch = "sparc",
+    target_arch = "sparc64",
     target_os = "dragonfly",
     target_os = "freebsd",
     target_os = "ios",
@@ -54,6 +56,8 @@ pub use imp::termios::types::B2500000;
 )))]
 pub use imp::termios::types::B3000000;
 #[cfg(not(any(
+    target_arch = "sparc",
+    target_arch = "sparc64",
     target_os = "dragonfly",
     target_os = "freebsd",
     target_os = "ios",
@@ -63,6 +67,8 @@ pub use imp::termios::types::B3000000;
 )))]
 pub use imp::termios::types::B3500000;
 #[cfg(not(any(
+    target_arch = "sparc",
+    target_arch = "sparc64",
     target_os = "dragonfly",
     target_os = "freebsd",
     target_os = "ios",
@@ -74,6 +80,8 @@ pub use imp::termios::types::B4000000;
 #[cfg(not(any(target_os = "ios", target_os = "macos", target_os = "openbsd")))]
 pub use imp::termios::types::B460800;
 #[cfg(not(any(
+    target_arch = "sparc",
+    target_arch = "sparc64",
     target_os = "dragonfly",
     target_os = "freebsd",
     target_os = "illumos",
@@ -688,6 +696,8 @@ pub fn speed_value(speed: imp::termios::
         )))]
         imp::termios::types::B2500000 => Some(2_500_000),
         #[cfg(not(any(
+            target_arch = "sparc",
+            target_arch = "sparc64",
             target_os = "dragonfly",
             target_os = "freebsd",
             target_os = "ios",
@@ -697,6 +707,8 @@ pub fn speed_value(speed: imp::termios::
         )))]
         imp::termios::types::B3000000 => Some(3_000_000),
         #[cfg(not(any(
+            target_arch = "sparc",
+            target_arch = "sparc64",
             target_os = "dragonfly",
             target_os = "freebsd",
             target_os = "ios",
@@ -706,6 +718,8 @@ pub fn speed_value(speed: imp::termios::
         )))]
         imp::termios::types::B3500000 => Some(3_500_000),
         #[cfg(not(any(
+            target_arch = "sparc",
+            target_arch = "sparc64",
             target_os = "dragonfly",
             target_os = "freebsd",
             target_os = "ios",
--- rustc-1.64.0+dfsg1.orig/vendor/rustix/src/termios/mod.rs
+++ rustc-1.64.0+dfsg1/vendor/rustix/src/termios/mod.rs
@@ -44,6 +44,8 @@ pub use constants::B1500000;
 )))]
 pub use constants::B2000000;
 #[cfg(not(any(
+    target_arch = "sparc",
+    target_arch = "sparc64",
     target_os = "dragonfly",
     target_os = "freebsd",
     target_os = "ios",
@@ -53,6 +55,8 @@ pub use constants::B2000000;
 )))]
 pub use constants::B2500000;
 #[cfg(not(any(
+    target_arch = "sparc",
+    target_arch = "sparc64",
     target_os = "dragonfly",
     target_os = "freebsd",
     target_os = "ios",
@@ -62,6 +66,8 @@ pub use constants::B2500000;
 )))]
 pub use constants::B3000000;
 #[cfg(not(any(
+    target_arch = "sparc",
+    target_arch = "sparc64",
     target_os = "dragonfly",
     target_os = "freebsd",
     target_os = "ios",
@@ -71,6 +77,8 @@ pub use constants::B3000000;
 )))]
 pub use constants::B3500000;
 #[cfg(not(any(
+    target_arch = "sparc",
+    target_arch = "sparc64",
     target_os = "dragonfly",
     target_os = "freebsd",
     target_os = "ios",
--- rustc-1.64.0+dfsg1.orig/vendor/rustix/tests/time/y2038.rs
+++ rustc-1.64.0+dfsg1/vendor/rustix/tests/time/y2038.rs
@@ -14,6 +14,7 @@
 #[cfg(not(all(target_env = "musl", target_pointer_width = "32")))]
 #[cfg(not(all(target_os = "android", target_pointer_width = "32")))]
 #[cfg(not(all(target_os = "emscripten", target_pointer_width = "32")))]
+#[cfg(not(all(target_os = "linux", target_arch = "sparc")))]
 #[test]
 fn test_y2038() {
     use rustix::time::{Secs, Timespec};