- some tests are failing
- remove readlink, timegm and sig* functions in favor of the
unix/mod.rs definitions
- remove time64_t (it is not defined for aarch64)
- move some definitions to android/b32.rs and create appropriated
definitions in android/b64.rs
Make readdir available on all unix targets
The readdir_r call has problems, and we'll probably want to move to
readdir on many, if not most, unix targets. This patch makes readdir
available in unix, rather than just solaris as before.
See https://github.com/rust-lang/rust/issues/40021
The readdir_r call has problems, and we'll probably want to move to
readdir on many, if not most, unix targets. This patch makes readdir
available in unix, rather than just solaris as before.
See https://github.com/rust-lang/rust/issues/40021
Added *_setpshared and *_getpshared bindings
Adding bindings to posix pthreads functions vital for IPC via shared memory.
That's my first PR into libc and I'm not proficient in unix systems programming, so I would really appreciate if someone reviewed it in case I missed something regardrless of the passed tests.
Thanks!
posix definitions should be used on Solaris
For compatibility reasons, Solaris historically had its header files
setup so that, unless specifically requested through specific header
defines, either the old pre-POSIX interfaces or POSIX.1c Draft 6
interfaces were used. However, in the case of rust, since these symbols
are linked directly instead of via system header files, the underlying
posix symbol name can be used directly instead.
These definitions should be corrected to match what they do on almost
every other platform.
Be aware this is a breaking change in terms of interface for any crates
/ consumers of these interfaces for Solaris.
Fixes#522
For compatibility reasons, Solaris historically had its header files
setup so that, unless specifically requested through specific header
defines, either the old pre-POSIX interfaces or POSIX.1c Draft 6
interfaces were used. However, in the case of rust, since these symbols
are linked directly instead of via system header files, the underlying
posix symbol name can be used directly instead.
These definitions should be corrected to match what they do on almost
every other platform.
Be aware this is a breaking change in terms of interface for any crates
/ consumers of these interfaces for Solaris.
Fixes#522
WIFCONTINUED function on Linux and FreeBSD
* Adds the missing WIFCONTINUED function to Linux (in `src/unix/notbsd/mod.rs`).
* Modifies the signature of WIFCONTINUED on FreeBSD (`src/unix/bsd/freebsdlike/mod.rs`) to be consistent with the ones on MacOS and Linux.
Correct solaris libc definitions:
* pthread_t is defined as uint_t, so must be c_uint, not uintptr_t, just
as pthread_key_t is already defined
* fd_set is defined as long, so must be i32/i64 based on
target_pointer_width; this also fixes an indirect endianness issue
encountered on sparc
* FD_SETSIZE should be defined as 65536 when target_pointer_width = 64
Fixes#515
* pthread_t is defined as uint_t, so must be c_uint, not uintptr_t, just
as pthread_key_t is already defined
* fd_set is defined as long, so must be i32/i64 based on
target_pointer_width; this also fixes an indirect endianness issue
encountered on sparc
* FD_SETSIZE should be defined as 65536 when target_pointer_width = 64
Fixes#515
Add AF_UNSPEC from Apple socket.h
[socket.h](https://opensource.apple.com/source/xnu/xnu-792.13.8/bsd/sys/socket.h) of Apple contains this definition so i'm not sure why it is missing from libc.
The same goes for other BSD-like OSes...
Is there some particular reasons why it is so?
Run ios tests
This WIP PR runs the tests on the iOS simulator. I've tested it locally using macOS Sierra and XCode 8.2.1. I get this output:
RUNNING ALL TESTS
PASSED 6756 tests
The python script probably needs to be customized for the specific failure output from this test runner (update: newest commit should have this).