@@ -8,6 +8,7 @@ pub type time_t = i32;
8
8
pub type suseconds_t = i32 ;
9
9
pub type wchar_t = u32 ;
10
10
pub type off_t = i32 ;
11
+ pub type off64_t = i64 ;
11
12
pub type ino_t = u32 ;
12
13
pub type blkcnt_t = u32 ;
13
14
pub type blksize_t = u32 ;
48
49
pub st_ino: :: c_ulonglong,
49
50
}
50
51
52
+ pub struct stat64 {
53
+ pub st_dev: :: c_ulonglong,
54
+ __pad0: [ :: c_uchar; 4 ] ,
55
+ __st_ino: :: ino_t,
56
+ pub st_mode: :: c_uint,
57
+ pub st_nlink: :: c_uint,
58
+ pub st_uid: :: uid_t,
59
+ pub st_gid: :: gid_t,
60
+ pub st_rdev: :: c_ulonglong,
61
+ __pad3: [ :: c_uchar; 4 ] ,
62
+ pub st_size: :: c_longlong,
63
+ pub st_blksize: blksize_t,
64
+ pub st_blocks: :: c_ulonglong,
65
+ pub st_atime: :: c_ulong,
66
+ pub st_atime_nsec: :: c_ulong,
67
+ pub st_mtime: :: c_ulong,
68
+ pub st_mtime_nsec: :: c_ulong,
69
+ pub st_ctime: :: c_ulong,
70
+ pub st_ctime_nsec: :: c_ulong,
71
+ pub st_ino: :: c_ulonglong,
72
+ }
73
+
51
74
pub struct dirent {
52
75
pub d_ino: u64 ,
53
76
pub d_off: i64 ,
56
79
pub d_name: [ :: c_char; 256 ] ,
57
80
}
58
81
82
+ pub struct dirent64 {
83
+ pub d_ino: u64 ,
84
+ pub d_off: i64 ,
85
+ pub d_reclen: :: c_ushort,
86
+ pub d_type: :: c_uchar,
87
+ pub d_name: [ :: c_char; 256 ] ,
88
+ }
89
+
90
+ pub struct rlimit64 {
91
+ pub rlim_cur: u64 ,
92
+ pub rlim_max: u64 ,
93
+ }
94
+
59
95
pub struct pthread_attr_t {
60
96
pub flags: :: uint32_t,
61
97
pub stack_base: * mut :: c_void,
@@ -588,6 +624,28 @@ extern {
588
624
pub fn timegm64 ( tm : * const :: tm ) -> time64_t ;
589
625
pub fn eventfd ( init : :: c_uint , flags : :: c_int ) -> :: c_int ;
590
626
pub fn ptrace ( request : :: c_int , ...) -> :: c_long ;
627
+ pub fn fstat64 ( fildes : :: c_int , buf : * mut stat64 ) -> :: c_int ;
628
+ pub fn stat64 ( path : * const c_char , buf : * mut stat64 ) -> :: c_int ;
629
+ pub fn open64 ( path : * const c_char , oflag : :: c_int , ...) -> :: c_int ;
630
+ pub fn creat64 ( path : * const c_char , mode : mode_t ) -> :: c_int ;
631
+ pub fn lseek64 ( fd : :: c_int , offset : off64_t , whence : :: c_int ) -> off64_t ;
632
+ pub fn pread64 ( fd : :: c_int , buf : * mut :: c_void , count : :: size_t ,
633
+ offset : off64_t ) -> :: ssize_t ;
634
+ pub fn pwrite64 ( fd : :: c_int , buf : * const :: c_void , count : :: size_t ,
635
+ offset : off64_t ) -> :: ssize_t ;
636
+ pub fn mmap64 ( addr : * mut :: c_void ,
637
+ len : :: size_t ,
638
+ prot : :: c_int ,
639
+ flags : :: c_int ,
640
+ fd : :: c_int ,
641
+ offset : off64_t )
642
+ -> * mut :: c_void ;
643
+ pub fn lstat64 ( path : * const c_char , buf : * mut stat64 ) -> :: c_int ;
644
+ pub fn ftruncate64 ( fd : :: c_int , length : off64_t ) -> :: c_int ;
645
+ pub fn readdir64_r ( dirp : * mut :: DIR , entry : * mut :: dirent64 ,
646
+ result : * mut * mut :: dirent64 ) -> :: c_int ;
647
+ pub fn getrlimit64 ( resource : :: c_int , rlim : * mut rlimit64 ) -> :: c_int ;
648
+ pub fn setrlimit64 ( resource : :: c_int , rlim : * const rlimit64 ) -> :: c_int ;
591
649
}
592
650
593
651
cfg_if ! {
0 commit comments