@@ -37,10 +37,6 @@ pub const SO_PASSCRED: ::c_int = 16;
3737pub const SO_PEERCRED : :: c_int = 17 ;
3838pub const SO_RCVLOWAT : :: c_int = 18 ;
3939pub const SO_SNDLOWAT : :: c_int = 19 ;
40- pub const SO_RCVTIMEO : :: c_int = 20 ;
41- pub const SO_SNDTIMEO : :: c_int = 21 ;
42- // pub const SO_RCVTIMEO_OLD: ::c_int = 20;
43- // pub const SO_SNDTIMEO_OLD: ::c_int = 21;
4440pub const SO_SECURITY_AUTHENTICATION : :: c_int = 22 ;
4541pub const SO_SECURITY_ENCRYPTION_TRANSPORT : :: c_int = 23 ;
4642pub const SO_SECURITY_ENCRYPTION_NETWORK : :: c_int = 24 ;
@@ -49,18 +45,37 @@ pub const SO_ATTACH_FILTER: ::c_int = 26;
4945pub const SO_DETACH_FILTER : :: c_int = 27 ;
5046pub const SO_GET_FILTER : :: c_int = SO_ATTACH_FILTER ;
5147pub const SO_PEERNAME : :: c_int = 28 ;
52- pub const SO_TIMESTAMP : :: c_int = 29 ;
48+
49+ cfg_if ! {
50+ if #[ cfg( all(
51+ linux_time_bits64,
52+ any( target_arch = "arm" , target_arch = "x86" )
53+ ) ) ] {
54+ pub const SO_TIMESTAMP : :: c_int = 63 ;
55+ pub const SO_TIMESTAMPNS : :: c_int = 64 ;
56+ pub const SO_TIMESTAMPING : :: c_int = 65 ;
57+ pub const SO_RCVTIMEO : :: c_int = 66 ;
58+ pub const SO_SNDTIMEO : :: c_int = 67 ;
59+ } else {
60+ pub const SO_TIMESTAMP : :: c_int = 29 ;
61+ pub const SO_TIMESTAMPNS : :: c_int = 35 ;
62+ pub const SO_TIMESTAMPING : :: c_int = 37 ;
63+ pub const SO_RCVTIMEO : :: c_int = 20 ;
64+ pub const SO_SNDTIMEO : :: c_int = 21 ;
65+ }
66+ }
5367// pub const SO_TIMESTAMP_OLD: ::c_int = 29;
68+ // pub const SO_TIMESTAMPNS_OLD: ::c_int = 35;
69+ // pub const SO_TIMESTAMPING_OLD: ::c_int = 37;
70+ // pub const SO_RCVTIMEO_OLD: ::c_int = 20;
71+ // pub const SO_SNDTIMEO_OLD: ::c_int = 21;
72+
5473pub const SO_ACCEPTCONN : :: c_int = 30 ;
5574pub const SO_PEERSEC : :: c_int = 31 ;
5675pub const SO_SNDBUFFORCE : :: c_int = 32 ;
5776pub const SO_RCVBUFFORCE : :: c_int = 33 ;
5877pub const SO_PASSSEC : :: c_int = 34 ;
59- pub const SO_TIMESTAMPNS : :: c_int = 35 ;
60- // pub const SO_TIMESTAMPNS_OLD: ::c_int = 35;
6178pub const SO_MARK : :: c_int = 36 ;
62- pub const SO_TIMESTAMPING : :: c_int = 37 ;
63- // pub const SO_TIMESTAMPING_OLD: ::c_int = 37;
6479pub const SO_PROTOCOL : :: c_int = 38 ;
6580pub const SO_DOMAIN : :: c_int = 39 ;
6681pub const SO_RXQ_OVFL : :: c_int = 40 ;
0 commit comments