Commit Graph

732 Commits

Author SHA1 Message Date
bluss
adb400dd0e Add the family of printf, scanf functions 2016-04-13 01:26:34 +02:00
bors
ba084f408a Auto merge of #261 - myfreeweb:master, r=alexcrichton
64-bit Android timegm fix

On aarch64 and x86_64, `timegm64` does not exist (see [time64.h](797351fd3b/ndk/platforms/android-L/include/time64.h)).

See rust-lang-deprecated/time#118 for usage. Since that patch, the time library switched to using libc for `timegm` (rust-lang-deprecated/time@51c0019), and it doesn't build on 64-bit Android. This PR fixes that.
2016-04-12 15:56:12 -07:00
Greg V
6b0e09c1f4 64-bit android fix 2016-04-12 22:44:18 +03:00
bors
e4447f406c Auto merge of #262 - alexcrichton:bump, r=alexcrichton
Bump to 0.2.10
2016-04-12 11:35:04 -07:00
Alex Crichton
b302bed9d2 Bump to 0.2.10 2016-04-12 11:09:00 -07:00
bors
74f8f4ae88 Auto merge of #260 - alexcrichton:correctly-gate-travis, r=alexcrichton
Use '&&' on travis, not ';'

Closes #258
2016-04-11 13:28:36 -07:00
Alex Crichton
dfd196efe6 Use '&&' on travis, not ';' 2016-04-11 13:28:21 -07:00
bors
b484e6f548 Auto merge of #256 - nodakai:fix-cpu_set, r=alexcrichton
Fix CPU_SET and CPU_ISSET
2016-04-11 09:02:23 -07:00
NODA, Kai
afa77dfa0e
Fix CPU_SET and CPU_ISSET
Signed-off-by: NODA, Kai <nodakai@gmail.com>
2016-04-10 19:14:51 +08:00
bors
60f90cf560 Auto merge of #237 - Nercury:use-signal-instead-of-bsd-signal, r=alexcrichton
Use now available link name "signal" instead of "bsd_signal"

On android, the `bsd_signal` is gone, the `signal` is available.

While this is the most obvious solution, I am not sure of a few things:
- How are we going to keep compatibility with older NDKs where `signal` does not exist;
- Was something dependent on this being different on android and thus would break (for example, the rust compiler uses this function, so it may break somewhere).

Fixes #236.
2016-04-06 16:50:11 -07:00
Nerijus Arlauskas
0b7ccdd119 Do not skip "signal" when building libc tests. 2016-04-06 20:56:54 +03:00
bors
f4411ad7db Auto merge of #250 - mrhota:readme_update, r=alexcrichton
Remove iOS doc links from README

Fixes #243
2016-04-04 22:28:30 -07:00
bors
c2d1c71eef Auto merge of #248 - mrhota:langinfo, r=alexcrichton
langinfo bindings and defs
2016-04-04 21:54:14 -07:00
A.J. Gardner
24c84f1360 Define xlocale and langinfo interfaces
There are many constants defined by langinfo, but we have the
new types, locale_t and nl_item.

We also have several functions, not all of which exist for every
platform:

nl_langinfo
nl_langinfo_l
newlocale
duplocale
freelocale
uselocale
querylocale
2016-04-04 20:51:44 -05:00
bors
7265c17d18 Auto merge of #254 - alexcrichton:rtld-default, r=alexcrichton
Add RTLD_DEFAULT to more platforms
2016-04-04 13:46:14 -07:00
Alex Crichton
031a450aeb Add RTLD_DEFAULT to more platforms 2016-04-04 13:14:54 -07:00
bors
2ded9aeae3 Auto merge of #249 - alexcrichton:fix-link, r=alexcrichton
Link to libraries when disabling `use_std`

This crate currently relies on libraries being linked to come from libstd, but
if `use_std` is disabled that's not true! In that case we need to pull in the
libraries ourselves.

Closes rust-lang/rust#32661
2016-04-04 10:03:27 -07:00
Alex Crichton
a28ec43900 Link to libraries when disabling use_std
This crate currently relies on libraries being linked to come from libstd, but
if `use_std` is disabled that's not true! In that case we need to pull in the
libraries ourselves.

Closes rust-lang/rust#32661
2016-04-04 10:02:52 -07:00
bors
fb2f0bbdab Auto merge of #253 - nodakai:strerror_r, r=alexcrichton
On non-musl Linux, strerror_r should be linked to __xpg_strerror_r

Currently `libc::strerror_r()` wrongly returns a `c_char` pointer as a large `c_int`.

Also exclude `MS_RMT_MASK` from `libc-test`.
2016-04-03 14:48:34 -07:00
bors
46cca7a06e Auto merge of #252 - mneumann:freebsd_dragonfly_pthread, r=alexcrichton
Add several pthread functions for DragonFly/FreeBSD

These are needed in order to fix/implement the guard page code of Rust
for DragonFly.
2016-04-03 11:54:31 -07:00
bors
331d70519e Auto merge of #247 - nodakai:clock_getres, r=alexcrichton
Add clock_getres(3) and improve clockid_t constants.

This is still a draft
2016-04-03 09:02:16 -07:00
NODA, Kai
4d1efd9e8a
Exclude MS_RMT_MASK from libc-test
It was updated recently, so the test is known to fail depending on the
libc version of the test environment.

Signed-off-by: NODA, Kai <nodakai@gmail.com>
2016-04-03 22:16:52 +08:00
NODA, Kai
75a69bf8e2
On non-musl Linux, strerror_r should be linked to __xpg_strerror_r
Signed-off-by: NODA, Kai <nodakai@gmail.com>
2016-04-03 22:16:43 +08:00
Michael Neumann
9940be6937 Add several pthread functions for DragonFly/FreeBSD
These are needed in order to fix/implement the guard page code of Rust
for DragonFly.
2016-04-03 12:28:23 +02:00
NODA, Kai
7e752a3b80
Add clock_getres(3) and more clockid_t constants.
Signed-off-by: NODA, Kai <nodakai@gmail.com>
2016-04-03 14:07:39 +08:00
A.J. Gardner
e335c50b13 Remove iOS doc links from README 2016-04-02 18:41:19 -05:00
bors
f288e185f4 Auto merge of #246 - kamalmarhubi:openpty, r=alexcrichton
unix: Add openpty(3) and forkpty(3) for non-Apple platforms

The functions were added for Apple in #202. Adding them to other
platforms was pending an amendment to RFC 1291 to expand the scope of
libc to include libutil. The amendment was merged as
  https://github.com/rust-lang/rfcs/pull/1529
2016-04-02 16:30:23 -07:00
Kamal Marhubi
9c4af10e88 unix: Add openpty(3) and forkpty(3) for non-Apple platforms
The functions were added for Apple in #202. Adding them to other
platforms was pending an amendment to RFC 1291 to expand the scope of
libc to include libutil. The amendment was merged as
  https://github.com/rust-lang/rfcs/pull/1529
2016-04-02 09:33:55 -04:00
bors
dfc1ab5f2b Auto merge of #244 - mrhota:basic_locale, r=alexcrichton
Add lconv type, and locale support for UNIX

We have lconv struct, setlocale(), and localeconv(). Constants live
under notbsd for now.
2016-03-31 10:15:53 -07:00
A.J. Gardner
5399c89f60 Change netbsd link_name for setlocale 2016-03-30 23:09:25 -05:00
A.J. Gardner
5a0c067f1b Define struct and consts for notbsds
Linux-likes have more locale categories than the BSDs (except for
musl). We define the common set of categories at the
src/unix/notbsd/mod.rs level, and leave the rest to the
platform-specific modules.
2016-03-30 22:51:47 -05:00
A.J. Gardner
0dc717626e Define struct and consts for bsds
The BSDs seem to have more peculiarities than the notbsds
2016-03-30 22:50:10 -05:00
A.J. Gardner
874852cff1 Pull lconv def down into notbsd 2016-03-30 19:59:47 -05:00
A.J. Gardner
912a7a03b4 Fix lconv field offsets for apple-likes 2016-03-30 19:49:42 -05:00
bors
62fb1d52b5 Auto merge of #245 - alexcrichton:bump, r=alexcrichton
Bump to 0.2.9
2016-03-30 17:40:49 -07:00
Alex Crichton
3de1107244 Bump to 0.2.9 2016-03-30 17:40:32 -07:00
bors
334b106303 Auto merge of #241 - alexcrichton:fix-header-footer, r=alexcrichton
Swap header/footer... dunno how they got that way?

Apparently they were swapped accidentally already!

Closes #240
2016-03-30 09:07:10 -07:00
A.J. Gardner
b788a5c736 Add locale.h in libc-test 2016-03-30 01:13:55 -05:00
A.J. Gardner
2bd6f12241 Fix long line
Lint caught a long line. This should fix the CI failure.
2016-03-30 00:55:49 -05:00
A.J. Gardner
110152c115 Add lconv type, and locale support for UNIX
We have lconv struct, setlocale(), and localeconv(). Constants live
under notbsd for now.
2016-03-30 00:36:43 -05:00
Alex Crichton
19e64f3cfb Swap header/footer... dunno how they got that way?
Apparently they were swapped accidentally already!

Closes #240
2016-03-28 13:58:13 -07:00
Nerijus Arlauskas
b2eec2470c Use now available link name "signal" instead of "bsd_signal".
Fixes #236.
2016-03-19 20:31:41 +02:00
bors
cd925e0ce1 Auto merge of #233 - kamalmarhubi:linux-fcntl, r=alexcrichton
linux: Add missing Linux-specific fcntls

Also move F_DUPFD_CLOEXEC up a level as it is available on Android.
2016-03-18 09:38:23 -07:00
Kamal Marhubi
b43118cb98 linux: Add missing Linux-specific fcntls
Also move F_DUPFD_CLOEXEC up a level as it is available on Android.

This commit leaves file sealing related fcntls and bitflag constants
out, as they are defined in `linux/fcntl.h` rather than `fcntl.h`. They
can be included once an approach for verification has been figured out.
See #235 for more detail.
2016-03-18 01:43:59 -04:00
bors
fa161aec16 Auto merge of #229 - kamalmarhubi:mount-flags, r=alexcrichton
linux: Move some MS_flags for mount(2) up

These flags are available on Android.
2016-03-15 00:12:31 -07:00
bors
aabff317d4 Auto merge of #226 - m4rw3r:master, r=alexcrichton
apple: Add TIOC* constants

From `sys/ioctl.h`.

Extracted on OS X 10.11.3.
2016-03-14 22:57:24 -07:00
bors
052118790c Auto merge of #230 - alexcrichton:winapi-update, r=alexcrichton
Update winapi
2016-03-14 21:59:54 -07:00
Alex Crichton
609693dae1 Update winapi 2016-03-14 21:59:21 -07:00
Kamal Marhubi
10bfe07651 linux: Move some MS_ flags for mount(2) up
These flags are available on Android.
2016-03-14 19:25:06 -04:00
Kamal Marhubi
4ff4acec36 linux: Comment distinction between msync and mount MS_ flags
They have different types and should be visually separated for ease of
reading.
2016-03-14 19:25:06 -04:00