File tree 2 files changed +10
-0
lines changed
2 files changed +10
-0
lines changed Original file line number Diff line number Diff line change @@ -41,6 +41,7 @@ fn main() {
41
41
let rustc_dep_of_std = env:: var ( "CARGO_FEATURE_RUSTC_DEP_OF_STD" ) . is_ok ( ) ;
42
42
let libc_ci = env:: var ( "LIBC_CI" ) . is_ok ( ) ;
43
43
let libc_check_cfg = env:: var ( "LIBC_CHECK_CFG" ) . is_ok ( ) || rustc_minor_ver >= 80 ;
44
+ let linux_time_bits64 = env:: var ( "RUST_LIBC_UNSTABLE_LINUX_TIME_BITS64" ) . is_ok ( ) ;
44
45
45
46
// The ABI of libc used by std is backward compatible with FreeBSD 12.
46
47
// The ABI of libc from crates.io is backward compatible with FreeBSD 12.
@@ -70,6 +71,10 @@ fn main() {
70
71
Some ( _) | None => ( ) ,
71
72
}
72
73
74
+ if linux_time_bits64 {
75
+ set_cfg ( "linux_time_bits64" ) ;
76
+ }
77
+
73
78
// On CI: deny all warnings
74
79
if libc_ci {
75
80
set_cfg ( "libc_deny_warnings" ) ;
Original file line number Diff line number Diff line change @@ -65,6 +65,11 @@ test_target() {
65
65
$cmd --features const-extern-fn
66
66
$cmd --features extra_traits
67
67
68
+ if [ " $os " = " linux" ]; then
69
+ # Test with the equivalent of __USE_TIME_BITS64
70
+ RUST_LIBC_UNSTABLE_LINUX_TIME_BITS64=1 $cmd
71
+ fi
72
+
68
73
# Test again without default features, i.e. without "std"
69
74
$cmd --no-default-features
70
75
$cmd --no-default-features --features extra_traits
You can’t perform that action at this time.
0 commit comments