-
Notifications
You must be signed in to change notification settings - Fork 1k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add musl definitions for x86, arm and asmjs
I've tested x86 against C locally, but not arm or asmjs. I added the arm definitions because asmjs's C is derived from arms. Mysteriously, my locally-built musl does not contain a definition for _SC_2_C_VERSION, so I just removed it.
- Loading branch information
Showing
8 changed files
with
242 additions
and
83 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,73 @@ | ||
s! { | ||
pub struct stat { | ||
pub st_dev: ::dev_t, | ||
__st_dev_padding: ::c_int, | ||
__st_ino_truncated: ::c_long, | ||
pub st_mode: ::mode_t, | ||
pub st_nlink: ::nlink_t, | ||
pub st_uid: ::uid_t, | ||
pub st_gid: ::gid_t, | ||
pub st_rdev: ::dev_t, | ||
__st_rdev_padding: ::c_int, | ||
pub st_size: ::off_t, | ||
pub st_blksize: ::blksize_t, | ||
pub st_blocks: ::blkcnt_t, | ||
pub st_atim: ::timespec, | ||
pub st_mtim: ::timespec, | ||
pub st_ctim: ::timespec, | ||
pub st_ino: ::ino_t, | ||
} | ||
|
||
pub struct stat64 { | ||
pub st_dev: ::dev_t, | ||
__st_dev_padding: ::c_int, | ||
__st_ino_truncated: ::c_long, | ||
pub st_mode: ::mode_t, | ||
pub st_nlink: ::nlink_t, | ||
pub st_uid: ::uid_t, | ||
pub st_gid: ::gid_t, | ||
pub st_rdev: ::dev_t, | ||
__st_rdev_padding: ::c_int, | ||
pub st_size: ::off_t, | ||
pub st_blksize: ::blksize_t, | ||
pub st_blocks: ::blkcnt_t, | ||
pub st_atim: ::timespec, | ||
pub st_mtim: ::timespec, | ||
pub st_ctim: ::timespec, | ||
pub st_ino: ::ino_t, | ||
} | ||
|
||
pub struct pthread_attr_t { | ||
__size: [u32; 9] | ||
} | ||
|
||
pub struct sigset_t { | ||
__val: [::c_ulong; 32], | ||
} | ||
|
||
pub struct shmid_ds { | ||
pub shm_perm: ::ipc_perm, | ||
pub shm_segsz: ::size_t, | ||
pub shm_atime: ::time_t, | ||
__unused1: ::c_int, | ||
pub shm_dtime: ::time_t, | ||
__unused2: ::c_int, | ||
pub shm_ctime: ::time_t, | ||
__unused3: ::c_int, | ||
pub shm_cpid: ::pid_t, | ||
pub shm_lpid: ::pid_t, | ||
pub shm_nattch: ::c_ulong, | ||
__pad1: ::c_ulong, | ||
__pad2: ::c_ulong, | ||
} | ||
|
||
pub struct msghdr { | ||
pub msg_name: *mut ::c_void, | ||
pub msg_namelen: ::socklen_t, | ||
pub msg_iov: *mut ::iovec, | ||
pub msg_iovlen: ::c_int, | ||
pub msg_control: *mut ::c_void, | ||
pub msg_controllen: ::socklen_t, | ||
pub msg_flags: ::c_int, | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,76 @@ | ||
s! { | ||
pub struct stat { | ||
pub st_dev: ::dev_t, | ||
pub st_ino: ::ino_t, | ||
pub st_nlink: ::nlink_t, | ||
pub st_mode: ::mode_t, | ||
pub st_uid: ::uid_t, | ||
pub st_gid: ::gid_t, | ||
__pad0: ::c_int, | ||
pub st_rdev: ::dev_t, | ||
pub st_size: ::off_t, | ||
pub st_blksize: ::blksize_t, | ||
pub st_blocks: ::blkcnt_t, | ||
pub st_atime: ::time_t, | ||
pub st_atime_nsec: ::c_long, | ||
pub st_mtime: ::time_t, | ||
pub st_mtime_nsec: ::c_long, | ||
pub st_ctime: ::time_t, | ||
pub st_ctime_nsec: ::c_long, | ||
__unused: [::c_long; 3], | ||
} | ||
|
||
pub struct stat64 { | ||
pub st_dev: ::dev_t, | ||
pub st_ino: ::ino64_t, | ||
pub st_nlink: ::nlink_t, | ||
pub st_mode: ::mode_t, | ||
pub st_uid: ::uid_t, | ||
pub st_gid: ::gid_t, | ||
__pad0: ::c_int, | ||
pub st_rdev: ::dev_t, | ||
pub st_size: ::off_t, | ||
pub st_blksize: ::blksize_t, | ||
pub st_blocks: ::blkcnt64_t, | ||
pub st_atime: ::time_t, | ||
pub st_atime_nsec: ::c_long, | ||
pub st_mtime: ::time_t, | ||
pub st_mtime_nsec: ::c_long, | ||
pub st_ctime: ::time_t, | ||
pub st_ctime_nsec: ::c_long, | ||
__reserved: [::c_long; 3], | ||
} | ||
|
||
pub struct pthread_attr_t { | ||
__size: [u64; 7] | ||
} | ||
|
||
pub struct sigset_t { | ||
__val: [::c_ulong; 16], | ||
} | ||
|
||
pub struct shmid_ds { | ||
pub shm_perm: ::ipc_perm, | ||
pub shm_segsz: ::size_t, | ||
pub shm_atime: ::time_t, | ||
pub shm_dtime: ::time_t, | ||
pub shm_ctime: ::time_t, | ||
pub shm_cpid: ::pid_t, | ||
pub shm_lpid: ::pid_t, | ||
pub shm_nattch: ::c_ulong, | ||
__pad1: ::c_ulong, | ||
__pad2: ::c_ulong, | ||
} | ||
|
||
pub struct msghdr { | ||
pub msg_name: *mut ::c_void, | ||
pub msg_namelen: ::socklen_t, | ||
pub msg_iov: *mut ::iovec, | ||
pub msg_iovlen: ::c_int, | ||
__pad1: ::c_int, | ||
pub msg_control: *mut ::c_void, | ||
pub msg_controllen: ::socklen_t, | ||
__pad2: ::socklen_t, | ||
pub msg_flags: ::c_int, | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.