Commit Graph

2904 Commits

Author SHA1 Message Date
ischeinkman
f64ee03115 Removed newlib struct duplicates. 2019-02-23 14:49:30 -08:00
Bryant Mairs
7dc2999574 Add extra traits for apple datatypes 2019-02-23 07:41:47 -08:00
Bryant Mairs
7597520dae Add extra traits for haiku datatypes 2019-02-22 20:15:38 -08:00
Bryant Mairs
35280a05f3 Add extra traits for fuchsia datatypes 2019-02-22 20:15:38 -08:00
bors
68701e7e67 Auto merge of #1274 - gnzlbg:clean_libctest_apple, r=gnzlbg
Clean libc-test for apple targets

This cleans up the build.rs of `libc-test` for apple targets.

I wanted to update the docker containers of some targets so that we can start testing newer currently-skipped APIs properly, but it is impossible to figure out which headers and APIs are skipped for each target, which has to change if we update the glibc version in one Linux container but not the other (updating them all at once is just madness).

This PR separates the testing of apple targets into its own self-contained function. This allows seeing exactly which headers are included, and which items are skipped. A lot of work will be required to separate the testing of all major platforms and make the script reasonable.

During the clean up, I discovered that, at least for apple targets, deprecated but not removed APIs are not tested. I re-enabled testing for those, and fixed `daemon`, which was not properly linking its symbol. I also added the `#[deprecated]` attribute to the `#[deprecated]` APIs of the apple targets. The attribute is available since Rust 1.9.0 and the min. Rust version we support is Rust 1.13.0.

Many other APIs are also currently not tested "because they are weird" which I interpret as "the test failed for an unknown reason", as a consequence:

* the signatures of execv, execve, and execvp are incorrect (see https://github.com/rust-lang/libc/issues/1272)

* the `sig_t` type is called `sighandler_t` in libc for some reason: https://github.com/rust-lang/libc/issues/1273

This probably explains why some other things, like the `sa_handler`/`sa_sigaction` fields of `sigaction` were skipped. The field is actually a union, which can be either a `sig_t` for the `sa_handler` field, or some other type for the `sa_sigaction` field, but because the distinction was not made, the field was not checked.

The latest ctest version can check volatile pointers, so a couple of skipped tests are now tested using this feature.
2019-02-22 18:18:25 +00:00
gnzlbg
f5cbdbc2b9 Clean libc-test for apple targets
This cleans up the build.rs of `libc-test` for apple targets.

I wanted to update the docker containers of some targets so that we can start
testing newer currently-skipped APIs properly, but it is impossible to figure
out which headers and APIs are skipped for each target.

This PR separates the testing of apple targets into its own self-contained
function. This allows seeing exactly which headers are included, and which items
are skipped. A lot of work will be required to separate the testing of all major
platforms and make the script reasonable.

During the clean up, I discovered that, at least for apple targets, deprecated
but not removed APIs are not tested. I re-enabled testing for those, and fixed
`daemon`, which was not properly linking its symbol. I also added the
`#[deprecated]` attribute to the `#[deprecated]` APIs of the apple targets. The
attribute is available since Rust 1.9.0 and the min. Rust version we support is
Rust 1.13.0.

Many other APIs are also currently not tested "because they are weird" which I
interpret as "the test failed for an unknown reason", as a consequence:

* the signatures of execv, execve, and execvp are incorrect (see
  https://github.com/rust-lang/libc/issues/1272)

* the `sig_t` type is called `sighandler_t` in libc for some reason:
  https://github.com/rust-lang/libc/issues/1273

This probably explains why some other things, like the
`sa_handler`/`sa_sigaction` fields of `sigaction` were skipped. The field is
actually a union, which can be either a `sig_t` for the `sa_handler` field, or
some other type for the `sa_sigaction` field, but because the distinction was
not made, the field was not checked.

The latest ctest version can check volatile pointers, so a couple of skipped
tests are now tested using this feature.
2019-02-22 19:18:02 +01:00
Bryant Mairs
a12c38332e Unify PartialEq and Hash implementation 2019-02-22 07:24:57 -08:00
bors
400372d7b9 Auto merge of #1270 - gnzlbg:no_extern_std, r=gnzlbg
Do not import the std library with use_std
2019-02-22 11:15:38 +00:00
bors
8c571e0ce9 Auto merge of #1269 - gnzlbg:fix_cp_pub, r=gnzlbg
Unnecessary pub use when private module use is available

Addresses part of #1266
2019-02-22 09:38:16 +00:00
gnzlbg
61aeeda955 Do not import the std library with use_std 2019-02-22 00:03:45 +01:00
gnzlbg
8eb506620c Unnecessary pub use when private module use is available 2019-02-21 23:51:15 +01:00
bors
fecc1fd607 Auto merge of #1268 - alexcrichton:fix-features, r=gnzlbg
Fix build of `rustc-dep-of-std` feature

Enusre that `no_core` is turned on, and while here update the `no_std`
header to be unconditionally applied.

Closes #1267
2019-02-21 20:52:11 +00:00
Alex Crichton
5049a97111 Fix build of rustc-dep-of-std feature
Enusre that `no_core` is turned on, and while here update the `no_std`
header to be unconditionally applied.

Closes #1267
2019-02-21 10:57:44 -08:00
bors
577fdc86b2 Auto merge of #1248 - Ralith:flowinfo, r=gnzlbg
Expose IPV6_FLOWINFO* on Linux
2019-02-21 09:21:11 +00:00
gnzlbg
dda85056bf Fix broken links in README 2019-02-21 10:18:06 +01:00
gnzlbg
cd49efc997 Fix typo in README; do not generate .nojekyll file in gh-pages branch 2019-02-21 08:46:25 +01:00
bors
5cefa3a2c3 Auto merge of #1263 - gnzlbg:no_core_build, r=gnzlbg
Test that targets without a shipping libcore / libstd build properly

This PR tests that `libc` builds on targets that currently don't ship a `libcore`/`libstd` by cross-compiling to them from Linux and MacOSX using `Xargo`.

This fixes the build on DragonflyBSD (superseeds #1237), Haiku, bitrig, and OpenBSD (superseeds #1259).

cc @asomers @strangelittlemonkey @semarie
2019-02-20 23:05:11 +00:00
gnzlbg
a25a42be76 Speed up documentation build by using cargo when possible 2019-02-20 18:42:34 +01:00
gnzlbg
575fdc8c0d Do not try to build documentation for apple targets from Linux 2019-02-20 17:57:01 +01:00
gnzlbg
7017701b21 Re-enable target-specific docs 2019-02-20 15:27:57 +01:00
gnzlbg
863d703910 Retry downloading artifacts to prevent spurious failures due to network issues 2019-02-20 13:01:00 +01:00
gnzlbg
5f9be7eebe Remove the CMSG_ APIs from bitrig 2019-02-20 11:22:43 +01:00
gnzlbg
7da4f477d0 cross-compile to the gnu windows targets on nightly with libstd 2019-02-20 11:21:38 +01:00
gnzlbg
6a6dd26447 Only fetch std component when there is something to fetch 2019-02-20 11:21:38 +01:00
gnzlbg
e3914cf31a Make the build script fail faster 2019-02-20 11:21:38 +01:00
gnzlbg
9bdc5122da The armv7r targets are not available on nightly 2019-02-20 11:21:38 +01:00
gnzlbg
34dd2da3f9 Run xargo only on Linux 2019-02-20 11:21:38 +01:00
gnzlbg
9a1d1f6445 Remove more documentation cruft 2019-02-20 11:21:38 +01:00
gnzlbg
971027d535 Fix bitrig build 2019-02-20 11:21:38 +01:00
gnzlbg
1c264bdafa Fix use of std:: in the OpenBSD-like module 2019-02-20 11:21:38 +01:00
gnzlbg
2e2e4e10c3 Fix unclosed delimiter in openbsd 2019-02-20 11:21:38 +01:00
gnzlbg
0180e40f22 Libcore fails to build for sparc-unknown-linux-gnu 2019-02-20 11:21:38 +01:00
gnzlbg
bbe4571216 Remove non-existent uclib targets 2019-02-20 11:21:38 +01:00
gnzlbg
2130d45fb1 Fix Haiku build 2019-02-20 11:21:38 +01:00
gnzlbg
dcf20b75d4 Fix DragonflyBSD build 2019-02-20 11:21:38 +01:00
gnzlbg
0ffba9f96b Test that targets without a libstd component build on CI using xargo 2019-02-20 11:21:38 +01:00
bors
c2904a70fa Auto merge of #1261 - glebpom:master, r=gnzlbg
Add AF_ALG constants and structures
2019-02-20 08:43:11 +00:00
Gleb Pomykalov
bce3ee3e71 Properly implement Debug for AF_ALG structures 2019-02-20 01:04:50 +03:00
Gleb Pomykalov
2e5358ae60 Revert "Improve Debug for AF_ALG structures"
This reverts commit ae2663a7db.
2019-02-20 00:10:35 +03:00
Gleb Pomykalov
ae2663a7db Improve Debug for AF_ALG structures 2019-02-19 23:41:52 +03:00
Gleb Pomykalov
c35d8fbfbe Uncomment salg_type from socket_alg debug_struct 2019-02-19 18:17:25 +03:00
Gleb Pomykalov
34c96d74e1 Add comment on ALG_SET_AEAD_* exclusion 2019-02-19 18:14:01 +03:00
Gleb Pomykalov
d0f4c6e0fc Ignore ALG_SET_AEAD_* constants on MUSL tests 2019-02-19 16:35:25 +03:00
bors
501ca548b2 Auto merge of #1256 - vdagonneau:master, r=gnzlbg
Moved inotify declarations up so that it works on android too.

Following my previous pull request to include inotify bindings, I would like to move the code so that it benefits android too.
2019-02-19 10:17:40 +00:00
Gleb Pomykalov
d6fe4f5463 fix unsafe blocks 2019-02-19 12:51:58 +03:00
Vincent Dagonneau
d25a054afe Removed trailing spaces. 2019-02-19 10:35:07 +01:00
vdagonneau
52e1d0f38d
Merge branch 'master' into master 2019-02-19 10:19:50 +01:00
Vincent Dagonneau
87b813a7cf Moved inotify_rm_watch out of the generic notbsd target and into specific linux and android targets because the second argument has a different type in android and linux. 2019-02-19 09:38:56 +01:00
Gleb Pomykalov
3ec632cbd9 fix as_slice for af_alg_iv 2019-02-19 10:46:05 +03:00
Gleb Pomykalov
97b5b3494b improve naming 2019-02-18 22:35:42 +03:00