Skip to content

Commit 71c4c67

Browse files
committed
Update rust to version 1.38.0.
Pkgsrc changes: * Adapt to the move of the implementation of random numbers. * Remove patch which is no longer relevant (Signals.inc) * Cross-build currently fails due to the still unresolved rust-lang/rust#62558, so bootstrap kits for 1.38.0 have to be built natively, and will follow shortly. * Bump bootstrap requirements to 1.37.0 except for armv7-unknown-netbsd-eabihf which I've neither managed to cross-build nor build natively. Upstream changes: Version 1.38.0 (2019-09-26) ========================== Language -------- - [The `#[global_allocator]` attribute can now be used in submodules.][62735] - [The `#[deprecated]` attribute can now be used on macros.][62042] Compiler -------- - [Added pipelined compilation support to `rustc`.][62766] This will improve compilation times in some cases. For further information please refer to the [_"Evaluating pipelined rustc compilation"_][pipeline-internals] thread. - [Added tier 3\* support for the `aarch64-uwp-windows-msvc`, `i686-uwp-windows-gnu`, `i686-uwp-windows-msvc`, `x86_64-uwp-windows-gnu`, and `x86_64-uwp-windows-msvc` targets.][60260] - [Added tier 3 support for the `armv7-unknown-linux-gnueabi` and `armv7-unknown-linux-musleabi` targets.][63107] - [Added tier 3 support for the `hexagon-unknown-linux-musl` target.][62814] - [Added tier 3 support for the `riscv32i-unknown-none-elf` target.][62784] \* Refer to Rust's [platform support page][forge-platform-support] for more information on Rust's tiered platform support. Libraries --------- - [`ascii::EscapeDefault` now implements `Clone` and `Display`.][63421] - [Derive macros for prelude traits (e.g. `Clone`, `Debug`, `Hash`) are now available at the same path as the trait.][63056] (e.g. The `Clone` derive macro is available at `std::clone::Clone`). This also makes all built-in macros available in `std`/`core` root. e.g. `std::include_bytes!`. - [`str::Chars` now implements `Debug`.][63000] - [`slice::{concat, connect, join}` now accepts `&[T]` in addition to `&T`.][62528] - [`*const T` and `*mut T` now implement `marker::Unpin`.][62583] - [`Arc<[T]>` and `Rc<[T]>` now implement `FromIterator<T>`.][61953] - [Added euclidean remainder and division operations (`div_euclid`, `rem_euclid`) to all numeric primitives.][61884] Additionally `checked`, `overflowing`, and `wrapping` versions are available for all integer primitives. - [`thread::AccessError` now implements `Clone`, `Copy`, `Eq`, `Error`, and `PartialEq`.][61491] - [`iter::{StepBy, Peekable, Take}` now implement `DoubleEndedIterator`.][61457] Stabilized APIs --------------- - [`<*const T>::cast`] - [`<*mut T>::cast`] - [`Duration::as_secs_f32`] - [`Duration::as_secs_f64`] - [`Duration::div_duration_f32`] - [`Duration::div_duration_f64`] - [`Duration::div_f32`] - [`Duration::div_f64`] - [`Duration::from_secs_f32`] - [`Duration::from_secs_f64`] - [`Duration::mul_f32`] - [`Duration::mul_f64`] - [`any::type_name`] Cargo ----- - [Added pipelined compilation support to `cargo`.][cargo/7143] - [You can now pass the `--features` option multiple times to enable multiple features.][cargo/7084] Misc ---- - [`rustc` will now warn about some incorrect uses of `mem::{uninitialized, zeroed}` that are known to cause undefined behaviour.][63346] Compatibility Notes ------------------- - Unfortunately the [`x86_64-unknown-uefi` platform can not be built][62785] with rustc 1.39.0. - The [`armv7-unknown-linux-gnueabihf` platform is also known to have issues][62896] for certain crates such as libc. [60260]: rust-lang/rust#60260 [61457]: rust-lang/rust#61457 [61491]: rust-lang/rust#61491 [61884]: rust-lang/rust#61884 [61953]: rust-lang/rust#61953 [62042]: rust-lang/rust#62042 [62528]: rust-lang/rust#62528 [62583]: rust-lang/rust#62583 [62735]: rust-lang/rust#62735 [62766]: rust-lang/rust#62766 [62784]: rust-lang/rust#62784 [62785]: rust-lang/rust#62785 [62814]: rust-lang/rust#62814 [62896]: rust-lang/rust#62896 [63000]: rust-lang/rust#63000 [63056]: rust-lang/rust#63056 [63107]: rust-lang/rust#63107 [63346]: rust-lang/rust#63346 [63421]: rust-lang/rust#63421 [cargo/7084]: rust-lang/cargo#7084 [cargo/7143]: rust-lang/cargo#7143 [`<*const T>::cast`]: https://doc.rust-lang.org/std/primitive.pointer.html#method.cast [`<*mut T>::cast`]: https://doc.rust-lang.org/std/primitive.pointer.html#method.cast [`Duration::as_secs_f32`]: https://doc.rust-lang.org/std/time/struct.Duration.html#method.as_secs_f32 [`Duration::as_secs_f64`]: https://doc.rust-lang.org/std/time/struct.Duration.html#method.as_secs_f64 [`Duration::div_duration_f32`]: https://doc.rust-lang.org/std/time/struct.Duration.html#method.div_duration_f32 [`Duration::div_duration_f64`]: https://doc.rust-lang.org/std/time/struct.Duration.html#method.div_duration_f64 [`Duration::div_f32`]: https://doc.rust-lang.org/std/time/struct.Duration.html#method.div_f32 [`Duration::div_f64`]: https://doc.rust-lang.org/std/time/struct.Duration.html#method.div_f64 [`Duration::from_secs_f32`]: https://doc.rust-lang.org/std/time/struct.Duration.html#method.from_secs_f32 [`Duration::from_secs_f64`]: https://doc.rust-lang.org/std/time/struct.Duration.html#method.from_secs_f64 [`Duration::mul_f32`]: https://doc.rust-lang.org/std/time/struct.Duration.html#method.mul_f32 [`Duration::mul_f64`]: https://doc.rust-lang.org/std/time/struct.Duration.html#method.mul_f64 [`any::type_name`]: https://doc.rust-lang.org/std/any/fn.type_name.html [forge-platform-support]: https://forge.rust-lang.org/platform-support.html [pipeline-internals]: https://internals.rust-lang.org/t/evaluating-pipelined-rustc-compilation/10199
1 parent 86c2594 commit 71c4c67

7 files changed

+206
-113
lines changed

lang/rust/Makefile

Lines changed: 38 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
1-
# $NetBSD: Makefile,v 1.116 2019/09/18 07:25:00 adam Exp $
1+
# $NetBSD: Makefile,v 1.117 2019/10/02 12:51:43 he Exp $
22

3-
DISTNAME= rustc-1.37.0-src
3+
DISTNAME= rustc-1.38.0-src
44
PKGNAME= ${DISTNAME:S/rustc/rust/:S/-src//}
55
CATEGORIES= lang
66
MASTER_SITES= http://static.rust-lang.org/dist/
@@ -23,6 +23,7 @@ CHECK_PORTABILITY_SKIP+=vendor/openssl-src/openssl/.travis-create-release.sh
2323

2424
HAS_CONFIGURE= yes
2525
PYTHON_FOR_BUILD_ONLY= yes
26+
PYTHON_VERSIONS_ACCEPTED=27
2627
CONFIG_SHELL= ${PYTHONBIN}
2728
CONFIGURE_SCRIPT= src/bootstrap/configure.py
2829
CONFIGURE_ARGS+= --prefix=${PREFIX}
@@ -42,8 +43,8 @@ CONFIGURE_ARGS+= --disable-ninja
4243
#CONFIGURE_ARGS+= --jemalloc-root=${BUILDLINK_PREFIX.jemalloc}/lib
4344

4445
# Use "dist" build target for cross compile of bootstrap
45-
#BUILD_TARGET= dist
46-
BUILD_TARGET= build
46+
BUILD_TARGET= dist
47+
#BUILD_TARGET= build
4748

4849
# The gcc-wrap / c++-wrap script takes CROSS_ROOT environment variable
4950
# to do a cross-build. The wrapper script assumes dest/ and tools/
@@ -91,18 +92,6 @@ BUILD_TARGET= build
9192
# the bootstrap
9293
PKGSRC_MAKE_ENV+= LD_LIBRARY_PATH=${RUST_BOOTSTRAP_PATH:Q}/lib
9394

94-
.if !empty(MACHINE_PLATFORM:MNetBSD-*-powerpc)
95-
# Bootstrapping on NetBSD/powerpc requires no debug-info from rustc
96-
# (both for amd64->powerpc built and powerpc->powerpc built bootstrap bits)
97-
CONFIGURE_ARGS+= --disable-debug
98-
CONFIGURE_ARGS+= --disable-debuginfo-tests
99-
CONFIGURE_ARGS+= --disable-debug-assertions
100-
CONFIGURE_ARGS+= --disable-debuginfo
101-
CONFIGURE_ARGS+= --disable-debuginfo-lines
102-
CONFIGURE_ARGS+= --disable-debuginfo-only-std
103-
CONFIGURE_ARGS+= --disable-debuginfo-tools
104-
.endif
105-
10695
# This should allow us to perform "offline" builds (so cargo doesn't fetch
10796
# dependencies during the build stage) but this isn't hooked up yet.
10897
CONFIGURE_ARGS+= --enable-vendor
@@ -124,6 +113,27 @@ CHECK_PORTABILITY_SKIP+= src/vendor/openssl-src/openssl/.travis-create-release.s
124113

125114
.include "../../mk/bsd.prefs.mk"
126115

116+
.if !empty(MACHINE_PLATFORM:MNetBSD-*-powerpc) || \
117+
!empty(MACHINE_PLATFORM:MNetBSD-*-earmv7hf)
118+
# Bootstrapping on NetBSD/powerpc requires no debug-info from rustc
119+
# (both for amd64->powerpc built and powerpc->powerpc built bootstrap bits)
120+
CONFIGURE_ARGS+= --disable-debug
121+
CONFIGURE_ARGS+= --disable-debuginfo-tests
122+
CONFIGURE_ARGS+= --disable-debug-assertions
123+
CONFIGURE_ARGS+= --disable-debuginfo
124+
CONFIGURE_ARGS+= --disable-debuginfo-lines
125+
CONFIGURE_ARGS+= --disable-debuginfo-only-std
126+
CONFIGURE_ARGS+= --disable-debuginfo-tools
127+
.endif
128+
129+
# Only build the ARM target on/for this host, due to resource constraints
130+
# (X86 needs to go along due to 2-stage build process)
131+
.if !empty(MACHINE_PLATFORM:MNetBSD-*-earmv7hf) || \
132+
!empty(TARGET:Marmv7-unknown-netbsd-eabihf)
133+
CONFIGURE_ARGS+= --set llvm.targets="ARM;X86"
134+
.endif
135+
136+
127137
#
128138
# Under NetBSD, do not use DT_RUNPATH
129139
#
@@ -137,42 +147,42 @@ BUILDLINK_TRANSFORM.NetBSD+= rm:-Wl,--enable-new-dtags
137147
# own bootstrap. See the stage0-bootstrap below for more details.
138148
#
139149
DISTFILES:= ${DEFAULT_DISTFILES}
140-
RUST_STAGE0_VER= 1.36.0
150+
RUST_STAGE0_VER= 1.37.0
141151
#
142152
.if !empty(MACHINE_PLATFORM:MDarwin-*-i386) || make(distinfo) || make (makesum) || make(mdi)
143-
RUST_STAGE0_VER= 1.36.0
153+
RUST_STAGE0_VER= 1.37.0
144154
RUST_ARCH:= i686-apple-darwin
145155
RUST_STAGE0:= rust-${RUST_STAGE0_VER}-${RUST_ARCH}.tar.gz
146156
RUST_STD_STAGE0:= rust-std-${RUST_STAGE0_VER}-${RUST_ARCH}.tar.gz
147157
DISTFILES:= ${DISTFILES} ${RUST_STAGE0} ${RUST_STD_STAGE0}
148158
pre-build-fix:
149159
.endif
150160
.if !empty(MACHINE_PLATFORM:MDarwin-*-x86_64) || make(distinfo) || make (makesum) || make(mdi)
151-
RUST_STAGE0_VER= 1.36.0
161+
RUST_STAGE0_VER= 1.37.0
152162
RUST_ARCH:= x86_64-apple-darwin
153163
RUST_STAGE0:= rust-${RUST_STAGE0_VER}-${RUST_ARCH}.tar.gz
154164
RUST_STD_STAGE0:= rust-std-${RUST_STAGE0_VER}-${RUST_ARCH}.tar.gz
155165
DISTFILES:= ${DISTFILES} ${RUST_STAGE0} ${RUST_STD_STAGE0}
156166
pre-build-fix:
157167
.endif
158168
.if !empty(MACHINE_PLATFORM:MLinux-*-i386) || make(distinfo) || make (makesum) || make(mdi)
159-
RUST_STAGE0_VER= 1.36.0
169+
RUST_STAGE0_VER= 1.37.0
160170
RUST_ARCH:= i686-unknown-linux-gnu
161171
RUST_STAGE0:= rust-${RUST_STAGE0_VER}-${RUST_ARCH}.tar.gz
162172
RUST_STD_STAGE0:= rust-std-${RUST_STAGE0_VER}-${RUST_ARCH}.tar.gz
163173
DISTFILES:= ${DISTFILES} ${RUST_STAGE0} ${RUST_STD_STAGE0}
164174
pre-build-fix:
165175
.endif
166176
.if !empty(MACHINE_PLATFORM:MLinux-*-x86_64) || make(distinfo) || make (makesum) || make(mdi)
167-
RUST_STAGE0_VER= 1.36.0
177+
RUST_STAGE0_VER= 1.37.0
168178
RUST_ARCH:= x86_64-unknown-linux-gnu
169179
RUST_STAGE0:= rust-${RUST_STAGE0_VER}-${RUST_ARCH}.tar.gz
170180
RUST_STD_STAGE0:= rust-std-${RUST_STAGE0_VER}-${RUST_ARCH}.tar.gz
171181
DISTFILES:= ${DISTFILES} ${RUST_STAGE0} ${RUST_STD_STAGE0}
172182
pre-build-fix:
173183
.endif
174184
.if !empty(MACHINE_PLATFORM:MSunOS-*-x86_64) || make(distinfo) || make (makesum) || make(mdi)
175-
RUST_STAGE0_VER= 1.36.0
185+
RUST_STAGE0_VER= 1.37.0
176186
RUST_ARCH:= x86_64-sun-solaris
177187
RUST_STAGE0:= rust-${RUST_STAGE0_VER}-${RUST_ARCH}.tar.gz
178188
SITES.${RUST_STAGE0}= https://us-east.manta.joyent.com/pkgsrc/public/pkg-bootstraps/
@@ -181,15 +191,15 @@ RUST_BOOTSTRAP_PATH?= ${WRKDIR}/rust-${RUST_STAGE0_VER}-${RUST_ARCH}
181191
pre-build-fix:
182192
.endif
183193
.if !empty(MACHINE_PLATFORM:MFreeBSD-*-i386) || make(distinfo) || make (makesum) || make(mdi)
184-
RUST_STAGE0_VER= 1.36.0
194+
RUST_STAGE0_VER= 1.37.0
185195
RUST_ARCH:= i686-unknown-freebsd
186196
RUST_STAGE0:= rust-${RUST_STAGE0_VER}-${RUST_ARCH}.tar.gz
187197
RUST_STD_STAGE0:= rust-std-${RUST_STAGE0_VER}-${RUST_ARCH}.tar.gz
188198
DISTFILES:= ${DISTFILES} ${RUST_STAGE0} ${RUST_STD_STAGE0}
189199
pre-build-fix:
190200
.endif
191201
.if !empty(MACHINE_PLATFORM:MFreeBSD-*-x86_64) || make(distinfo) || make (makesum) || make(mdi)
192-
RUST_STAGE0_VER= 1.36.0
202+
RUST_STAGE0_VER= 1.37.0
193203
RUST_ARCH:= x86_64-unknown-freebsd
194204
RUST_STAGE0:= rust-${RUST_STAGE0_VER}-${RUST_ARCH}.tar.gz
195205
RUST_STD_STAGE0:= rust-std-${RUST_STAGE0_VER}-${RUST_ARCH}.tar.gz
@@ -294,9 +304,12 @@ post-extract:
294304
${CP} ${WRKSRC}/vendor/rand/.cargo-checksum.json \
295305
${WRKSRC}/vendor/rand/.cargo-checksum.json.orig
296306
${SED} -e 's/1e732c2e3b4bd1561f11e0979bf9d20669a96eae7afe0deff9dfbb980ee47bf1/bc03f2345d7cfa7000f9da817120b6afa073359789c21a9a790ebd8676c50cca/' ${WRKSRC}/vendor/rand/.cargo-checksum.json.orig > ${WRKSRC}/vendor/rand/.cargo-checksum.json
307+
${CP} ${WRKSRC}/vendor/rand-0.6.1/.cargo-checksum.json \
308+
${WRKSRC}/vendor/rand-0.6.1/.cargo-checksum.json.orig
309+
${SED} -e 's/1e732c2e3b4bd1561f11e0979bf9d20669a96eae7afe0deff9dfbb980ee47bf1/bc03f2345d7cfa7000f9da817120b6afa073359789c21a9a790ebd8676c50cca/' ${WRKSRC}/vendor/rand-0.6.1/.cargo-checksum.json.orig > ${WRKSRC}/vendor/rand-0.6.1/.cargo-checksum.json
297310
${CP} ${WRKSRC}/vendor/libc/.cargo-checksum.json \
298311
${WRKSRC}/vendor/libc/.cargo-checksum.json.orig
299-
${SED} -e 's/0c6d148d84f2fa9feb86b464d30af9c52322553bf321ae4fe27184d274ccbe21/27dae4ec77f317c74e2c205658bcc8220c512f751802b754b07770c16e420dd1/' ${WRKSRC}/vendor/libc/.cargo-checksum.json.orig > ${WRKSRC}/vendor/libc/.cargo-checksum.json
312+
${SED} -e 's/b715246dd48adf4794e7b6dc2ec166c80561fcae42fa100c62ffca23b624d6fc/efeeb8c29ec9b5c69e643cb9dfdb5d4760b6fc8ca6dec4c641450be95da1b7c3/' ${WRKSRC}/vendor/libc/.cargo-checksum.json.orig > ${WRKSRC}/vendor/libc/.cargo-checksum.json
300313
${CP} ${WRKSRC}/vendor/backtrace-sys/.cargo-checksum.json \
301314
${WRKSRC}/vendor/backtrace-sys/.cargo-checksum.json.orig
302315
${SED} -e 's/59763fc255248b54fba5d0761d61093a73d51fa4cb400b0df1b5f339b9c2f48a/ba66d192421fd536ceddb50616c4c4aea06f4e39450eb0bc2bbbaed0b1e684c1/' ${WRKSRC}/vendor/backtrace-sys/.cargo-checksum.json.orig > ${WRKSRC}/vendor/backtrace-sys/.cargo-checksum.json

0 commit comments

Comments
 (0)