diff options
author | bdrewery <bdrewery@FreeBSD.org> | 2018-03-09 10:54:10 +0800 |
---|---|---|
committer | bdrewery <bdrewery@FreeBSD.org> | 2018-03-09 10:54:10 +0800 |
commit | d31d1487723d251a6dbb10f1bef2e1a2ff8f7e27 (patch) | |
tree | e9c8f09fd599a209e66c3733df1f5aed45035d5a /lang | |
parent | 733c4c43ae4563155b46dc61393f37f97523a25b (diff) | |
download | freebsd-ports-gnome-d31d1487723d251a6dbb10f1bef2e1a2ff8f7e27.tar.gz freebsd-ports-gnome-d31d1487723d251a6dbb10f1bef2e1a2ff8f7e27.tar.zst freebsd-ports-gnome-d31d1487723d251a6dbb10f1bef2e1a2ff8f7e27.zip |
- Fix kevent on head by binding to the old ABI symbol version.
- Add some context in the patches for where they came from. They need to be
in 1 patch due to needing to use the .orig file for fixing up checksums.
Obtained from: rust upstream
Diffstat (limited to 'lang')
-rw-r--r-- | lang/rust-nightly/files/extra-patch-abi (renamed from lang/rust-nightly/files/extra-patch-ino64) | 38 | ||||
-rw-r--r-- | lang/rust/Makefile | 3 | ||||
-rw-r--r-- | lang/rust/files/extra-patch-abi (renamed from lang/rust/files/extra-patch-ino64) | 38 |
3 files changed, 78 insertions, 1 deletions
diff --git a/lang/rust-nightly/files/extra-patch-ino64 b/lang/rust-nightly/files/extra-patch-abi index 1c2bcfb6de34..e4fdca6a93d4 100644 --- a/lang/rust-nightly/files/extra-patch-ino64 +++ b/lang/rust-nightly/files/extra-patch-abi @@ -1,3 +1,25 @@ +------------------------------------------------------------------------ +r441843 | kib | 2017-05-27 05:06:40 -0700 (Sat, 27 May 2017) | 6 lines + +Fix lang/rust after ino64 src commit. + +Approved by: bapt, dumbbell +Sponsored by: The FreeBSD Foundation +Differential revision: https://reviews.freebsd.org/D10799 + +------------------------------------------------------------------------ + +commit 969ad2b73cdc928b88f6db8f31916bbe294764c0 +Author: Bryan Drewery <bryan@shatow.net> +Date: Thu Mar 1 12:35:01 2018 -0800 + + 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. + --- ./src/liblibc/src/unix/bsd/freebsdlike/freebsd/aarch64.rs.orig 2017-04-24 18:56:45.000000000 +0000 +++ ./src/liblibc/src/unix/bsd/freebsdlike/freebsd/aarch64.rs 2017-05-30 07:55:40.703709000 +0000 @@ -7,10 +7,12 @@ @@ -142,6 +164,14 @@ pub type mode_t = u16; pub type pthread_attr_t = *mut ::c_void; pub type rlim_t = i64; +@@ -1052,6 +1052,7 @@ extern { + serv: *mut ::c_char, + servlen: ::size_t, + flags: ::c_int) -> ::c_int; ++ #[cfg_attr(target_os = "freebsd", link_name = "kevent@FBSD_1.0")] + pub fn kevent(kq: ::c_int, + changelist: *const ::kevent, + nchanges: ::c_int, --- ./src/libstd/os/freebsd/raw.rs.orig 2017-04-24 18:53:46.000000000 +0000 +++ ./src/libstd/os/freebsd/raw.rs 2017-05-25 16:25:42.304715000 +0000 @@ -38,32 +38,52 @@ @@ -383,3 +413,11 @@ pub type mode_t = u16; pub type pthread_attr_t = *mut ::c_void; pub type rlim_t = i64; +@@ -1052,6 +1052,7 @@ extern { + serv: *mut ::c_char, + servlen: ::size_t, + flags: ::c_int) -> ::c_int; ++ #[cfg_attr(target_os = "freebsd", link_name = "kevent@FBSD_1.0")] + pub fn kevent(kq: ::c_int, + changelist: *const ::kevent, + nchanges: ::c_int, diff --git a/lang/rust/Makefile b/lang/rust/Makefile index dddad626f9c6..6928ac63f913 100644 --- a/lang/rust/Makefile +++ b/lang/rust/Makefile @@ -3,6 +3,7 @@ PORTNAME= rust PORTVERSION?= 1.24.0 +PORTREVISION?= 1 CATEGORIES= lang MASTER_SITES= http://static.rust-lang.org/dist/:src \ LOCAL/dumbbell/rust:rust_bootstrap \ @@ -92,7 +93,7 @@ PLIST_FILES= lib/rustlib/components \ .include <bsd.port.pre.mk> .if ${OPSYS} == FreeBSD && ${OSVERSION} >= 1200031 -EXTRA_PATCHES+= ${PATCHDIR}/extra-patch-ino64 +EXTRA_PATCHES+= ${PATCHDIR}/extra-patch-abi .endif X_PY_ENV= HOME="${WRKDIR}" \ diff --git a/lang/rust/files/extra-patch-ino64 b/lang/rust/files/extra-patch-abi index 1c2bcfb6de34..e4fdca6a93d4 100644 --- a/lang/rust/files/extra-patch-ino64 +++ b/lang/rust/files/extra-patch-abi @@ -1,3 +1,25 @@ +------------------------------------------------------------------------ +r441843 | kib | 2017-05-27 05:06:40 -0700 (Sat, 27 May 2017) | 6 lines + +Fix lang/rust after ino64 src commit. + +Approved by: bapt, dumbbell +Sponsored by: The FreeBSD Foundation +Differential revision: https://reviews.freebsd.org/D10799 + +------------------------------------------------------------------------ + +commit 969ad2b73cdc928b88f6db8f31916bbe294764c0 +Author: Bryan Drewery <bryan@shatow.net> +Date: Thu Mar 1 12:35:01 2018 -0800 + + 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. + --- ./src/liblibc/src/unix/bsd/freebsdlike/freebsd/aarch64.rs.orig 2017-04-24 18:56:45.000000000 +0000 +++ ./src/liblibc/src/unix/bsd/freebsdlike/freebsd/aarch64.rs 2017-05-30 07:55:40.703709000 +0000 @@ -7,10 +7,12 @@ @@ -142,6 +164,14 @@ pub type mode_t = u16; pub type pthread_attr_t = *mut ::c_void; pub type rlim_t = i64; +@@ -1052,6 +1052,7 @@ extern { + serv: *mut ::c_char, + servlen: ::size_t, + flags: ::c_int) -> ::c_int; ++ #[cfg_attr(target_os = "freebsd", link_name = "kevent@FBSD_1.0")] + pub fn kevent(kq: ::c_int, + changelist: *const ::kevent, + nchanges: ::c_int, --- ./src/libstd/os/freebsd/raw.rs.orig 2017-04-24 18:53:46.000000000 +0000 +++ ./src/libstd/os/freebsd/raw.rs 2017-05-25 16:25:42.304715000 +0000 @@ -38,32 +38,52 @@ @@ -383,3 +413,11 @@ pub type mode_t = u16; pub type pthread_attr_t = *mut ::c_void; pub type rlim_t = i64; +@@ -1052,6 +1052,7 @@ extern { + serv: *mut ::c_char, + servlen: ::size_t, + flags: ::c_int) -> ::c_int; ++ #[cfg_attr(target_os = "freebsd", link_name = "kevent@FBSD_1.0")] + pub fn kevent(kq: ::c_int, + changelist: *const ::kevent, + nchanges: ::c_int, |