Add timerfd API on Linux
This change adds the Linux-specific timerfd API to libc.
```C
#include <sys/timerfd.h>
int timerfd_create(int clockid, int flags);
int timerfd_gettime(int fd, struct itimerspec *curr_value);
int timerfd_settime(int fd, int flags,
const struct itimerspec *new_value,
struct itimerspec *old_value);
```
The timerfd API has been available since kernel 2.6.25 and in glibc since version 2.8.
I'm not sure if I put the changes in the right places, so please review with great care.
Fix dev_t minor() bitmasking on Linux
This code appears to be modeled on the macros in glibc bits/sysmacros.h
(since Glibc 2.26). Fix the masking of bits for minor() to match that
implementation, which also corresponds with the explanatory comment in
that file.
This code appears to be modeled on the macros in glibc bits/sysmacros.h
(since Glibc 2.26). Fix the masking of bits for minor() to match that
implementation, which also corresponds with the explanatory comment in
that file.
Updated types of PTRACE requests for musl to be consistent.
For some reason the type of ptrace request constants in musl change for the register based requests. As they are used in the same way and this doesn't mimic musl this has been changed for consistency and ease of use.
First raised in issue #744
Add asmjs/wasm32 to CI
Rebase of #610 and also move emscripten up much higher in the hierarchy to
ensure that it doesn't have too much of a ripple effect on other platforms.
This involved moving down a good number of definitions, but hopefully was done
with care to not break anything!
Add syscall constants to more Android/Linux targets
Primarily adding `SYS_memfd_create` and `SYS_pivot_root` for `nix`. But I also equalized a few constants across platforms so some of the other ones that were defined on some targets are now defined across all linux/android targets.
For some reason the type of ptrace request constants in musl change for the register based requests. As they are used in the same way and this doesn't mimic musl this has been changed for consistency and ease of use.
Rebase of #610 and also move emscripten up much higher in the hierarchy to
ensure that it doesn't have too much of a ripple effect on other platforms.
This involved moving down a good number of definitions, but hopefully was done
with care to not break anything!