@@ -2819,7 +2819,7 @@ fn test_emscripten(target: &str) {
2819
2819
// Just pass all these through, no need for a "struct" prefix
2820
2820
"FILE" | "fd_set" | "Dl_info" | "DIR" => ty. to_string ( ) ,
2821
2821
2822
- // LFS64 types have been removed in Emscripten 3.1.44+
2822
+ // LFS64 types have been removed in Emscripten 3.1.44
2823
2823
// https://github.com/emscripten-core/emscripten/pull/19812
2824
2824
"off64_t" => "off_t" . to_string ( ) ,
2825
2825
@@ -2843,7 +2843,7 @@ fn test_emscripten(target: &str) {
2843
2843
s if s. ends_with ( "_nsec" ) && struct_. starts_with ( "stat" ) => {
2844
2844
s. replace ( "e_nsec" , ".tv_nsec" )
2845
2845
}
2846
- // FIXME: appears that `epoll_event.data` is an union
2846
+ // Rust struct uses raw u64, rather than union
2847
2847
"u64" if struct_ == "epoll_event" => "data.u64" . to_string ( ) ,
2848
2848
s => s. to_string ( ) ,
2849
2849
}
@@ -2859,10 +2859,7 @@ fn test_emscripten(target: &str) {
2859
2859
// https://github.com/emscripten-core/emscripten/issues/5033
2860
2860
ty if ty. starts_with ( "epoll" ) => true ,
2861
2861
2862
- // FIXME: The size has been changed due to musl's time64
2863
- "time_t" => true ,
2864
-
2865
- // LFS64 types have been removed in Emscripten 3.1.44+
2862
+ // LFS64 types have been removed in Emscripten 3.1.44
2866
2863
// https://github.com/emscripten-core/emscripten/pull/19812
2867
2864
t => t. ends_with ( "64" ) || t. ends_with ( "64_t" ) ,
2868
2865
}
@@ -2871,30 +2868,19 @@ fn test_emscripten(target: &str) {
2871
2868
cfg. skip_struct ( move |ty| {
2872
2869
match ty {
2873
2870
// This is actually a union, not a struct
2874
- // FIXME: is this necessary?
2875
2871
"sigval" => true ,
2876
2872
2877
- // FIXME: It was removed in
2878
- // emscripten-core/emscripten@953e414
2879
- "pthread_mutexattr_t" => true ,
2880
-
2881
2873
// FIXME: Investigate why the test fails.
2882
2874
// Skip for now to unblock CI.
2883
2875
"pthread_condattr_t" => true ,
2884
-
2885
- // FIXME: The size has been changed when upgraded to musl 1.2.2
2886
- "pthread_mutex_t" => true ,
2876
+ "pthread_mutexattr_t" => true ,
2887
2877
2888
2878
// No epoll support
2889
2879
// https://github.com/emscripten-core/emscripten/issues/5033
2890
2880
ty if ty. starts_with ( "epoll" ) => true ,
2891
2881
ty if ty. starts_with ( "signalfd" ) => true ,
2892
2882
2893
- // FIXME: The size has been changed due to time64
2894
- "utimbuf" | "timeval" | "timespec" | "rusage" | "itimerval" | "sched_param"
2895
- | "stat" | "stat64" | "shmid_ds" | "msqid_ds" => true ,
2896
-
2897
- // LFS64 types have been removed in Emscripten 3.1.44+
2883
+ // LFS64 types have been removed in Emscripten 3.1.44
2898
2884
// https://github.com/emscripten-core/emscripten/pull/19812
2899
2885
ty => ty. ends_with ( "64" ) || ty. ends_with ( "64_t" ) ,
2900
2886
}
@@ -2903,12 +2889,9 @@ fn test_emscripten(target: &str) {
2903
2889
cfg. skip_fn ( move |name| {
2904
2890
match name {
2905
2891
// Emscripten does not support fork/exec/wait or any kind of multi-process support
2906
- // https://github.com/emscripten-core/emscripten/blob/3.1.30 /tools/system_libs.py#L973
2892
+ // https://github.com/emscripten-core/emscripten/blob/3.1.68 /tools/system_libs.py#L1100
2907
2893
"execv" | "execve" | "execvp" | "execvpe" | "fexecve" | "wait4" => true ,
2908
2894
2909
- // FIXME: Remove after emscripten-core/emscripten#18492 is released (> 3.1.30).
2910
- "clearenv" => true ,
2911
-
2912
2895
_ => false ,
2913
2896
}
2914
2897
} ) ;
@@ -2936,8 +2919,8 @@ fn test_emscripten(target: &str) {
2936
2919
"USRQUOTA" | "GRPQUOTA" | "Q_GETFMT" | "Q_GETINFO" | "Q_SETINFO" | "Q_SYNC"
2937
2920
| "Q_QUOTAON" | "Q_QUOTAOFF" | "Q_GETQUOTA" | "Q_SETQUOTA" => true ,
2938
2921
2939
- // FIXME: `SYS_gettid` was removed in
2940
- // emscripten-core/emscripten@6d6474e
2922
+ // `SYS_gettid` was removed in Emscripten v1.39.9
2923
+ // https://github.com/ emscripten-core/emscripten/pull/10439
2941
2924
"SYS_gettid" => true ,
2942
2925
2943
2926
// No personality.h
@@ -2946,19 +2929,11 @@ fn test_emscripten(target: &str) {
2946
2929
| "ADDR_LIMIT_32BIT" | "SHORT_INODE" | "WHOLE_SECONDS" | "STICKY_TIMEOUTS"
2947
2930
| "ADDR_LIMIT_3GB" => true ,
2948
2931
2949
- // FIXME: These values have been changed
2950
- | "POSIX_MADV_DONTNEED" // to 4
2951
- | "RLIMIT_NLIMITS" // to 16
2952
- | "RLIM_NLIMITS" // to 16
2953
- | "IPPROTO_MAX" // to 263
2954
- | "F_GETLK" // to 5
2955
- | "F_SETLK" // to 6
2956
- | "F_SETLKW" // to 7
2957
- | "O_TMPFILE" // to 65
2958
- | "SIG_IGN" // -1
2959
- => true ,
2932
+ // `SIG_IGN` has been changed to -2 since 1 is a valid function address
2933
+ // https://github.com/emscripten-core/emscripten/pull/14883
2934
+ "SIG_IGN" => true ,
2960
2935
2961
- // LFS64 types have been removed in Emscripten 3.1.44+
2936
+ // LFS64 types have been removed in Emscripten 3.1.44
2962
2937
// https://github.com/emscripten-core/emscripten/pull/19812
2963
2938
n if n. starts_with ( "RLIM64" ) => true ,
2964
2939
@@ -2968,23 +2943,18 @@ fn test_emscripten(target: &str) {
2968
2943
2969
2944
cfg. skip_field_type ( move |struct_, field| {
2970
2945
// This is a weird union, don't check the type.
2971
- // FIXME: is this necessary?
2972
2946
( struct_ == "ifaddrs" && field == "ifa_ifu" ) ||
2973
2947
// sighandler_t type is super weird
2974
- // FIXME: is this necessary?
2975
2948
( struct_ == "sigaction" && field == "sa_sigaction" ) ||
2976
2949
// sigval is actually a union, but we pretend it's a struct
2977
- // FIXME: is this necessary?
2978
2950
( struct_ == "sigevent" && field == "sigev_value" )
2979
2951
} ) ;
2980
2952
2981
2953
cfg. skip_field ( move |struct_, field| {
2982
2954
// this is actually a union on linux, so we can't represent it well and
2983
2955
// just insert some padding.
2984
- // FIXME: is this necessary?
2985
2956
( struct_ == "siginfo_t" && field == "_pad" ) ||
2986
2957
// musl names this __dummy1 but it's still there
2987
- // FIXME: is this necessary?
2988
2958
( struct_ == "glob_t" && field == "gl_flags" ) ||
2989
2959
// FIXME: After musl 1.1.24, it have only one field `sched_priority`,
2990
2960
// while other fields become reserved.
@@ -2996,7 +2966,6 @@ fn test_emscripten(target: &str) {
2996
2966
] . contains ( & field) )
2997
2967
} ) ;
2998
2968
2999
- // FIXME: test linux like
3000
2969
cfg. generate ( "../src/lib.rs" , "main.rs" ) ;
3001
2970
}
3002
2971
0 commit comments