Commit graph

2161 commits

Author SHA1 Message Date
bors 787420a7a3 Auto merge of #946 - bgermann:master, r=alexcrichton
Add ___errno() for Solaris
2018-03-10 18:29:06 +00:00
bors 650d58ea4f Auto merge of #947 - bgermann:master, r=alexcrichton
Edit documentation

Add sparc64-unknown-linux-gnu and x86_64-sun-solaris.
Remove aarch64-unknown-linux-musl.
2018-03-10 18:03:25 +00:00
bgermann cf70168621 Edit documentation
Add sparc64-unknown-linux-gnu and x86_64-sun-solaris.
Remove aarch64-unknown-linux-musl.
2018-03-10 13:10:50 +01:00
bgermann 4c1d1f809d Add ___errno() for Solaris 2018-03-10 09:45:55 +01:00
bors ebb3d05fd4 Auto merge of #945 - wictory:rectract_ucred_from_openbsd, r=alexcrichton
Retract ucred type alias for sockpeercred from OpenBSD and Bitrig

Introduced in [this](https://github.com/rust-lang/libc/pull/941) PR.
2018-03-08 21:06:48 +00:00
Wictor Lund ba2e460b4e Retract ucred type alias for sockpeercred from OpenBSD and Bitrig 2018-03-08 22:15:12 +02:00
bors 837310de9a Auto merge of #942 - wictory:pledge_changed, r=alexcrichton
Arguments of pledge(2) changed.

The arguments of pledge(2) have changed. However, the changes have to yet been propagated to Bitrig.

https://marc.info/?l=openbsd-tech&m=151268831628549&w=2
2018-03-07 22:12:38 +00:00
bors 1669334a6e Auto merge of #943 - wictory:recycle_ffi_openbsd, r=alexcrichton
Recycle IFF_NOTRAILERS into IFF_STATICARP in OpenBSD but not in Bitrig.

https://cvsweb.openbsd.org/cgi-bin/cvsweb/src/sys/net/if.h?rev=1.190&content-type=text/x-cvsweb-markup
2018-03-07 21:26:12 +00:00
bors 30c205c7b1 Auto merge of #944 - wictory:invalid_functions_in_openbsd, r=alexcrichton
getpwent_r() and getgrent_r() doesn't exist in OpenBSD and Bitrig
2018-03-07 16:27:40 +00:00
Wictor Lund 88c536dc75 Recycle IFF_NOTRAILERS into IFF_STATICARP in OpenBSD but not in Bitrig.
https://cvsweb.openbsd.org/cgi-bin/cvsweb/src/sys/net/if.h?rev=1.190&content-type=text/x-cvsweb-markup
2018-03-07 18:17:48 +02:00
Wictor Lund 6b20b3761c getpwent_r() and getgrent_r() exists in NetBSD, but not in OpenBSD and Bitrig. 2018-03-07 18:16:37 +02:00
Wictor Lund 349d343caa Arguments of pledge(2) changed.
https://marc.info/?l=openbsd-tech&m=151268831628549&w=2
2018-03-07 17:52:34 +02:00
bors 659de79564 Auto merge of #941 - wictory:ucred_openbsd, r=alexcrichton
Added ucred (sockpeercred) for OpenBSD and Bitrig

OpenBSD and Bitrig has `struct ucred`implemented in the way it is used in `getsockopt(2)` with `SOL_SOCKET` and `SO_PEERCRED`. However, it is called `struct sockpeercred`.

Source: https://cvsweb.openbsd.org/cgi-bin/cvsweb/src/sys/sys/socket.h?rev=1.65&content-type=text/x-cvsweb-markup

I added a type alias for `ucred` to enable Linux compatibility, but I'm not sure this is the correct way to do it.
2018-03-07 15:14:59 +00:00
Wictor Lund 2e38d9a944 Added ucred (sockpeercred) for OpenBSD and Bitrig 2018-03-07 16:00:43 +02:00
bors ed04152aac Auto merge of #939 - ctrlcctrlv:master, r=alexcrichton
Add FreeBSD `get[pw|gr]ent_r`, forgotten in #934

Sorry, accidentally forgot this when submitting #934..
2018-03-05 16:06:48 +00:00
Fredrick Brennan 528374ed9a Add FreeBSD get[pw|gr]ent_r, forgotten in #934
Sorry, accidentally forgot this when submitting #934..
2018-03-05 21:25:55 +08:00
bors 936e16bccb Auto merge of #934 - ctrlcctrlv:master, r=alexcrichton
Add passwd/group APIs needed for nix-rust/nix#864

Hope I did this right. I only added platforms I could personally test. . .

cc: @gnzlbg
2018-03-03 03:25:49 +00:00
Fredrick Brennan d058e0c87a Refresh Cargo.lock 2018-03-05 02:52:46 +00:00
Fredrick Brennan 6d959f1a53 Fix BSD errors (hopefully) 2018-03-04 13:11:04 +00:00
Fredrick Brennan 99869e02ec Fix failure to document for Open/NetBSD 2018-03-04 10:48:39 +00:00
Fredrick Brennan 0f24a662b0 Fix long line 2018-03-04 10:41:02 +00:00
Fredrick Brennan 6228556cfa Fix issues raised by @gnzlbg 2018-03-04 10:09:43 +00:00
Fredrick Brennan f59c095c5c Remove "double blank line" 2018-03-03 11:53:39 +00:00
Fredrick Brennan 74c554c395 Fix build error on stable Rust 2018-03-03 11:26:40 +00:00
Fredrick Brennan 5f9538d1e2 Add passwd/group APIs needed for nix-rust/nix#864 2018-03-03 11:13:02 +00:00
bors 68d4848fe6 Auto merge of #937 - bdrewery:freebsd-ino64-compat, r=alexcrichton
Use pre-ino64 FreeBSD symbols to resolve binary compatibility.

This follows the same method as other platforms like OSX and NetBSD.

This will fix rustup and building from git (once libc is updated for bootstrap)
on FreeBSD12 post-ino64 in f713b08c02.
It also avoids having to hotpatch the stage0 compiler, and HOME/.cargo
libc files on FreeBSD12 to build rust.

The only real pitfall is that this will prevent interaction with inodes that
have an ino_t above the 32-bit limit due to truncation.  On the other hand
Rust won't work at all on 12 without doing this currently.  In general
it should not be a problem for users and if they need 64-bit ino_t they
can use a patched libc, rather than the current state of affairs in
requiring a patched libc to use Rust on 12.

A better, or complementary, approach would be something like proposed in
https://github.com/rust-lang/rfcs/pull/2048 to allow targetting a specific
version of FreeBSD. This would allow Rust to default to this compatibility
mode by targetting FreeBSD10 and still allow targetting FreeBSD12 for 64-bit
ino_t.

The symbol versions used were taken from the old version in
f713b08c02 (diff-61a32fcfb7ecd4517665fed591813c57)
and
f713b08c02 (diff-7f67ccf8b5f44ff2f54eaab0207abb8d).

The scope of functions versioned here differs from other platforms as
not all structs were modified that were on others, such as DIR for
`opendir`, `telldir`, etc.  Only functions using dirent, stat, glob_t,
and dev_t need the changes.

Fixes https://github.com/rust-lang/rust/issues/42681
2018-03-02 01:19:11 +00:00
Bryan Drewery 78f93220d7 Use pre-ino64 FreeBSD symbols to resolve binary compatibility.
This follows the same method as other platforms like OSX and NetBSD.

This will fix rustup and building from git (once libc is updated for bootstrap)
on FreeBSD12 post-ino64 in f713b08c02.
It also avoids having to hotpatch the stage0 compiler, and HOME/.cargo
libc files on FreeBSD12 to build rust.

The only real pitfall is that this will prevent interaction with inodes that
have an ino_t above the 32-bit limit due to truncation.  On the other hand
Rust won't work at all on 12 without doing this currently.  In general
it should not be a problem for users and if they need 64-bit ino_t they
can use a patched libc, rather than the current state of affairs in
requiring a patched libc to use Rust on 12.

A better, or complementary, approach would be something like proposed in
https://github.com/rust-lang/rfcs/pull/2048 to allow targetting a specific
version of FreeBSD. This would allow Rust to default to this compatibility
mode by targetting FreeBSD10 and still allow targetting FreeBSD12 for 64-bit
ino_t.

The symbol versions used were taken from the old version in
f713b08c02 (diff-61a32fcfb7ecd4517665fed591813c57)
and
f713b08c02 (diff-7f67ccf8b5f44ff2f54eaab0207abb8d).

The scope of functions versioned here differs from other platforms as
not all structs were modified that were on others, such as DIR for
`opendir`, `telldir`, etc.  Only functions using dirent, stat, glob_t,
and dev_t need the changes.

Fixes https://github.com/rust-lang/rust/issues/42681
2018-03-01 15:26:26 -08:00
bors f0938610e5 Auto merge of #936 - bdrewery:freebsd-kevent-compat, r=alexcrichton
Link against kevent@FBSD_1.0 to fix ABI compat with FreeBSD12.

struct kevent was modified in FreeBSD12.  The @FBSD_1.0 symbol supports the old
structure ABI still.

This allows the `mio` crate tests to now pass on FreeBSD12.
2018-03-01 20:50:57 +00:00
Bryan Drewery 969ad2b73c Link against kevent@FBSD_1.0 to fix ABI compat with FreeBSD12.
struct kevent was modified in FreeBSD12.  The @FBSD_1.0 symbol supports the old
structure ABI still.

This allows the `mio` crate tests to now pass on FreeBSD12.
2018-03-01 12:36:00 -08:00
bors 677b645353 Auto merge of #935 - bgermann:master, r=alexcrichton
Add Solaris constants needed by net2

The added constants are
IPV6_UNICAST_HOPS,
IPV6_MULTICAST_IF,
IPV6_MULTICAST_HOPS,
IP_MULTICAST_IF.
2018-03-01 15:05:18 +00:00
bgermann c299cc49d3 Add Solaris constants needed by net2
The added constants are
IPV6_UNICAST_HOPS,
IPV6_MULTICAST_IF,
IPV6_MULTICAST_HOPS,
IP_MULTICAST_IF.
2018-03-01 12:48:24 +01:00
bors 2bfacc8633 Auto merge of #933 - raphlinus:ipv6_fuchsia, r=alexcrichton
Add IPV6_UNICAST_HOPS to fuchsia module

Recent change #925 added constants for IPV6 multicast, but seems to have inadvertently left off IPV6_UNICAST_HOPS from the fuchsia module.

Fixes #932
2018-02-28 23:48:15 +00:00
Raph Levien 709709db15 Add IPV6_UNICAST_HOPS to fuchsia module
Recent change #925 added constants for IPV6 multicast, but seems
to have inadvertently left off IPV6_UNICAST_HOPS from fuchsia.

Fixes #932
2018-02-28 15:41:50 -08:00
bors 8bed48a751 Auto merge of #931 - bdrewery:posix_spawn_freebsd, r=alexcrichton
Add posix_spawn bindings for FreeBSD
2018-02-28 17:30:10 +00:00
bors 92d3739070 Auto merge of #930 - gnzlbg:fix_musl, r=alexcrichton
Fix --no-default-features builds

Closes #928 #929 #684
2018-02-28 15:45:08 +00:00
gnzlbg 78320c7c75 retry 2018-02-28 15:27:38 +01:00
gnzlbg 2938d1c4c2 fix style 2018-02-28 10:58:01 +01:00
gnzlbg 5c95d8d03b wrap target_vendor with stdbuild 2018-02-28 08:34:12 +01:00
gnzlbg f9c396803c perform ctest with and without std 2018-02-27 17:36:45 +01:00
gnzlbg 5b890a31bd fix ci script 2018-02-27 17:08:14 +01:00
gnzlbg 4c0b6ea61e fix style 2018-02-27 16:13:49 +01:00
gnzlbg 988843834f test --no-default-features and fix musl builds 2018-02-27 15:47:18 +01:00
bors bb2a95c9f2 Auto merge of #927 - bluejekyll:master, r=alexcrichton
Bump to 0.2.37

This includes:
- more multicast fields
- netfilter/nftables fields
2018-02-27 09:36:10 +00:00
Benjamin Fry 5a50bec431 0.2.37 for release 2018-02-26 21:23:21 -08:00
Bryan Drewery 92d50c9c79 Add posix_spawn bindings for FreeBSD 2018-02-26 16:45:41 -08:00
bors 8650afb555 Auto merge of #926 - faern:add-netfilter-fields, r=alexcrichton
Add netfilter/nftables fields

Adding a few missing `NF_` constants to more complete the story around that header. Then most importantly add a lot of `NFT_` constants needed in my nftables library. Some were added back in #911, but as the library grew I realized I needed more constants.
2018-02-26 03:28:23 +00:00
bors 42377bb76d Auto merge of #925 - bluejekyll:master, r=alexcrichton
add IPV6_MULTICAST_IF and IPV6_MULTICAST_HOPS

These were missing from the net2 crate. Adding them here so that the higher functions can be added to net2 later. They are necessary for declaring the interface for ipv6 multicast packets (route), and limits on the number of hops an ipv6 packet can travel

Linux reference: https://github.com/torvalds/linux/blob/master/include/uapi/linux/in6.h#L168-L170
macOS reference: https://github.com/apple/darwin-xnu/blob/master/bsd/netinet6/in6.h#L538-L540
2018-02-26 03:07:07 +00:00
Benjamin Fry 0e421c9611 add IPV6_UNICAST_HOPS 2018-02-25 15:23:46 -08:00
Linus Färnstrand b89d662117 Add missing NFT_ constants from nf_tables.h 2018-02-25 22:45:43 +01:00
Linus Färnstrand 750fcf5c5a Add missing netfilter constants
Was able to move some of them up one level so they are valid on more
platforms with less duplication
2018-02-25 22:45:43 +01:00