Skip to content

Commit 98e72b0

Browse files
committed
Remove some workarounds for older macOSes
1 parent cdf887c commit 98e72b0

File tree

1 file changed

+3
-21
lines changed

1 file changed

+3
-21
lines changed

libc-test/build.rs

+3-21
Original file line numberDiff line numberDiff line change
@@ -221,6 +221,7 @@ fn test_apple(target: &str) {
221221
"poll.h",
222222
"pthread.h",
223223
"pthread_spis.h",
224+
"pthread/introspection.h",
224225
"pwd.h",
225226
"regex.h",
226227
"resolv.h",
@@ -284,12 +285,8 @@ fn test_apple(target: &str) {
284285
}
285286
});
286287

287-
cfg.skip_type(move |ty| {
288-
match ty {
289-
// requires macOs 11.0 or higher
290-
"pthread_introspection_hook_t" => true,
291-
_ => false,
292-
}
288+
cfg.skip_type(move |ty| match ty {
289+
_ => false,
293290
});
294291

295292
cfg.skip_const(move |name| {
@@ -303,14 +300,6 @@ fn test_apple(target: &str) {
303300
"KERN_KDENABLE_BG_TRACE" | "KERN_KDDISABLE_BG_TRACE" => true,
304301
// FIXME: the value has been changed since Catalina (0xffff0000 -> 0x3fff0000).
305302
"SF_SETTABLE" => true,
306-
// FIXME: the values have been changed since Big Sur
307-
"HW_TARGET" | "HW_PRODUCT" | "HW_MAXID" => true,
308-
// these consts requires macOS 11.0 or higher
309-
"PTHREAD_INTROSPECTION_THREAD_CREATE"
310-
| "PTHREAD_INTROSPECTION_THREAD_DESTROY"
311-
| "PTHREAD_INTROSPECTION_THREAD_START"
312-
| "PTHREAD_INTROSPECTION_THREAD_TERMINATE"
313-
| "RTF_GLOBAL" => true,
314303
_ => false,
315304
}
316305
});
@@ -324,13 +313,6 @@ fn test_apple(target: &str) {
324313
// close calls the close_nocancel system call
325314
"close" => true,
326315

327-
// these calls require macOS 11.0 or higher
328-
"pthread_introspection_hook_install"
329-
| "pthread_introspection_getspecific_np"
330-
| "pthread_introspection_setspecific_np"
331-
| "preadv"
332-
| "pwritev" => true,
333-
334316
_ => false,
335317
}
336318
});

0 commit comments

Comments
 (0)