rust: Upgrade to version 1.75.0. Pkgsrc changes: * Adjust patches and cargo checksums to new versions. * For an external LLVM, set dependency of llvm >= 16, in accordance with the upstream changes. * Mark that on NetBSD we now need >= 9.0, so 8.x is no longer supported. * On NetBSD/sparc64 10.x, we now need GCC 12 to build the embedded LLVM, which is version 17; apparently GCC 10.4 or 10.5 mis-compiles it, resulting in an illegal instruction fault during the build. Ref. https://github.com/rust-lang/rust/issues/117231 Upstream changes: Version 1.75.0 (2023-12-28) ========================== - [Stabilize `async fn` and return-position `impl Trait` in traits.] (https://github.com/rust-lang/rust/pull/115822/) - [Allow function pointer signatures containing `&mut T` in `const` contexts.] (https://github.com/rust-lang/rust/pull/116015/) - [Match `usize`/`isize` exhaustively with half-open ranges.] (https://github.com/rust-lang/rust/pull/116692/) - [Guarantee that `char` has the same size and alignment as `u32`.] (https://github.com/rust-lang/rust/pull/116894/) - [Document that the null pointer has the 0 address.] (https://github.com/rust-lang/rust/pull/116988/) - [Allow partially moved values in `match`.] (https://github.com/rust-lang/rust/pull/103208/) - [Add notes about non-compliant FP behavior on 32bit x86 targets.] (https://github.com/rust-lang/rust/pull/113053/) - [Stabilize ratified RISC-V target features.] (https://github.com/rust-lang/rust/pull/116485/) Compiler -------- - [Rework negative coherence to properly consider impls that only partly overlap.] (https://github.com/rust-lang/rust/pull/112875/) - [Bump `COINDUCTIVE_OVERLAP_IN_COHERENCE` to deny, and warn in dependencies.] (https://github.com/rust-lang/rust/pull/116493/) - [Consider alias bounds when computing liveness in NLL.] (https://github.com/rust-lang/rust/pull/116733/) - [Add the V (vector) extension to the `riscv64-linux-android` target spec.] (https://github.com/rust-lang/rust/pull/116618/) - [Automatically enable cross-crate inlining for small functions] (https://github.com/rust-lang/rust/pull/116505) - Add several new tier 3 targets: - [`csky-unknown-linux-gnuabiv2hf`] (https://github.com/rust-lang/rust/pull/117049/) - [`i586-unknown-netbsd`] (https://github.com/rust-lang/rust/pull/117170/) - [`mipsel-unknown-netbsd`] (https://github.com/rust-lang/rust/pull/117356/) Refer to Rust's [platform support page][platform-support-doc] for more information on Rust's tiered platform support. Libraries --------- - [Override `Waker::clone_from` to avoid cloning `Waker`s unnecessarily.] (https://github.com/rust-lang/rust/pull/96979/) - [Implement `BufRead` for `VecDeque<u8>`.] (https://github.com/rust-lang/rust/pull/110604/) - [Implement `FusedIterator` for `DecodeUtf16` when the inner iterator does.] (https://github.com/rust-lang/rust/pull/110729/) - [Implement `Not, Bit{And,Or}{,Assign}` for IP addresses.] (https://github.com/rust-lang/rust/pull/113747/) - [Implement `Default` for `ExitCode`.] (https://github.com/rust-lang/rust/pull/114589/) - [Guarantee representation of None in NPO] (https://github.com/rust-lang/rust/pull/115333/) - [Document when atomic loads are guaranteed read-only.] (https://github.com/rust-lang/rust/pull/115577/) - [Broaden the consequences of recursive TLS initialization.] (https://github.com/rust-lang/rust/pull/116172/) - [Windows: Support sub-millisecond sleep.] (https://github.com/rust-lang/rust/pull/116461/) - [Fix generic bound of `str::SplitInclusive`'s `DoubleEndedIterator` impl] (https://github.com/rust-lang/rust/pull/100806/) - [Fix exit status / wait status on non-Unix `cfg(unix)` platforms.] (https://github.com/rust-lang/rust/pull/115108/) Stabilized APIs --------------- - [`Atomic*::from_ptr`] (https://doc.rust-lang.org/stable/core/sync/atomic/struct.AtomicUsize.html#method.from_ptr) - [`FileTimes`] (https://doc.rust-lang.org/stable/std/fs/struct.FileTimes.html) - [`FileTimesExt`] (https://doc.rust-lang.org/stable/std/os/windows/fs/trait.FileTimesExt.html) - [`File::set_modified`] (https://doc.rust-lang.org/stable/std/fs/struct.File.html#method.set_modified) - [`File::set_times`] (https://doc.rust-lang.org/stable/std/fs/struct.File.html#method.set_times) - [`IpAddr::to_canonical`] (https://doc.rust-lang.org/stable/core/net/enum.IpAddr.html#method.to_canonical) - [`Ipv6Addr::to_canonical`] (https://doc.rust-lang.org/stable/core/net/struct.Ipv6Addr.html#method.to_canonical) - [`Option::as_slice`] (https://doc.rust-lang.org/stable/core/option/enum.Option.html#method.as_slice) - [`Option::as_mut_slice`] (https://doc.rust-lang.org/stable/core/option/enum.Option.html#method.as_mut_slice) - [`pointer::byte_add`] (https://doc.rust-lang.org/stable/core/primitive.pointer.html#method.byte_add) - [`pointer::byte_offset`] (https://doc.rust-lang.org/stable/core/primitive.pointer.html#method.byte_offset) - [`pointer::byte_offset_from`] (https://doc.rust-lang.org/stable/core/primitive.pointer.html#method.byte_offset_from) - [`pointer::byte_sub`] (https://doc.rust-lang.org/stable/core/primitive.pointer.html#method.byte_sub) - [`pointer::wrapping_byte_add`] (https://doc.rust-lang.org/stable/core/primitive.pointer.html#method.wrapping_byte_add) - [`pointer::wrapping_byte_offset`] (https://doc.rust-lang.org/stable/core/primitive.pointer.html#method.wrapping_byte_offset) - [`pointer::wrapping_byte_sub`] (https://doc.rust-lang.org/stable/core/primitive.pointer.html#method.wrapping_byte_sub) These APIs are now stable in const contexts: - [`Ipv6Addr::to_ipv4_mapped`] (https://doc.rust-lang.org/stable/core/net/struct.Ipv6Addr.html#method.to_ipv4_mapped) - [`MaybeUninit::assume_init_read`] (https://doc.rust-lang.org/stable/core/mem/union.MaybeUninit.html#method.assume_init_read) - [`MaybeUninit::zeroed`] (https://doc.rust-lang.org/stable/core/mem/union.MaybeUninit.html#method.zeroed) - [`mem::discriminant`] (https://doc.rust-lang.org/stable/core/mem/fn.discriminant.html) - [`mem::zeroed`] (https://doc.rust-lang.org/stable/core/mem/fn.zeroed.html) Cargo ----- - [Add new packages to `[workspace.members]` automatically.] (https://github.com/rust-lang/cargo/pull/12779/) - [Allow version-less `Cargo.toml` manifests.] (https://github.com/rust-lang/cargo/pull/12786/) - [Make browser links out of HTML file paths.] (https://github.com/rust-lang/cargo/pull/12889) Rustdoc ------- - [Accept less invalid Rust in rustdoc.] (https://github.com/rust-lang/rust/pull/117450/) - [Document lack of object safety on affected traits.] (https://github.com/rust-lang/rust/pull/113241/) - [Hide `#[repr(transparent)]` if it isn't part of the public ABI.] (https://github.com/rust-lang/rust/pull/115439/) - [Show enum discriminant if it is a C-like variant.] (https://github.com/rust-lang/rust/pull/116142/) Compatibility Notes ------------------- - [FreeBSD targets now require at least version 12.] (https://github.com/rust-lang/rust/pull/114521/) - [Formally demote tier 2 MIPS targets to tier 3.] (https://github.com/rust-lang/rust/pull/115238/) - [Make misalignment a hard error in `const` contexts.] (https://github.com/rust-lang/rust/pull/115524/) - [Fix detecting references to packed unsized fields.] (https://github.com/rust-lang/rust/pull/115583/) - [Remove support for compiler plugins.] (https://github.com/rust-lang/rust/pull/116412/)diff -r1.302 -r1.303 pkgsrc/lang/rust/Makefile
(he)
@@ -1,33 +1,31 @@ | @@ -1,33 +1,31 @@ | |||
1 | # $NetBSD: Makefile,v 1.302 2024/01/15 15:15:01 jperkin Exp $ | 1 | # $NetBSD: Makefile,v 1.303 2024/03/03 14:53:32 he Exp $ | |
2 | 2 | |||
3 | DISTNAME= rustc-1.74.1-src | 3 | DISTNAME= rustc-1.75.0-src | |
4 | PKGNAME= ${DISTNAME:S/rustc/rust/:S/-src//} | 4 | PKGNAME= ${DISTNAME:S/rustc/rust/:S/-src//} | |
5 | CATEGORIES= lang | 5 | CATEGORIES= lang | |
6 | PKGREVISION= 1 | |||
7 | MASTER_SITES= https://static.rust-lang.org/dist/ | 6 | MASTER_SITES= https://static.rust-lang.org/dist/ | |
8 | 7 | |||
9 | MAINTAINER= pkgsrc-users@NetBSD.org | 8 | MAINTAINER= pkgsrc-users@NetBSD.org | |
10 | HOMEPAGE= https://www.rust-lang.org/ | 9 | HOMEPAGE= https://www.rust-lang.org/ | |
11 | COMMENT= Safe, concurrent, practical language | 10 | COMMENT= Safe, concurrent, practical language | |
12 | LICENSE= mit OR apache-2.0 | 11 | LICENSE= mit OR apache-2.0 | |
13 | 12 | |||
14 | CONFLICTS+= rust-bin-[0-9]* | 13 | CONFLICTS+= rust-bin-[0-9]* | |
15 | 14 | |||
16 | # LLVM uses -std=c++17 | 15 | # LLVM uses -std=c++17 | |
17 | USE_CXX_FEATURES+= c++17 | 16 | USE_CXX_FEATURES+= c++17 | |
18 | ||||
19 | USE_GCC_RUNTIME= yes | 17 | USE_GCC_RUNTIME= yes | |
20 | USE_LANGUAGES= c c++17 | 18 | USE_LANGUAGES= c c++ | |
21 | USE_LIBTOOL= yes | 19 | USE_LIBTOOL= yes | |
22 | USE_TOOLS+= bash grep gmake perl:build pkg-config | 20 | USE_TOOLS+= bash grep gmake perl:build pkg-config | |
23 | 21 | |||
24 | # The NetBSD bootstraps are built for NetBSD 8 (because rust doesn't | 22 | # The NetBSD bootstraps are built for NetBSD 8 (because rust doesn't | |
25 | # build on 7). Mark earlier versions as broken. | 23 | # build on 7). Mark earlier versions as broken. | |
26 | BROKEN_ON_PLATFORM+= NetBSD-[1-7].*-* | 24 | BROKEN_ON_PLATFORM+= NetBSD-[1-7].*-* | |
27 | # Bootstrap is built for NetBSD 9.x on these platforms: | 25 | # Bootstrap is built for NetBSD 9.x on these platforms: | |
28 | BROKEN_ON_PLATFORM+= NetBSD-8.*-*arm* | 26 | BROKEN_ON_PLATFORM+= NetBSD-8.*-*arm* | |
29 | BROKEN_ON_PLATFORM+= NetBSD-8.*-aarch64 | 27 | BROKEN_ON_PLATFORM+= NetBSD-8.*-aarch64 | |
30 | BROKEN_ON_PLATFORM+= NetBSD-8.*-sparc64 | 28 | BROKEN_ON_PLATFORM+= NetBSD-8.*-sparc64 | |
31 | BROKEN_ON_PLATFORM+= NetBSD-8.*-powerpc | 29 | BROKEN_ON_PLATFORM+= NetBSD-8.*-powerpc | |
32 | BROKEN_ON_PLATFORM+= NetBSD-8.*-i386 | 30 | BROKEN_ON_PLATFORM+= NetBSD-8.*-i386 | |
33 | 31 | |||
@@ -211,264 +209,255 @@ BUILDLINK_TRANSFORM.NetBSD+= rm:-Wl,--en | @@ -211,264 +209,255 @@ BUILDLINK_TRANSFORM.NetBSD+= rm:-Wl,--en | |||
211 | .if ${MACHINE_PLATFORM:MDarwin-*-aarch64} | 209 | .if ${MACHINE_PLATFORM:MDarwin-*-aarch64} | |
212 | BUILDLINK_TRANSFORM+= opt:x86_64:arm64 | 210 | BUILDLINK_TRANSFORM+= opt:x86_64:arm64 | |
213 | .endif | 211 | .endif | |
214 | 212 | |||
215 | # | 213 | # | |
216 | # Rust unfortunately requires itself to build. On platforms which aren't | 214 | # Rust unfortunately requires itself to build. On platforms which aren't | |
217 | # supported by upstream (where they offer binary bootstraps), or where we do | 215 | # supported by upstream (where they offer binary bootstraps), or where we do | |
218 | # not trust random binaries from the Internet, we need to build and provide our | 216 | # not trust random binaries from the Internet, we need to build and provide our | |
219 | # own bootstrap. See the stage0-bootstrap below for more details. | 217 | # own bootstrap. See the stage0-bootstrap below for more details. | |
220 | # | 218 | # | |
221 | DISTFILES:= ${DEFAULT_DISTFILES} | 219 | DISTFILES:= ${DEFAULT_DISTFILES} | |
222 | 220 | |||
223 | .if ${MACHINE_PLATFORM:MDarwin-*-aarch64} || make(distinfo) || make (makesum) || make(mdi) | 221 | .if ${MACHINE_PLATFORM:MDarwin-*-aarch64} || make(distinfo) || make (makesum) || make(mdi) | |
224 | RUST_STAGE0_VER= 1.73.0 | 222 | RUST_STAGE0_VER= 1.74.1 | |
225 | RUST_ARCH:= aarch64-apple-darwin | 223 | RUST_ARCH:= aarch64-apple-darwin | |
226 | RUST_STAGE0:= rust-${RUST_STAGE0_VER}-${RUST_ARCH}.tar.gz | 224 | RUST_STAGE0:= rust-${RUST_STAGE0_VER}-${RUST_ARCH}.tar.gz | |
227 | RUST_STD_STAGE0:= rust-std-${RUST_STAGE0_VER}-${RUST_ARCH}.tar.gz | 225 | RUST_STD_STAGE0:= rust-std-${RUST_STAGE0_VER}-${RUST_ARCH}.tar.gz | |
228 | DISTFILES:= ${DISTFILES} ${RUST_STAGE0} ${RUST_STD_STAGE0} | 226 | DISTFILES:= ${DISTFILES} ${RUST_STAGE0} ${RUST_STD_STAGE0} | |
229 | .endif | 227 | .endif | |
230 | .if ${MACHINE_PLATFORM:MDarwin-*-x86_64} || make(distinfo) || make (makesum) || make(mdi) | 228 | .if ${MACHINE_PLATFORM:MDarwin-*-x86_64} || make(distinfo) || make (makesum) || make(mdi) | |
231 | RUST_STAGE0_VER= 1.73.0 | 229 | RUST_STAGE0_VER= 1.74.1 | |
232 | RUST_ARCH:= x86_64-apple-darwin | 230 | RUST_ARCH:= x86_64-apple-darwin | |
233 | RUST_STAGE0:= rust-${RUST_STAGE0_VER}-${RUST_ARCH}.tar.gz | 231 | RUST_STAGE0:= rust-${RUST_STAGE0_VER}-${RUST_ARCH}.tar.gz | |
234 | RUST_STD_STAGE0:= rust-std-${RUST_STAGE0_VER}-${RUST_ARCH}.tar.gz | 232 | RUST_STD_STAGE0:= rust-std-${RUST_STAGE0_VER}-${RUST_ARCH}.tar.gz | |
235 | DISTFILES:= ${DISTFILES} ${RUST_STAGE0} ${RUST_STD_STAGE0} | 233 | DISTFILES:= ${DISTFILES} ${RUST_STAGE0} ${RUST_STD_STAGE0} | |
236 | .endif | 234 | .endif | |
237 | .if ${MACHINE_PLATFORM:MLinux-*-aarch64} || make(distinfo) || make (makesum) || make(mdi) | 235 | .if ${MACHINE_PLATFORM:MLinux-*-aarch64} || make(distinfo) || make (makesum) || make(mdi) | |
238 | RUST_STAGE0_VER= 1.73.0 | 236 | RUST_STAGE0_VER= 1.74.1 | |
239 | RUST_ARCH:= aarch64-unknown-linux-gnu | 237 | RUST_ARCH:= aarch64-unknown-linux-gnu | |
240 | RUST_STAGE0:= rust-${RUST_STAGE0_VER}-${RUST_ARCH}.tar.gz | 238 | RUST_STAGE0:= rust-${RUST_STAGE0_VER}-${RUST_ARCH}.tar.gz | |
241 | RUST_STD_STAGE0:= rust-std-${RUST_STAGE0_VER}-${RUST_ARCH}.tar.gz | 239 | RUST_STD_STAGE0:= rust-std-${RUST_STAGE0_VER}-${RUST_ARCH}.tar.gz | |
242 | DISTFILES:= ${DISTFILES} ${RUST_STAGE0} ${RUST_STD_STAGE0} | 240 | DISTFILES:= ${DISTFILES} ${RUST_STAGE0} ${RUST_STD_STAGE0} | |
243 | .endif | 241 | .endif | |
244 | .if ${MACHINE_PLATFORM:MLinux-*-earmv6hf} || make(distinfo) || make (makesum) || make(mdi) | 242 | .if ${MACHINE_PLATFORM:MLinux-*-earmv6hf} || make(distinfo) || make (makesum) || make(mdi) | |
245 | RUST_STAGE0_VER= 1.73.0 | 243 | RUST_STAGE0_VER= 1.74.1 | |
246 | RUST_ARCH:= arm-unknown-linux-gnueabihf | 244 | RUST_ARCH:= arm-unknown-linux-gnueabihf | |
247 | RUST_STAGE0:= rust-${RUST_STAGE0_VER}-${RUST_ARCH}.tar.gz | 245 | RUST_STAGE0:= rust-${RUST_STAGE0_VER}-${RUST_ARCH}.tar.gz | |
248 | RUST_STD_STAGE0:= rust-std-${RUST_STAGE0_VER}-${RUST_ARCH}.tar.gz | 246 | RUST_STD_STAGE0:= rust-std-${RUST_STAGE0_VER}-${RUST_ARCH}.tar.gz | |
249 | DISTFILES:= ${DISTFILES} ${RUST_STAGE0} ${RUST_STD_STAGE0} | 247 | DISTFILES:= ${DISTFILES} ${RUST_STAGE0} ${RUST_STD_STAGE0} | |
250 | .endif | 248 | .endif | |
251 | .if ${MACHINE_PLATFORM:MLinux-*-earmv7hf} || make(distinfo) || make (makesum) || make(mdi) | 249 | .if ${MACHINE_PLATFORM:MLinux-*-earmv7hf} || make(distinfo) || make (makesum) || make(mdi) | |
252 | RUST_STAGE0_VER= 1.73.0 | 250 | RUST_STAGE0_VER= 1.74.1 | |
253 | RUST_ARCH:= armv7-unknown-linux-gnueabihf | 251 | RUST_ARCH:= armv7-unknown-linux-gnueabihf | |
254 | RUST_STAGE0:= rust-${RUST_STAGE0_VER}-${RUST_ARCH}.tar.gz | 252 | RUST_STAGE0:= rust-${RUST_STAGE0_VER}-${RUST_ARCH}.tar.gz | |
255 | RUST_STD_STAGE0:= rust-std-${RUST_STAGE0_VER}-${RUST_ARCH}.tar.gz | 253 | RUST_STD_STAGE0:= rust-std-${RUST_STAGE0_VER}-${RUST_ARCH}.tar.gz | |
256 | DISTFILES:= ${DISTFILES} ${RUST_STAGE0} ${RUST_STD_STAGE0} | 254 | DISTFILES:= ${DISTFILES} ${RUST_STAGE0} ${RUST_STD_STAGE0} | |
257 | .endif | 255 | .endif | |
258 | .if ${MACHINE_PLATFORM:MLinux-*-i386} || make(distinfo) || make (makesum) || make(mdi) | 256 | .if ${MACHINE_PLATFORM:MLinux-*-i386} || make(distinfo) || make (makesum) || make(mdi) | |
259 | RUST_STAGE0_VER= 1.73.0 | 257 | RUST_STAGE0_VER= 1.74.1 | |
260 | RUST_ARCH:= i686-unknown-linux-gnu | 258 | RUST_ARCH:= i686-unknown-linux-gnu | |
261 | RUST_STAGE0:= rust-${RUST_STAGE0_VER}-${RUST_ARCH}.tar.gz | 259 | RUST_STAGE0:= rust-${RUST_STAGE0_VER}-${RUST_ARCH}.tar.gz | |
262 | RUST_STD_STAGE0:= rust-std-${RUST_STAGE0_VER}-${RUST_ARCH}.tar.gz | 260 | RUST_STD_STAGE0:= rust-std-${RUST_STAGE0_VER}-${RUST_ARCH}.tar.gz | |
263 | DISTFILES:= ${DISTFILES} ${RUST_STAGE0} ${RUST_STD_STAGE0} | 261 | DISTFILES:= ${DISTFILES} ${RUST_STAGE0} ${RUST_STD_STAGE0} | |
264 | .endif | 262 | .endif | |
265 | .if ${MACHINE_PLATFORM:MLinux-*-x86_64} || make(distinfo) || make (makesum) || make(mdi) | 263 | .if ${MACHINE_PLATFORM:MLinux-*-x86_64} || make(distinfo) || make (makesum) || make(mdi) | |
266 | RUST_STAGE0_VER= 1.73.0 | 264 | RUST_STAGE0_VER= 1.74.1 | |
267 | RUST_ARCH:= x86_64-unknown-linux-gnu | 265 | RUST_ARCH:= x86_64-unknown-linux-gnu | |
268 | RUST_STAGE0:= rust-${RUST_STAGE0_VER}-${RUST_ARCH}.tar.gz | 266 | RUST_STAGE0:= rust-${RUST_STAGE0_VER}-${RUST_ARCH}.tar.gz | |
269 | RUST_STD_STAGE0:= rust-std-${RUST_STAGE0_VER}-${RUST_ARCH}.tar.gz | 267 | RUST_STD_STAGE0:= rust-std-${RUST_STAGE0_VER}-${RUST_ARCH}.tar.gz | |
270 | DISTFILES:= ${DISTFILES} ${RUST_STAGE0} ${RUST_STD_STAGE0} | 268 | DISTFILES:= ${DISTFILES} ${RUST_STAGE0} ${RUST_STD_STAGE0} | |
271 | .endif | 269 | .endif | |
272 | # | 270 | # | |
273 | # The SunOS target defaults to illumos as that's what the current bootstraps | 271 | # The SunOS target defaults to illumos as that's what the current bootstraps | |
274 | # are built on. If you wish to target Oracle Solaris you'll need to create an | 272 | # are built on. If you wish to target Oracle Solaris you'll need to create an | |
275 | # x86_64-sun-solaris bootstrap and comment out the overrides. | 273 | # x86_64-sun-solaris bootstrap and comment out the overrides. | |
276 | # | 274 | # | |
277 | .if ${MACHINE_PLATFORM:MSunOS-*-x86_64} || make(distinfo) || make (makesum) || make(mdi) | 275 | .if ${MACHINE_PLATFORM:MSunOS-*-x86_64} || make(distinfo) || make (makesum) || make(mdi) | |
278 | RUST_STAGE0_VER= 1.73.0 | 276 | RUST_STAGE0_VER= 1.74.1 | |
279 | RUST_ARCH:= x86_64-unknown-illumos | 277 | RUST_ARCH:= x86_64-unknown-illumos | |
280 | RUST_STAGE0:= rust-${RUST_STAGE0_VER}-${RUST_ARCH}.tar.gz | 278 | RUST_STAGE0:= rust-${RUST_STAGE0_VER}-${RUST_ARCH}.tar.gz | |
281 | SITES.${RUST_STAGE0}= https://us-central.manta.mnx.io/pkgsrc/public/pkg-bootstraps/ | 279 | SITES.${RUST_STAGE0}= https://us-central.manta.mnx.io/pkgsrc/public/pkg-bootstraps/ | |
282 | DISTFILES:= ${DISTFILES} ${RUST_STAGE0} | 280 | DISTFILES:= ${DISTFILES} ${RUST_STAGE0} | |
283 | RUST_BOOTSTRAP_PATH?= ${WRKDIR}/rust-${RUST_STAGE0_VER}-${RUST_ARCH} | 281 | RUST_BOOTSTRAP_PATH?= ${WRKDIR}/rust-${RUST_STAGE0_VER}-${RUST_ARCH} | |
284 | # Override default "x86_64-sun-solaris" selection | 282 | # Override default "x86_64-sun-solaris" selection | |
285 | CONFIGURE_ARGS+= --set=target.${RUST_ARCH}.llvm-config=${LLVM_CONFIG_PATH} | 283 | CONFIGURE_ARGS+= --set=target.${RUST_ARCH}.llvm-config=${LLVM_CONFIG_PATH} | |
286 | CONFIGURE_ARGS+= --build=${RUST_ARCH} | 284 | CONFIGURE_ARGS+= --build=${RUST_ARCH} | |
287 | CONFIGURE_ARGS+= --host=${RUST_ARCH} | 285 | CONFIGURE_ARGS+= --host=${RUST_ARCH} | |
288 | CONFIGURE_ARGS+= --target=${RUST_ARCH} | 286 | CONFIGURE_ARGS+= --target=${RUST_ARCH} | |
289 | .endif | 287 | .endif | |
290 | .if ${MACHINE_PLATFORM:MFreeBSD-*-x86_64} || make(distinfo) || make (makesum) || make(mdi) | 288 | .if ${MACHINE_PLATFORM:MFreeBSD-*-x86_64} || make(distinfo) || make (makesum) || make(mdi) | |
291 | RUST_STAGE0_VER= 1.73.0 | 289 | RUST_STAGE0_VER= 1.74.1 | |
292 | RUST_ARCH:= x86_64-unknown-freebsd | 290 | RUST_ARCH:= x86_64-unknown-freebsd | |
293 | RUST_STAGE0:= rust-${RUST_STAGE0_VER}-${RUST_ARCH}.tar.gz | 291 | RUST_STAGE0:= rust-${RUST_STAGE0_VER}-${RUST_ARCH}.tar.gz | |
294 | RUST_STD_STAGE0:= rust-std-${RUST_STAGE0_VER}-${RUST_ARCH}.tar.gz | 292 | RUST_STD_STAGE0:= rust-std-${RUST_STAGE0_VER}-${RUST_ARCH}.tar.gz | |
295 | DISTFILES:= ${DISTFILES} ${RUST_STAGE0} ${RUST_STD_STAGE0} | 293 | DISTFILES:= ${DISTFILES} ${RUST_STAGE0} ${RUST_STD_STAGE0} | |
296 | .endif | 294 | .endif | |
297 | .if ${MACHINE_PLATFORM:MNetBSD-*-i386} || make(distinfo) || make (makesum) || make(mdi) | 295 | .if ${MACHINE_PLATFORM:MNetBSD-*-i386} || make(distinfo) || make (makesum) || make(mdi) | |
298 | RUST_STAGE0_VER= 1.73.0 | 296 | RUST_STAGE0_VER= 1.74.1 | |
299 | RUST_ARCH= i586-unknown-netbsd | 297 | RUST_ARCH= i586-unknown-netbsd | |
300 | RUST_STAGE0:= rust-${RUST_STAGE0_VER}-${RUST_ARCH}.tar.xz | 298 | RUST_STAGE0:= rust-${RUST_STAGE0_VER}-${RUST_ARCH}.tar.xz | |
301 | RUST_STD_STAGE0:= rust-std-${RUST_STAGE0_VER}-${RUST_ARCH}.tar.xz | 299 | RUST_STD_STAGE0:= rust-std-${RUST_STAGE0_VER}-${RUST_ARCH}.tar.xz | |
302 | SITES.${RUST_STAGE0}= ${MASTER_SITE_LOCAL:=rust/} | 300 | SITES.${RUST_STAGE0}= ${MASTER_SITE_LOCAL:=rust/} | |
303 | SITES.${RUST_STD_STAGE0}= ${MASTER_SITE_LOCAL:=rust/} | 301 | SITES.${RUST_STD_STAGE0}= ${MASTER_SITE_LOCAL:=rust/} | |
304 | DISTFILES:= ${DISTFILES} ${RUST_STAGE0} ${RUST_STD_STAGE0} | 302 | DISTFILES:= ${DISTFILES} ${RUST_STAGE0} ${RUST_STD_STAGE0} | |
305 | # Setting this changes it for every distfile, which doesn't match what is | 303 | # Setting this changes it for every distfile, which doesn't match what is | |
306 | # currently in distinfo. | 304 | # currently in distinfo. | |
307 | #DIST_SUBDIR= ${PKGNAME} | 305 | #DIST_SUBDIR= ${PKGNAME} | |
308 | # For atomic ops | 306 | # For atomic ops | |
309 | CFLAGS+= -march=i586 | 307 | CFLAGS+= -march=i586 | |
310 | CONFIGURE_ARGS+= --build=${RUST_ARCH} | 308 | CONFIGURE_ARGS+= --build=${RUST_ARCH} | |
311 | pre-build: pre-build-fix-paxctl | 309 | pre-build: pre-build-fix-paxctl | |
312 | .PHONY: pre-build-fix-paxctl | 310 | .PHONY: pre-build-fix-paxctl | |
313 | pre-build-fix-paxctl: | 311 | pre-build-fix-paxctl: | |
314 | ${TOOLS_PLATFORM.paxctl} +am ${WRKDIR}/rust-bootstrap/bin/cargo | 312 | ${TOOLS_PLATFORM.paxctl} +am ${WRKDIR}/rust-bootstrap/bin/cargo | |
315 | ${TOOLS_PLATFORM.paxctl} +am ${WRKDIR}/rust-bootstrap/bin/rustc | 313 | ${TOOLS_PLATFORM.paxctl} +am ${WRKDIR}/rust-bootstrap/bin/rustc | |
316 | .endif | 314 | .endif | |
317 | .if ${MACHINE_PLATFORM:MNetBSD-*-x86_64} || make(distinfo) || make (makesum) || make(mdi) | 315 | .if ${MACHINE_PLATFORM:MNetBSD-*-x86_64} || make(distinfo) || make (makesum) || make(mdi) | |
318 | RUST_STAGE0_VER= 1.73.0 | 316 | RUST_STAGE0_VER= 1.74.1 | |
319 | RUST_ARCH= x86_64-unknown-netbsd | 317 | RUST_ARCH= x86_64-unknown-netbsd | |
320 | RUST_STAGE0:= rust-${RUST_STAGE0_VER}-${RUST_ARCH}.tar.xz | 318 | RUST_STAGE0:= rust-${RUST_STAGE0_VER}-${RUST_ARCH}.tar.xz | |
321 | RUST_STD_STAGE0:= rust-std-${RUST_STAGE0_VER}-${RUST_ARCH}.tar.xz | 319 | RUST_STD_STAGE0:= rust-std-${RUST_STAGE0_VER}-${RUST_ARCH}.tar.xz | |
322 | DISTFILES:= ${DISTFILES} ${RUST_STAGE0} ${RUST_STD_STAGE0} | 320 | DISTFILES:= ${DISTFILES} ${RUST_STAGE0} ${RUST_STD_STAGE0} | |
323 | .endif | 321 | .endif | |
324 | .if ${MACHINE_PLATFORM:MNetBSD-*-powerpc} || make(distinfo) || make (makesum) || make(mdi) | 322 | .if ${MACHINE_PLATFORM:MNetBSD-*-powerpc} || make(distinfo) || make (makesum) || make(mdi) | |
325 | RUST_STAGE0_VER= 1.73.0 | 323 | RUST_STAGE0_VER= 1.74.1 | |
326 | RUST_ARCH= powerpc-unknown-netbsd-nb1 | 324 | RUST_ARCH= powerpc-unknown-netbsd | |
327 | 325 | |||
328 | # Cross-built against NetBSD 9.0 | 326 | # Cross-built against NetBSD 9.0 | |
329 | RUST_STAGE0:= rust-${RUST_STAGE0_VER}-${RUST_ARCH}.tar.xz | 327 | RUST_STAGE0:= rust-${RUST_STAGE0_VER}-${RUST_ARCH}.tar.xz | |
330 | RUST_STD_STAGE0:= rust-std-${RUST_STAGE0_VER}-${RUST_ARCH}.tar.xz | 328 | RUST_STD_STAGE0:= rust-std-${RUST_STAGE0_VER}-${RUST_ARCH}.tar.xz | |
331 | DISTFILES:= ${DISTFILES} ${RUST_STAGE0} ${RUST_STD_STAGE0} | 329 | DISTFILES:= ${DISTFILES} ${RUST_STAGE0} ${RUST_STD_STAGE0} | |
332 | SITES.${RUST_STAGE0}= ${MASTER_SITE_LOCAL:=rust/} | 330 | SITES.${RUST_STAGE0}= ${MASTER_SITE_LOCAL:=rust/} | |
333 | SITES.${RUST_STD_STAGE0}= ${MASTER_SITE_LOCAL:=rust/} | 331 | SITES.${RUST_STD_STAGE0}= ${MASTER_SITE_LOCAL:=rust/} | |
334 | 332 | |||
335 | .endif | 333 | .endif | |
336 | .if ${MACHINE_PLATFORM:MNetBSD-*-aarch64} || make(distinfo) || make (makesum) || make(mdi) | 334 | .if ${MACHINE_PLATFORM:MNetBSD-*-aarch64} || make(distinfo) || make (makesum) || make(mdi) | |
337 | RUST_STAGE0_VER= 1.73.0 | 335 | RUST_STAGE0_VER= 1.74.1 | |
338 | RUST_ARCH= aarch64-unknown-netbsd | 336 | RUST_ARCH= aarch64-unknown-netbsd | |
339 | RUST_STAGE0:= rust-${RUST_STAGE0_VER}-${RUST_ARCH}.tar.xz | 337 | RUST_STAGE0:= rust-${RUST_STAGE0_VER}-${RUST_ARCH}.tar.xz | |
340 | RUST_STD_STAGE0:= rust-std-${RUST_STAGE0_VER}-${RUST_ARCH}.tar.xz | 338 | RUST_STD_STAGE0:= rust-std-${RUST_STAGE0_VER}-${RUST_ARCH}.tar.xz | |
341 | DISTFILES:= ${DISTFILES} ${RUST_STAGE0} ${RUST_STD_STAGE0} | 339 | DISTFILES:= ${DISTFILES} ${RUST_STAGE0} ${RUST_STD_STAGE0} | |
342 | SITES.${RUST_STAGE0}= ${MASTER_SITE_LOCAL:=rust/} | 340 | SITES.${RUST_STAGE0}= ${MASTER_SITE_LOCAL:=rust/} | |
343 | SITES.${RUST_STD_STAGE0}= ${MASTER_SITE_LOCAL:=rust/} | 341 | SITES.${RUST_STD_STAGE0}= ${MASTER_SITE_LOCAL:=rust/} | |
344 | .endif | 342 | .endif | |
345 | .if ${MACHINE_PLATFORM:MNetBSD-*-aarch64eb} || make(distinfo) || make (makesum) || make(mdi) | 343 | .if ${MACHINE_PLATFORM:MNetBSD-*-aarch64eb} || make(distinfo) || make (makesum) || make(mdi) | |
346 | RUST_STAGE0_VER= 1.73.0 | 344 | RUST_STAGE0_VER= 1.74.1 | |
347 | RUST_ARCH= aarch64_be-unknown-netbsd | 345 | RUST_ARCH= aarch64_be-unknown-netbsd | |
348 | RUST_STAGE0:= rust-${RUST_STAGE0_VER}-${RUST_ARCH}.tar.xz | 346 | RUST_STAGE0:= rust-${RUST_STAGE0_VER}-${RUST_ARCH}.tar.xz | |
349 | RUST_STD_STAGE0:= rust-std-${RUST_STAGE0_VER}-${RUST_ARCH}.tar.xz | 347 | RUST_STD_STAGE0:= rust-std-${RUST_STAGE0_VER}-${RUST_ARCH}.tar.xz | |
350 | DISTFILES:= ${DISTFILES} ${RUST_STAGE0} ${RUST_STD_STAGE0} | 348 | DISTFILES:= ${DISTFILES} ${RUST_STAGE0} ${RUST_STD_STAGE0} | |
351 | SITES.${RUST_STAGE0}= ${MASTER_SITE_LOCAL:=rust/} | 349 | SITES.${RUST_STAGE0}= ${MASTER_SITE_LOCAL:=rust/} | |
352 | SITES.${RUST_STD_STAGE0}= ${MASTER_SITE_LOCAL:=rust/} | 350 | SITES.${RUST_STD_STAGE0}= ${MASTER_SITE_LOCAL:=rust/} | |
353 | .endif | 351 | .endif | |
354 | .if ${MACHINE_PLATFORM:MNetBSD-*-sparc64} || make(distinfo) || make (makesum) || make(mdi) | 352 | .if ${MACHINE_PLATFORM:MNetBSD-*-sparc64} || make(distinfo) || make (makesum) || make(mdi) | |
355 | RUST_STAGE0_VER= 1.73.0 | 353 | RUST_STAGE0_VER= 1.74.1 | |
356 | RUST_ARCH= sparc64-unknown-netbsd | 354 | RUST_ARCH= sparc64-unknown-netbsd | |
357 | RUST_STAGE0:= rust-${RUST_STAGE0_VER}-${RUST_ARCH}.tar.xz | 355 | RUST_STAGE0:= rust-${RUST_STAGE0_VER}-${RUST_ARCH}.tar.xz | |
358 | RUST_STD_STAGE0:= rust-std-${RUST_STAGE0_VER}-${RUST_ARCH}.tar.xz | 356 | RUST_STD_STAGE0:= rust-std-${RUST_STAGE0_VER}-${RUST_ARCH}.tar.xz | |
359 | DISTFILES:= ${DISTFILES} ${RUST_STAGE0} ${RUST_STD_STAGE0} | 357 | DISTFILES:= ${DISTFILES} ${RUST_STAGE0} ${RUST_STD_STAGE0} | |
360 | SITES.${RUST_STAGE0}= ${MASTER_SITE_LOCAL:=rust/} | 358 | SITES.${RUST_STAGE0}= ${MASTER_SITE_LOCAL:=rust/} | |
361 | SITES.${RUST_STD_STAGE0}= ${MASTER_SITE_LOCAL:=rust/} | 359 | SITES.${RUST_STD_STAGE0}= ${MASTER_SITE_LOCAL:=rust/} | |
362 | .endif | 360 | .endif | |
363 | .if ${MACHINE_PLATFORM:MNetBSD-*-earmv7hf} || make(distinfo) || make (makesum) || make(mdi) | 361 | .if ${MACHINE_PLATFORM:MNetBSD-*-earmv7hf} || make(distinfo) || make (makesum) || make(mdi) | |
364 | RUST_ARCH= armv7-unknown-netbsd-eabihf | 362 | RUST_ARCH= armv7-unknown-netbsd-eabihf | |
365 | RUST_STAGE0_VER= 1.73.0 | 363 | RUST_STAGE0_VER= 1.74.1 | |
366 | RUST_STAGE0:= rust-${RUST_STAGE0_VER}-${RUST_ARCH}.tar.xz | 364 | RUST_STAGE0:= rust-${RUST_STAGE0_VER}-${RUST_ARCH}.tar.xz | |
367 | RUST_STD_STAGE0:= rust-std-${RUST_STAGE0_VER}-${RUST_ARCH}.tar.xz | 365 | RUST_STD_STAGE0:= rust-std-${RUST_STAGE0_VER}-${RUST_ARCH}.tar.xz | |
368 | DISTFILES:= ${DISTFILES} ${RUST_STAGE0} ${RUST_STD_STAGE0} | 366 | DISTFILES:= ${DISTFILES} ${RUST_STAGE0} ${RUST_STD_STAGE0} | |
369 | SITES.${RUST_STAGE0}= ${MASTER_SITE_LOCAL:=rust/} | 367 | SITES.${RUST_STAGE0}= ${MASTER_SITE_LOCAL:=rust/} | |
370 | SITES.${RUST_STD_STAGE0}= ${MASTER_SITE_LOCAL:=rust/} | 368 | SITES.${RUST_STD_STAGE0}= ${MASTER_SITE_LOCAL:=rust/} | |
371 | .endif | 369 | .endif | |
372 | .if ${MACHINE_PLATFORM:MNetBSD-*-earmv6hf} || make(distinfo) || make (makesum) || make(mdi) | 370 | .if ${MACHINE_PLATFORM:MNetBSD-*-earmv6hf} || make(distinfo) || make (makesum) || make(mdi) | |
373 | RUST_ARCH= armv6-unknown-netbsd-eabihf | 371 | RUST_ARCH= armv6-unknown-netbsd-eabihf | |
374 | RUST_STAGE0_VER= 1.73.0 | 372 | RUST_STAGE0_VER= 1.74.1 | |
375 | RUST_STAGE0:= rust-${RUST_STAGE0_VER}-${RUST_ARCH}.tar.xz | 373 | RUST_STAGE0:= rust-${RUST_STAGE0_VER}-${RUST_ARCH}.tar.xz | |
376 | RUST_STD_STAGE0:= rust-std-${RUST_STAGE0_VER}-${RUST_ARCH}.tar.xz | 374 | RUST_STD_STAGE0:= rust-std-${RUST_STAGE0_VER}-${RUST_ARCH}.tar.xz | |
377 | DISTFILES:= ${DISTFILES} ${RUST_STAGE0} ${RUST_STD_STAGE0} | 375 | DISTFILES:= ${DISTFILES} ${RUST_STAGE0} ${RUST_STD_STAGE0} | |
378 | SITES.${RUST_STAGE0}= ${MASTER_SITE_LOCAL:=rust/} | 376 | SITES.${RUST_STAGE0}= ${MASTER_SITE_LOCAL:=rust/} | |
379 | SITES.${RUST_STD_STAGE0}= ${MASTER_SITE_LOCAL:=rust/} | 377 | SITES.${RUST_STD_STAGE0}= ${MASTER_SITE_LOCAL:=rust/} | |
380 | .endif | 378 | .endif | |
381 | .if ${MACHINE_PLATFORM:MNetBSD-*-mipsel} || make(distinfo) || make (makesum) || make(mdi) | 379 | .if ${MACHINE_PLATFORM:MNetBSD-*-mipsel} || make(distinfo) || make (makesum) || make(mdi) | |
382 | RUST_ARCH= mipsel-unknown-netbsd | 380 | RUST_ARCH= mipsel-unknown-netbsd | |
383 | RUST_STAGE0_VER= 1.73.0 | 381 | RUST_STAGE0_VER= 1.74.1 | |
384 | RUST_STAGE0:= rust-${RUST_STAGE0_VER}-${RUST_ARCH}.tar.xz | 382 | RUST_STAGE0:= rust-${RUST_STAGE0_VER}-${RUST_ARCH}.tar.xz | |
385 | RUST_STD_STAGE0:= rust-std-${RUST_STAGE0_VER}-${RUST_ARCH}.tar.xz | 383 | RUST_STD_STAGE0:= rust-std-${RUST_STAGE0_VER}-${RUST_ARCH}.tar.xz | |
386 | DISTFILES:= ${DISTFILES} ${RUST_STAGE0} ${RUST_STD_STAGE0} | 384 | DISTFILES:= ${DISTFILES} ${RUST_STAGE0} ${RUST_STD_STAGE0} | |
387 | SITES.${RUST_STAGE0}= ${MASTER_SITE_LOCAL:=rust/} | 385 | SITES.${RUST_STAGE0}= ${MASTER_SITE_LOCAL:=rust/} | |
388 | SITES.${RUST_STD_STAGE0}= ${MASTER_SITE_LOCAL:=rust/} | 386 | SITES.${RUST_STD_STAGE0}= ${MASTER_SITE_LOCAL:=rust/} | |
389 | .endif | 387 | .endif | |
390 | .if ${MACHINE_PLATFORM:MNetBSD-*-riscv64} || make(distinfo) || make (makesum) || make(mdi) | 388 | .if ${MACHINE_PLATFORM:MNetBSD-*-riscv64} || make(distinfo) || make (makesum) || make(mdi) | |
391 | RUST_ARCH= riscv64gc-unknown-netbsd | 389 | RUST_ARCH= riscv64gc-unknown-netbsd | |
392 | RUST_STAGE0_VER= 1.73.0 | 390 | RUST_STAGE0_VER= 1.74.1 | |
393 | RUST_STAGE0:= rust-${RUST_STAGE0_VER}-${RUST_ARCH}.tar.xz | 391 | RUST_STAGE0:= rust-${RUST_STAGE0_VER}-${RUST_ARCH}.tar.xz | |
394 | RUST_STD_STAGE0:= rust-std-${RUST_STAGE0_VER}-${RUST_ARCH}.tar.xz | 392 | RUST_STD_STAGE0:= rust-std-${RUST_STAGE0_VER}-${RUST_ARCH}.tar.xz | |
395 | DISTFILES:= ${DISTFILES} ${RUST_STAGE0} ${RUST_STD_STAGE0} | 393 | DISTFILES:= ${DISTFILES} ${RUST_STAGE0} ${RUST_STD_STAGE0} | |
396 | SITES.${RUST_STAGE0}= ${MASTER_SITE_LOCAL:=rust/} | 394 | SITES.${RUST_STAGE0}= ${MASTER_SITE_LOCAL:=rust/} | |
397 | SITES.${RUST_STD_STAGE0}= ${MASTER_SITE_LOCAL:=rust/} | 395 | SITES.${RUST_STD_STAGE0}= ${MASTER_SITE_LOCAL:=rust/} | |
398 | .endif | 396 | .endif | |
399 | 397 | |||
400 | # You may override RUST_BOOTSTRAP_PATH and RUST_ARCH in mk.conf | 398 | # You may override RUST_BOOTSTRAP_PATH and RUST_ARCH in mk.conf | |
401 | # if you have a local bootstrap compiler. | 399 | # if you have a local bootstrap compiler. | |
402 | .if !defined(RUST_ARCH) && !defined(RUST_BOOTSTRAP_PATH) | 400 | .if !defined(RUST_ARCH) && !defined(RUST_BOOTSTRAP_PATH) | |
403 | NOT_FOR_PLATFORM+= ${MACHINE_PLATFORM} | 401 | NOT_FOR_PLATFORM+= ${MACHINE_PLATFORM} | |
404 | .else | 402 | .else | |
405 | RUST_BOOTSTRAP_PATH?= ${WRKDIR}/rust-bootstrap | 403 | RUST_BOOTSTRAP_PATH?= ${WRKDIR}/rust-bootstrap | |
406 | .endif | 404 | .endif | |
407 | 405 | |||
408 | .if ${OPSYS} == "SunOS" | 406 | .if ${OPSYS} == "SunOS" | |
409 | TOOL_DEPENDS+= coreutils>=0:../../sysutils/coreutils | 407 | TOOL_DEPENDS+= coreutils>=0:../../sysutils/coreutils | |
410 | TOOL_DEPENDS+= gzip>=0:../../archivers/gzip | 408 | TOOL_DEPENDS+= gzip>=0:../../archivers/gzip | |
411 | TOOLS_CREATE+= md5sum | 409 | TOOLS_CREATE+= md5sum | |
412 | TOOLS_PATH.md5sum= ${PREFIX}/bin/gmd5sum | 410 | TOOLS_PATH.md5sum= ${PREFIX}/bin/gmd5sum | |
413 | TOOLS_PLATFORM.gzcat= ${PREFIX}/bin/gzip -cd | 411 | TOOLS_PLATFORM.gzcat= ${PREFIX}/bin/gzip -cd | |
414 | .endif | 412 | .endif | |
415 | 413 | |||
416 | SUBST_CLASSES+= rpath | 414 | SUBST_CLASSES+= prefix | |
417 | SUBST_STAGE.rpath= pre-configure | 415 | SUBST_STAGE.prefix= pre-configure | |
418 | SUBST_FILES.rpath+= compiler/rustc_codegen_ssa/src/back/linker.rs | 416 | SUBST_FILES.prefix+= compiler/rustc_codegen_ssa/src/back/linker.rs | |
419 | SUBST_FILES.rpath+= compiler/rustc_target/src/spec/netbsd_base.rs | 417 | SUBST_FILES.prefix+= compiler/rustc_target/src/spec/base/netbsd.rs | |
420 | SUBST_FILES.rpath+= src/bootstrap/builder.rs | 418 | SUBST_FILES.prefix+= src/bootstrap/src/core/build_steps/compile.rs | |
421 | SUBST_FILES.rpath+= src/bootstrap/compile.rs | 419 | SUBST_FILES.prefix+= src/bootstrap/src/core/builder.rs | |
422 | SUBST_VARS.rpath= PREFIX | 420 | SUBST_FILES.prefix+= src/bootstrap/bootstrap.py | |
421 | SUBST_VARS.prefix= PREFIX | |||
423 | 422 | |||
424 | # | 423 | # | |
425 | # Generate list of subst entries for various .cargo-checksum.json files. These | 424 | # Generate list of subst entries for various .cargo-checksum.json files. These | |
426 | # are all handled together in one big substitution to simplify things rather | 425 | # are all handled together in one big substitution to simplify things rather | |
427 | # than one substitution entry per file, but are kept separate below to ease | 426 | # than one substitution entry per file, but are kept separate below to ease | |
428 | # updating and verification. | 427 | # updating and verification. | |
429 | # | 428 | # | |
430 | 429 | |||
431 | CKSUM_CRATES+= vendor/cc-1.0.73 | |||
432 | CKSUMS+= 38970d678de0efb4b5e2978265daa8a613a1db35fc42e669621b03fc56d5b138 | |||
433 | CKSUMS+= 65de0d6593a4256e5fcaf898f9468d71bab672c70a2dfab3dcb8514e9b72819c | |||
434 | ||||
435 | CKSUM_CRATES+= vendor/cc | |||
436 | CKSUMS+= 17a4659710aa290c4ed9c23063c7b202c5bcf2a84de33aa1f01fc6fded69a1f8 | |||
437 | CKSUMS+= a19bcb1a561d4ba5846f8f89fcfe6f05a3cb2e79baf8f21f53f0fba012db1b7f | |||
438 | ||||
439 | CKSUM_CRATES+= vendor/libc | 430 | CKSUM_CRATES+= vendor/libc | |
431 | ||||
432 | CKSUM_CRATES+= vendor/libc-0.2.146 | |||
440 | CKSUMS+= 55ce4624745e31ad226b47fde177a46176a89da3fa5030663673a115102471f9 | 433 | CKSUMS+= 55ce4624745e31ad226b47fde177a46176a89da3fa5030663673a115102471f9 | |
441 | CKSUMS+= 09ab15cd50245f4ced230b7919657ab170e06443bb0ed4baf4449d3472f5f656 | 434 | CKSUMS+= 09ab15cd50245f4ced230b7919657ab170e06443bb0ed4baf4449d3472f5f656 | |
442 | CKSUMS+= 90dd33ef20dc3be8aef5bd152a6a06e7ab34f9527b3978487b593aaa16a907bd | 435 | CKSUMS+= 90dd33ef20dc3be8aef5bd152a6a06e7ab34f9527b3978487b593aaa16a907bd | |
443 | CKSUMS+= ec1cb2b8522ce7d35c9fce2f5b17a1a7e28cae9836f1cf11e267f222b72dff60 | 436 | CKSUMS+= ec1cb2b8522ce7d35c9fce2f5b17a1a7e28cae9836f1cf11e267f222b72dff60 | |
437 | ||||
438 | CKSUM_CRATES+= vendor/libc-0.2.149 | |||
439 | CKSUMS+= 1f1beb74c33bd3ad6a5d7aae2afdacf0ccbad0f9dacda2894d2cfdc2414174ae | |||
440 | CKSUMS+= 80f3168251556b3eb918056aa9563db07383f61e69a262f3af390b542fd757bb | |||
444 | CKSUMS+= b1660c631a599a3355116e7485b88ab2f8f2929c2e37851a763431387b902f14 | 441 | CKSUMS+= b1660c631a599a3355116e7485b88ab2f8f2929c2e37851a763431387b902f14 | |
445 | CKSUMS+= 990d1c6c01db31b9e5541128e4987b114f39c6808d94a5f8f048f492cfb96d78 | 442 | CKSUMS+= 990d1c6c01db31b9e5541128e4987b114f39c6808d94a5f8f048f492cfb96d78 | |
446 | 443 | |||
447 | CKSUM_CRATES+= vendor/libc-0.2.138 | 444 | CKSUM_CRATES+= vendor/cc-1.0.73 | |
448 | CKSUMS+= 107a4aa396b8383c66e0ace2f941450b4b69146558cdc4d9fbe33eeab51760f1 | 445 | CKSUMS+= 38970d678de0efb4b5e2978265daa8a613a1db35fc42e669621b03fc56d5b138 | |
449 | CKSUMS+= 4be83bef456569d59405edf134e7fe8eff78f3fe35f1efd60e15405d5c822725 | 446 | CKSUMS+= 65de0d6593a4256e5fcaf898f9468d71bab672c70a2dfab3dcb8514e9b72819c | |
450 | ||||
451 | CKSUM_CRATES+= vendor/libc-0.2.140 | |||
452 | CKSUMS+= 4493317993af390d8aafc2cb7ace4c349dfc9d2451fd666844f04a4fa1f47442 | |||
453 | CKSUMS+= 537a01c3cd5507f493616193991e1135c7896aae3fc92d98ec9facbfe243d980 | |||
454 | CKSUMS+= 6442ed05eb390d44a03daa9800af1030f2ee3e61db98675262c227b28de51937 | |||
455 | CKSUMS+= ec554c837999c718786debfcfe2241984193751fcd52156323b418d96319aa95 | |||
456 | 447 | |||
457 | CKSUM_CRATES+= vendor/libc-0.2.146 | 448 | CKSUM_CRATES+= vendor/cc | |
458 | #CKSUMS+= 6442ed05eb390d44a03daa9800af1030f2ee3e61db98675262c227b28de51937 | 449 | CKSUMS+= 17a4659710aa290c4ed9c23063c7b202c5bcf2a84de33aa1f01fc6fded69a1f8 | |
459 | #CKSUMS+= ec554c837999c718786debfcfe2241984193751fcd52156323b418d96319aa95 | 450 | CKSUMS+= a19bcb1a561d4ba5846f8f89fcfe6f05a3cb2e79baf8f21f53f0fba012db1b7f | |
460 | #CKSUMS+= 6a60a542639528a0a34b9c9a7298973ec2cf1449c59546b7b30dcef6c51874dd | |||
461 | #CKSUMS+= ec1cb2b8522ce7d35c9fce2f5b17a1a7e28cae9836f1cf11e267f222b72dff60 | |||
462 | 451 | |||
463 | CKSUM_CRATES+= vendor/lzma-sys | 452 | CKSUM_CRATES+= vendor/lzma-sys | |
464 | CKSUMS+= 6fd5e9245db34c6f557b8bfcaf03db82fc88c3b06dbfbb5f03b2bcd138983ef9 | 453 | CKSUMS+= 6fd5e9245db34c6f557b8bfcaf03db82fc88c3b06dbfbb5f03b2bcd138983ef9 | |
465 | CKSUMS+= 5e252578b5d266f6a4c8dc9f71ca7a91536ccb8c5c7d7753b82f12ec886459ef | 454 | CKSUMS+= 5e252578b5d266f6a4c8dc9f71ca7a91536ccb8c5c7d7753b82f12ec886459ef | |
466 | 455 | |||
467 | CKSUM_CRATES+= vendor/stacker | 456 | CKSUM_CRATES+= vendor/stacker | |
468 | CKSUMS+= 59ca847887cf19387119d18c57f08d5a8520d714876ca0142b8f1c001ecde06b | 457 | CKSUMS+= 59ca847887cf19387119d18c57f08d5a8520d714876ca0142b8f1c001ecde06b | |
469 | CKSUMS+= 03be8ae293b713fe6e9703e4809dd68caaec992bae6777914ffddae8da2a9bc7 | 458 | CKSUMS+= 03be8ae293b713fe6e9703e4809dd68caaec992bae6777914ffddae8da2a9bc7 | |
470 | 459 | |||
471 | CKSUM_CRATES+= vendor/crossbeam-utils | 460 | CKSUM_CRATES+= vendor/crossbeam-utils | |
472 | CKSUMS+= 5f75132808d9e8d6e266fe77f9e20bbc35855a1c37a5dbc0940b3e989bca1a94 | 461 | CKSUMS+= 5f75132808d9e8d6e266fe77f9e20bbc35855a1c37a5dbc0940b3e989bca1a94 | |
473 | CKSUMS+= 3d7c747108434546837b1c5664111c9146fcbfb2e084c95f8ce0be970d652421 | 462 | CKSUMS+= 3d7c747108434546837b1c5664111c9146fcbfb2e084c95f8ce0be970d652421 | |
474 | 463 |
@@ -1,54 +1,60 @@ | @@ -1,54 +1,60 @@ | |||
1 | # $NetBSD: options.mk,v 1.34 2024/01/15 12:24:21 adam Exp $ | 1 | # $NetBSD: options.mk,v 1.35 2024/03/03 14:53:32 he Exp $ | |
2 | 2 | |||
3 | PKG_OPTIONS_VAR= PKG_OPTIONS.rust | 3 | PKG_OPTIONS_VAR= PKG_OPTIONS.rust | |
4 | PKG_SUPPORTED_OPTIONS+= rust-cargo-static rust-docs | 4 | PKG_SUPPORTED_OPTIONS+= rust-cargo-static rust-docs | |
5 | 5 | |||
6 | .include "../../mk/bsd.fast.prefs.mk" | 6 | .include "../../mk/bsd.fast.prefs.mk" | |
7 | 7 | |||
8 | # The bundled LLVM current has issues building on SunOS. | 8 | # The bundled LLVM current has issues building on SunOS. | |
9 | .if ${OPSYS} != "SunOS" | 9 | .if ${OPSYS} != "SunOS" | |
10 | PKG_SUPPORTED_OPTIONS+= rust-internal-llvm | 10 | PKG_SUPPORTED_OPTIONS+= rust-internal-llvm | |
11 | # There may be compatibility issues with the base LLVM on e.g. NetBSD. | 11 | # There may be compatibility issues with the base LLVM on e.g. NetBSD. | |
12 | . if !empty(HAVE_LLVM) || ${MACHINE_PLATFORM:MDarwin-*-aarch64} | 12 | . if !empty(HAVE_LLVM) || ${MACHINE_PLATFORM:MDarwin-*-aarch64} | |
13 | PKG_SUGGESTED_OPTIONS+= rust-internal-llvm | 13 | PKG_SUGGESTED_OPTIONS+= rust-internal-llvm | |
14 | . endif | 14 | . endif | |
15 | .endif | 15 | .endif | |
16 | 16 | |||
17 | # If cross-building, always use the internal LLVM | 17 | # If cross-building, always use the internal LLVM | |
18 | .if !empty(TARGET) | 18 | .if !empty(TARGET) | |
19 | PKG_SUGGESTED_OPTIONS+= rust-internal-llvm | 19 | PKG_SUGGESTED_OPTIONS+= rust-internal-llvm | |
20 | .endif | 20 | .endif | |
21 | 21 | |||
22 | # (NetBSD)/sparc64 systems fail to build libunwind, | 22 | # NetBSD/sparc64 when using the internal LLVM needs | |
23 | # a dependency of pkgsrc llvm, so use the internal one instead | 23 | # to not use gcc 10.4 or 10.5 (as found in 10.0_BETA or 10.0), ref. | |
24 | .if ${MACHINE_PLATFORM:MNetBSD-*-sparc64} | 24 | # https://github.com/rust-lang/rust/issues/117231 | |
25 | PKG_SUGGESTED_OPTIONS+= rust-internal-llvm | 25 | # (however, gcc from 9.x produces a working LLVM). | |
26 | .if ${MACHINE_PLATFORM:MNetBSD-10.*-sparc64} | |||
27 | . if !empty(PKG_OPTIONS:Mrust-internal-llvm) | |||
28 | # Require GCC 12 (from pkgsrc) to correctly build the embedded LLVM (17.x). | |||
29 | GCC_REQD= 12 | |||
30 | . endif | |||
26 | .endif | 31 | .endif | |
27 | 32 | |||
28 | # Bundle OpenSSL and curl into the cargo binary when producing | 33 | # Bundle OpenSSL and curl into the cargo binary when producing | |
29 | # bootstraps on NetBSD. | 34 | # bootstraps on NetBSD. | |
30 | .if ${OPSYS} == "NetBSD" && ${BUILD_TARGET} == "dist" | 35 | .if ${OPSYS} == "NetBSD" && ${BUILD_TARGET} == "dist" | |
31 | PKG_SUGGESTED_OPTIONS+= rust-cargo-static | 36 | PKG_SUGGESTED_OPTIONS+= rust-cargo-static | |
32 | .endif | 37 | .endif | |
33 | 38 | |||
34 | PKG_OPTIONS_LEGACY_OPTS+= rust-llvm:rust-internal-llvm | 39 | PKG_OPTIONS_LEGACY_OPTS+= rust-llvm:rust-internal-llvm | |
35 | 40 | |||
36 | .include "../../mk/bsd.options.mk" | 41 | .include "../../mk/bsd.options.mk" | |
37 | 42 | |||
38 | # | 43 | # | |
39 | # Use the internal copy of LLVM or the external one? | 44 | # Use the internal copy of LLVM or the external one? | |
40 | # | 45 | # | |
41 | .if empty(PKG_OPTIONS:Mrust-internal-llvm) | 46 | .if empty(PKG_OPTIONS:Mrust-internal-llvm) | |
47 | # External LLVM must be >= 15, ref. RELEASES.md | |||
42 | BUILDLINK_API_DEPENDS.llvm+= llvm>=15 | 48 | BUILDLINK_API_DEPENDS.llvm+= llvm>=15 | |
43 | .include "../../lang/libunwind/buildlink3.mk" | 49 | .include "../../lang/libunwind/buildlink3.mk" | |
44 | .include "../../lang/llvm/buildlink3.mk" | 50 | .include "../../lang/llvm/buildlink3.mk" | |
45 | CONFIGURE_ARGS+= --enable-llvm-link-shared | 51 | CONFIGURE_ARGS+= --enable-llvm-link-shared | |
46 | CONFIGURE_ARGS+= --llvm-libunwind=system | 52 | CONFIGURE_ARGS+= --llvm-libunwind=system | |
47 | CONFIGURE_ARGS+= --llvm-root=${BUILDLINK_PREFIX.llvm} | 53 | CONFIGURE_ARGS+= --llvm-root=${BUILDLINK_PREFIX.llvm} | |
48 | .endif | 54 | .endif | |
49 | 55 | |||
50 | # | 56 | # | |
51 | # Link cargo statically against "native" libraries. | 57 | # Link cargo statically against "native" libraries. | |
52 | # (openssl and curl specifically). | 58 | # (openssl and curl specifically). | |
53 | # | 59 | # | |
54 | .if !empty(PKG_OPTIONS:Mrust-cargo-static) | 60 | .if !empty(PKG_OPTIONS:Mrust-cargo-static) |
@@ -1,26 +1,26 @@ | @@ -1,26 +1,26 @@ | |||
1 | # $NetBSD: platform.mk,v 1.20 2023/10/25 05:50:43 pin Exp $ | 1 | # $NetBSD: platform.mk,v 1.21 2024/03/03 14:53:32 he Exp $ | |
2 | 2 | |||
3 | # This file encodes whether a given platform has support for rust. | 3 | # This file encodes whether a given platform has support for rust. | |
4 | 4 | |||
5 | # Platforms where rust ought to work but does not require a link to an | 5 | # Platforms where rust ought to work but does not require a link to an | |
6 | # open PR. | 6 | # open PR. | |
7 | 7 | |||
8 | .if !defined(PLATFORM_SUPPORTS_RUST) | 8 | .if !defined(PLATFORM_SUPPORTS_RUST) | |
9 | 9 | |||
10 | # Rust needs NetBSD>7 | 10 | # Rust needs NetBSD>8 | |
11 | .for rust_arch in aarch64 earmv7hf i386 powerpc riscv64 sparc64 x86_64 | 11 | .for rust_arch in aarch64 earmv7hf i386 powerpc riscv64 sparc64 x86_64 | |
12 | . for rust_os in Darwin FreeBSD Linux NetBSD SunOS | 12 | . for rust_os in Darwin FreeBSD Linux NetBSD SunOS | |
13 | . if ${OPSYS} != "NetBSD" || empty(OS_VERSION:M[0-7].*) | 13 | . if ${OPSYS} != "NetBSD" || empty(OS_VERSION:M[0-8].*) | |
14 | RUST_PLATFORMS+= ${rust_os}-*-${rust_arch} | 14 | RUST_PLATFORMS+= ${rust_os}-*-${rust_arch} | |
15 | . endif | 15 | . endif | |
16 | . endfor | 16 | . endfor | |
17 | .endfor | 17 | .endfor | |
18 | 18 | |||
19 | .for rust_platform in ${RUST_PLATFORMS} | 19 | .for rust_platform in ${RUST_PLATFORMS} | |
20 | . if !empty(MACHINE_PLATFORM:M${rust_platform}) | 20 | . if !empty(MACHINE_PLATFORM:M${rust_platform}) | |
21 | PLATFORM_SUPPORTS_RUST= yes | 21 | PLATFORM_SUPPORTS_RUST= yes | |
22 | . endif | 22 | . endif | |
23 | .endfor | 23 | .endfor | |
24 | PLATFORM_SUPPORTS_RUST?= no | 24 | PLATFORM_SUPPORTS_RUST?= no | |
25 | 25 | |||
26 | .endif # !defined(PLATFORM_SUPPORTS_RUST) | 26 | .endif # !defined(PLATFORM_SUPPORTS_RUST) |
@@ -1,51 +1,49 @@ | @@ -1,51 +1,49 @@ | |||
1 | $NetBSD: patch-compiler_rustc__llvm_build.rs,v 1.15 2024/01/06 19:00:19 he Exp $ | 1 | $NetBSD: patch-compiler_rustc__llvm_build.rs,v 1.16 2024/03/03 14:53:32 he Exp $ | |
2 | 2 | |||
3 | Fix build on NetBSD HEAD-llvm. XXX there is probably a better way to do this. | 3 | Fix build on NetBSD HEAD-llvm. XXX there is probably a better way to do this. | |
4 | 4 | |||
5 | Pick up -latomic tweak from | 5 | Pick up -latomic tweak from | |
6 | https://github.com/rust-lang/rust/issues/104220 | 6 | https://github.com/rust-lang/rust/issues/104220 | |
7 | and | 7 | and | |
8 | https://github.com/rust-lang/rust/pull/104572 | 8 | https://github.com/rust-lang/rust/pull/104572 | |
9 | 9 | |||
10 | --- compiler/rustc_llvm/build.rs.orig 2023-10-03 02:52:17.000000000 +0000 | 10 | --- compiler/rustc_llvm/build.rs.orig 2023-10-03 02:52:17.000000000 +0000 | |
11 | +++ compiler/rustc_llvm/build.rs | 11 | +++ compiler/rustc_llvm/build.rs | |
12 | @@ -249,6 +249,10 @@ fn main() { | 12 | @@ -249,6 +249,10 @@ fn main() { | |
13 | { | 13 | { | |
14 | // 32-bit targets need to link libatomic. | 14 | // 32-bit targets need to link libatomic. | |
15 | println!("cargo:rustc-link-lib=atomic"); | 15 | println!("cargo:rustc-link-lib=atomic"); | |
16 | + if target.contains("netbsd") | 16 | + if target.contains("netbsd") | |
17 | + { | 17 | + { | |
18 | + println!("cargo:rustc-link-lib=z"); | 18 | + println!("cargo:rustc-link-lib=z"); | |
19 | + } | 19 | + } | |
20 | } else if target.contains("windows-gnu") { | 20 | } else if target.contains("windows-gnu") { | |
21 | println!("cargo:rustc-link-lib=shell32"); | 21 | println!("cargo:rustc-link-lib=shell32"); | |
22 | println!("cargo:rustc-link-lib=uuid"); | 22 | println!("cargo:rustc-link-lib=uuid"); | |
23 | @@ -258,6 +262,14 @@ fn main() { | 23 | @@ -261,7 +265,11 @@ fn main() { | |
24 | { | 24 | // On NetBSD/i386, gcc and g++ is built for i486 (to maximize backward compat) | |
25 | println!("cargo:rustc-link-lib=z"); | 25 | // However, LLVM insists on using 64-bit atomics. | |
26 | } else if target.contains("netbsd") { | 26 | // This gives rise to a need to link rust itself with -latomic for these targets | |
27 | + // When build llvm for i486, and then need -latomic for 64-bit atomics | 27 | - if target.starts_with("i586") || target.starts_with("i686") { | |
28 | + if target.starts_with("i386") | 28 | + if target.starts_with("i386") | |
29 | + || target.starts_with("i486") | 29 | + || target.starts_with("i486") | |
30 | + || target.starts_with("i586") | 30 | + || target.starts_with("i586") | |
31 | + || target.starts_with("i686") | 31 | + || target.starts_with("i686") | |
32 | + { | 32 | + { | |
33 | + println!("cargo:rustc-link-lib=atomic"); | 33 | println!("cargo:rustc-link-lib=atomic"); | |
34 | + } | 34 | } | |
35 | println!("cargo:rustc-link-lib=z"); | 35 | println!("cargo:rustc-link-lib=z"); | |
36 | println!("cargo:rustc-link-lib=execinfo"); | 36 | @@ -352,7 +360,13 @@ fn main() { | |
37 | } | |||
38 | @@ -346,7 +358,13 @@ fn main() { | |||
39 | "c++" | 37 | "c++" | |
40 | } else if target.contains("netbsd") && llvm_static_stdcpp.is_some() { | 38 | } else if target.contains("netbsd") && llvm_static_stdcpp.is_some() { | |
41 | // NetBSD uses a separate library when relocation is required | 39 | // NetBSD uses a separate library when relocation is required | |
42 | - "stdc++_p" | 40 | - "stdc++_p" | |
43 | + if env::var_os("PKGSRC_HAVE_LIBCPP").is_some() { | 41 | + if env::var_os("PKGSRC_HAVE_LIBCPP").is_some() { | |
44 | + "c++_pic" | 42 | + "c++_pic" | |
45 | + } else { | 43 | + } else { | |
46 | + "stdc++_pic" | 44 | + "stdc++_pic" | |
47 | + } | 45 | + } | |
48 | + } else if env::var_os("PKGSRC_HAVE_LIBCPP").is_some() { | 46 | + } else if env::var_os("PKGSRC_HAVE_LIBCPP").is_some() { | |
49 | + "c++" | 47 | + "c++" | |
50 | } else if llvm_use_libcxx.is_some() { | 48 | } else if llvm_use_libcxx.is_some() { | |
51 | "c++" | 49 | "c++" |
@@ -1,15 +1,14 @@ | @@ -1,15 +1,14 @@ | |||
1 | $NetBSD: patch-compiler_rustc__target_src_spec_mod.rs,v 1.15 2023/10/25 05:50:43 pin Exp $ | 1 | $NetBSD: patch-compiler_rustc__target_src_spec_mod.rs,v 1.16 2024/03/03 14:53:32 he Exp $ | |
2 | 2 | |||
3 | Add i586(pentium) and mipsel NetBSD targets. | 3 | Add entry for NetBSD/mips64el. | |
4 | 4 | |||
5 | --- compiler/rustc_target/src/spec/mod.rs.orig 2021-03-23 16:15:10.000000000 +0000 | 5 | --- compiler/rustc_target/src/spec/mod.rs.orig 2024-01-13 14:20:59.236278792 +0000 | |
6 | +++ compiler/rustc_target/src/spec/mod.rs | 6 | +++ compiler/rustc_target/src/spec/mod.rs | |
7 | @@ -1324,6 +1324,8 @@ supported_targets! { | 7 | @@ -1532,6 +1532,7 @@ supported_targets! { | |
8 | ("armv6-unknown-netbsd-eabihf", armv6_unknown_netbsd_eabihf), | |||
9 | ("armv7-unknown-netbsd-eabihf", armv7_unknown_netbsd_eabihf), | 8 | ("armv7-unknown-netbsd-eabihf", armv7_unknown_netbsd_eabihf), | |
9 | ("i586-unknown-netbsd", i586_unknown_netbsd), | |||
10 | ("i686-unknown-netbsd", i686_unknown_netbsd), | 10 | ("i686-unknown-netbsd", i686_unknown_netbsd), | |
11 | + ("i586-unknown-netbsd", i586_unknown_netbsd), | 11 | + ("mips64el-unknown-netbsd", mips64el_unknown_netbsd), | |
12 | + ("mipsel-unknown-netbsd", mipsel_unknown_netbsd), | 12 | ("mipsel-unknown-netbsd", mipsel_unknown_netbsd), | |
13 | ("powerpc-unknown-netbsd", powerpc_unknown_netbsd), | 13 | ("powerpc-unknown-netbsd", powerpc_unknown_netbsd), | |
14 | ("riscv64gc-unknown-netbsd", riscv64gc_unknown_netbsd), | 14 | ("riscv64gc-unknown-netbsd", riscv64gc_unknown_netbsd), | |
15 | ("sparc64-unknown-netbsd", sparc64_unknown_netbsd), |
$NetBSD: patch-compiler_rustc__target_src_spec_base_netbsd.rs,v 1.1 2024/03/03 14:53:32 he Exp $
For the benefit of powerpc, when libatomic-links is installed,
search the directory containing the symlinks to -latomic.
--- compiler/rustc_target/src/spec/base/netbsd.rs.orig 2024-01-06 19:57:14.887897867 +0000
+++ compiler/rustc_target/src/spec/base/netbsd.rs
@@ -1,12 +1,23 @@
-use crate::spec::{cvs, RelroLevel, TargetOptions};
+use crate::spec::{cvs, Cc, Lld, RelroLevel, LinkerFlavor, TargetOptions};
pub fn opts() -> TargetOptions {
+ let add_linker_paths =
+ &[
+ // For the benefit of powerpc, when libatomic-links is installed,
+ "-Wl,-R@PREFIX@/lib/libatomic",
+ "-Wl,-L@PREFIX@/lib/libatomic",
+ ];
+ let pre_link_args = TargetOptions::link_args(
+ LinkerFlavor::Gnu(Cc::Yes, Lld::No),
+ add_linker_paths
+ );
TargetOptions {
os: "netbsd".into(),
dynamic_linking: true,
families: cvs!["unix"],
no_default_libraries: false,
has_rpath: true,
+ pre_link_args,
position_independent_executables: true,
relro_level: RelroLevel::Full,
use_ctors_section: true,
$NetBSD: patch-compiler_rustc__target_src_spec_targets_mips64el__unknown__netbsd.rs,v 1.1 2024/03/03 14:53:32 he Exp $
Provide a mips64el target with N32, suitable for NetBSD/mips64el.
--- compiler/rustc_target/src/spec/targets/mips64el_unknown_netbsd.rs.orig 2024-01-13 14:16:30.122042614 +0000
+++ compiler/rustc_target/src/spec/targets/mips64el_unknown_netbsd.rs
@@ -0,0 +1,22 @@
+use crate::abi::Endian;
+use crate::spec::{base, Target, TargetOptions};
+
+pub fn target() -> Target {
+ let mut base = base::netbsd::opts();
+ base.max_atomic_width = Some(32);
+ base.cpu = "mips32".into();
+
+ Target {
+ llvm_target: "mipsel-unknown-netbsd".into(),
+ pointer_width: 32,
+ data_layout: "e-m:m-p:32:32-i8:8:32-i16:16:32-i64:64-n32-S64".into(),
+ arch: "mips".into(),
+ options: TargetOptions {
+ abi: "n32".into(),
+ features: "+soft-float,+abi=n32".into(),
+ endian: Endian::Little,
+ mcount: "__mcount".into(),
+ ..base
+ },
+ }
+}
$NetBSD: patch-src_bootstrap_src_core_build__steps_compile.rs,v 1.1 2024/03/03 14:53:32 he Exp $
On Darwin, do not use @rpath for internal libraries.
--- src/bootstrap/src/core/build_steps/compile.rs.orig 2024-01-06 20:42:20.028206400 +0000
+++ src/bootstrap/src/core/build_steps/compile.rs
@@ -626,7 +626,7 @@ fn copy_sanitizers(
|| target == "x86_64-apple-ios"
{
// Update the library’s install name to reflect that it has been renamed.
- apple_darwin_update_library_name(&dst, &format!("@rpath/{}", &runtime.name));
+ apple_darwin_update_library_name(&dst, &format!("@PREFIX@/lib/{}", &runtime.name));
// Upon renaming the install name, the code signature of the file will invalidate,
// so we will sign it again.
apple_darwin_sign_file(&dst);
$NetBSD: patch-src_bootstrap_src_core_builder.rs,v 1.1 2024/03/03 14:53:32 he Exp $
Use @PREFIX@, not $ORIGIN in rpath.
--- src/bootstrap/src/core/builder.rs.orig 2024-01-13 20:06:50.748741545 +0000
+++ src/bootstrap/src/core/builder.rs
@@ -1678,7 +1678,7 @@ impl<'a> Builder<'a> {
&& !target.contains("xous")
{
rustflags.arg("-Clink-args=-Wl,-z,origin");
- Some(format!("-Wl,-rpath,$ORIGIN/../{libdir}"))
+ Some(format!("-Wl,-rpath,@PREFIX@/{libdir}"))
} else {
None
};
$NetBSD: patch-src_bootstrap_src_lib.rs,v 1.1 2024/03/03 14:53:32 he Exp $
Don't filter out optimization flags.
FreeBSD has a particular C++ runtime library name
--- src/bootstrap/src/lib.rs.orig 2024-01-06 20:52:50.892941220 +0000
+++ src/bootstrap/src/lib.rs
@@ -1195,13 +1195,13 @@ impl Build {
.args()
.iter()
.map(|s| s.to_string_lossy().into_owned())
- .filter(|s| !s.starts_with("-O") && !s.starts_with("/O"))
.collect::<Vec<String>>();
// If we're compiling C++ on macOS then we add a flag indicating that
// we want libc++ (more filled out than libstdc++), ensuring that
// LLVM/etc are all properly compiled.
- if matches!(c, CLang::Cxx) && target.contains("apple-darwin") {
+ if matches!(c, CLang::Cxx) &&
+ (target.contains("apple-darwin") || target.contains("freebsd")) {
base.push("-stdlib=libc++".into());
}
$NetBSD: patch-vendor_libc-0.2.148_src_unix_bsd_netbsdlike+netbsd_mips.rs,v 1.1 2024/03/03 14:53:33 he Exp $
Add entry for NetBSD/mips.
--- vendor/libc-0.2.148/src/unix/bsd/netbsdlike/netbsd/mips.rs.orig 2024-01-06 21:03:21.781003759 +0000
+++ vendor/libc-0.2.148/src/unix/bsd/netbsdlike/netbsd/mips.rs 2024-01-06 22:27:31.830676317 +0000
@@ -0,0 +1,22 @@
+use PT_FIRSTMACH;
+
+pub type c_long = i32;
+pub type c_ulong = u32;
+pub type c_char = i8;
+pub type __cpu_simple_lock_nv_t = ::c_int;
+
+// should be pub(crate), but that requires Rust 1.18.0
+cfg_if! {
+ if #[cfg(libc_const_size_of)] {
+ #[doc(hidden)]
+ pub const _ALIGNBYTES: usize = ::mem::size_of::<::c_longlong>() - 1;
+ } else {
+ #[doc(hidden)]
+ pub const _ALIGNBYTES: usize = 8 - 1;
+ }
+}
+
+pub const PT_GETREGS: ::c_int = PT_FIRSTMACH + 1;
+pub const PT_SETREGS: ::c_int = PT_FIRSTMACH + 2;
+pub const PT_GETFPREGS: ::c_int = PT_FIRSTMACH + 3;
+pub const PT_SETFPREGS: ::c_int = PT_FIRSTMACH + 4;
$NetBSD: patch-vendor_libc-0.2.148_src_unix_bsd_netbsdlike_netbsd_mod.rs,v 1.1 2024/03/03 14:53:33 he Exp $
Add entries for execinfo, and support
for NetBSD/mips and NetBSD/riscv64.
--- vendor/libc-0.2.148/src/unix/bsd/netbsdlike/netbsd/mod.rs.orig 2024-01-06 22:33:33.911876204 +0000
+++ vendor/libc-0.2.148/src/unix/bsd/netbsdlike/netbsd/mod.rs
@@ -10,7 +10,7 @@ type __pthread_spin_t = __cpu_simple_loc
pub type vm_size_t = ::uintptr_t; // FIXME: deprecated since long time
pub type lwpid_t = ::c_uint;
pub type shmatt_t = ::c_uint;
-pub type cpuid_t = u64;
+pub type cpuid_t = ::c_ulong;
pub type cpuset_t = _cpuset;
pub type pthread_spin_t = ::c_uchar;
pub type timer_t = ::c_int;
@@ -3153,6 +3153,22 @@ extern "C" {
pub fn kinfo_getvmmap(pid: ::pid_t, cntp: *mut ::size_t) -> *mut kinfo_vmentry;
}
+#[link(name = "execinfo")]
+extern "C" {
+ pub fn backtrace(addrlist: *mut *mut ::c_void, len: ::size_t) -> ::size_t;
+ pub fn backtrace_symbols(addrlist: *const *mut ::c_void, len: ::size_t) -> *mut *mut ::c_char;
+ pub fn backtrace_symbols_fd(
+ addrlist: *const *mut ::c_void,
+ len: ::size_t,
+ fd: ::c_int,
+ ) -> ::c_int;
+ pub fn backtrace_symbols_fmt(
+ addrlist: *const *mut ::c_void,
+ len: ::size_t,
+ fmt: *const ::c_char,
+ ) -> *mut *mut ::c_char;
+}
+
cfg_if! {
if #[cfg(target_arch = "aarch64")] {
mod aarch64;
@@ -3172,6 +3188,12 @@ cfg_if! {
} else if #[cfg(target_arch = "x86")] {
mod x86;
pub use self::x86::*;
+ } else if #[cfg(target_arch = "mips")] {
+ mod mips;
+ pub use self::mips::*;
+ } else if #[cfg(target_arch = "riscv64")] {
+ mod riscv64;
+ pub use self::riscv64::*;
} else {
// Unknown target_arch
}
$NetBSD: patch-vendor_libc-0.2.148_src_unix_bsd_netbsdlike_netbsd_riscv64.rs,v 1.1 2024/03/03 14:53:33 he Exp $
Add support for NetBSD/riscv64.
--- vendor/libc-0.2.148/src/unix/bsd/netbsdlike/netbsd/riscv64.rs.orig 2024-01-06 21:03:21.781003759 +0000
+++ vendor/libc-0.2.148/src/unix/bsd/netbsdlike/netbsd/riscv64.rs 2024-01-06 22:31:25.289387359 +0000
@@ -0,0 +1,22 @@
+use PT_FIRSTMACH;
+
+pub type c_long = i64;
+pub type c_ulong = u64;
+pub type c_char = u8;
+pub type __cpu_simple_lock_nv_t = ::c_int;
+
+// should be pub(crate), but that requires Rust 1.18.0
+cfg_if! {
+ if #[cfg(libc_const_size_of)] {
+ #[doc(hidden)]
+ pub const _ALIGNBYTES: usize = ::mem::size_of::<::c_long>() - 1;
+ } else {
+ #[doc(hidden)]
+ pub const _ALIGNBYTES: usize = 8 - 1;
+ }
+}
+
+pub const PT_GETREGS: ::c_int = PT_FIRSTMACH + 0;
+pub const PT_SETREGS: ::c_int = PT_FIRSTMACH + 1;
+pub const PT_GETFPREGS: ::c_int = PT_FIRSTMACH + 2;
+pub const PT_SETFPREGS: ::c_int = PT_FIRSTMACH + 3;
$NetBSD: patch-vendor_libc-0.2.148_src_unix_solarish_mod.rs,v 1.1 2024/03/03 14:53:33 he Exp $
Fix xattr build.
--- vendor/libc-0.2.148/src/unix/solarish/mod.rs.orig 2024-01-06 22:41:58.182128108 +0000
+++ vendor/libc-0.2.148/src/unix/solarish/mod.rs
@@ -1523,6 +1523,8 @@ pub const EOWNERDEAD: ::c_int = 58;
pub const ENOTRECOVERABLE: ::c_int = 59;
pub const ENOSTR: ::c_int = 60;
pub const ENODATA: ::c_int = 61;
+// This is not supported but is required for xattr
+pub const ENOATTR: ::c_int = ::ENODATA;
pub const ETIME: ::c_int = 62;
pub const ENOSR: ::c_int = 63;
pub const ENONET: ::c_int = 64;
@@ -1,24 +1,25 @@ | @@ -1,24 +1,25 @@ | |||
1 | $NetBSD: patch-library_backtrace_src_symbolize_gimli_elf.rs,v 1.6 2023/10/25 05:50:43 pin Exp $ | 1 | $NetBSD: patch-library_backtrace_src_symbolize_gimli_elf.rs,v 1.7 2024/03/03 14:53:32 he Exp $ | |
2 | 2 | |||
3 | Make NetBSD also find its debug libraries, if present. | 3 | Make NetBSD also find its debug libraries, if present. | |
4 | 4 | |||
5 | --- library/backtrace/src/symbolize/gimli/elf.rs.orig 2022-04-04 09:41:26.000000000 +0000 | 5 | --- library/backtrace/src/symbolize/gimli/elf.rs.orig 2022-04-04 09:41:26.000000000 +0000 | |
6 | +++ library/backtrace/src/symbolize/gimli/elf.rs | 6 | +++ library/backtrace/src/symbolize/gimli/elf.rs | |
7 | @@ -276,11 +276,16 @@ fn decompress_zlib(input: &[u8], output: | 7 | @@ -304,11 +304,17 @@ fn decompress_zlib(input: &[u8], output: | |
8 | } | 8 | } | |
9 | } | 9 | } | |
10 | 10 | |||
11 | +#[cfg(target_os = "netbsd")] | 11 | +#[cfg(target_os = "netbsd")] | |
12 | +const DEBUG_PATH: &[u8] = b"/usr/libdata/debug"; | 12 | +const DEBUG_PATH: &[u8] = b"/usr/libdata/debug"; | |
13 | +#[cfg(not(target_os = "netbsd"))] | 13 | +#[cfg(not(target_os = "netbsd"))] | |
14 | const DEBUG_PATH: &[u8] = b"/usr/lib/debug"; | 14 | const DEBUG_PATH: &[u8] = b"/usr/lib/debug"; | |
15 | 15 | |||
16 | fn debug_path_exists() -> bool { | 16 | fn debug_path_exists() -> bool { | |
17 | cfg_if::cfg_if! { | 17 | cfg_if::cfg_if! { | |
18 | - if #[cfg(any(target_os = "freebsd", target_os = "linux"))] { | 18 | - if #[cfg(any(target_os = "freebsd", target_os = "hurd", target_os = "linux"))] { | |
19 | + if #[cfg(any(target_os = "freebsd", | 19 | + if #[cfg(any(target_os = "freebsd", | |
20 | + target_os = "netbsd", | 20 | + target_os = "netbsd", | |
21 | + target_os = "hurd", | |||
21 | + target_os = "linux"))] { | 22 | + target_os = "linux"))] { | |
22 | use core::sync::atomic::{AtomicU8, Ordering}; | 23 | use core::sync::atomic::{AtomicU8, Ordering}; | |
23 | static DEBUG_PATH_EXISTS: AtomicU8 = AtomicU8::new(0); | 24 | static DEBUG_PATH_EXISTS: AtomicU8 = AtomicU8::new(0); | |
24 | 25 |
@@ -1,17 +1,18 @@ | @@ -1,17 +1,18 @@ | |||
1 | $NetBSD: patch-src_bootstrap_bootstrap.py,v 1.21 2024/01/06 19:00:19 he Exp $ | 1 | $NetBSD: patch-src_bootstrap_bootstrap.py,v 1.22 2024/03/03 14:53:32 he Exp $ | |
2 | 2 | |||
3 | Use `uname -p` on NetBSD, as that is reliable and sensible there. | 3 | Use `uname -p` on NetBSD, as that is reliable and sensible there. | |
4 | Handle earmv[67]hf for NetBSD. | 4 | Handle earmv[67]hf for NetBSD. | |
5 | Also use @PREFIX@ and not $ORIGIN in rpath. | |||
5 | 6 | |||
6 | --- src/bootstrap/bootstrap.py.orig 2023-07-12 03:32:40.000000000 +0000 | 7 | --- src/bootstrap/bootstrap.py.orig 2023-07-12 03:32:40.000000000 +0000 | |
7 | +++ src/bootstrap/bootstrap.py | 8 | +++ src/bootstrap/bootstrap.py | |
8 | @@ -271,6 +271,11 @@ def default_build_triple(verbose): | 9 | @@ -271,6 +271,11 @@ def default_build_triple(verbose): | |
9 | 'GNU': 'unknown-hurd', | 10 | 'GNU': 'unknown-hurd', | |
10 | } | 11 | } | |
11 | 12 | |||
12 | + # For NetBSD, use `uname -p`, as there it is reliable & sensible | 13 | + # For NetBSD, use `uname -p`, as there it is reliable & sensible | |
13 | + if kernel == 'NetBSD': | 14 | + if kernel == 'NetBSD': | |
14 | + cputype = subprocess.check_output( | 15 | + cputype = subprocess.check_output( | |
15 | + ['uname', '-p']).strip().decode(default_encoding) | 16 | + ['uname', '-p']).strip().decode(default_encoding) | |
16 | + | 17 | + | |
17 | # Consider the direct transformation first and then the special cases | 18 | # Consider the direct transformation first and then the special cases | |
@@ -25,13 +26,22 @@ Handle earmv[67]hf for NetBSD. | @@ -25,13 +26,22 @@ Handle earmv[67]hf for NetBSD. | |||
25 | + elif cputype in {'armv6hf', 'earmv6hf'}: | 26 | + elif cputype in {'armv6hf', 'earmv6hf'}: | |
26 | + cputype = 'armv6' | 27 | + cputype = 'armv6' | |
27 | + if kernel == 'unknown-netbsd': | 28 | + if kernel == 'unknown-netbsd': | |
28 | + kernel += '-eabihf' | 29 | + kernel += '-eabihf' | |
29 | + elif cputype in {'armv7l', 'earmv7hf', 'armv8l'}: | 30 | + elif cputype in {'armv7l', 'earmv7hf', 'armv8l'}: | |
30 | cputype = 'armv7' | 31 | cputype = 'armv7' | |
31 | if kernel == 'linux-android': | 32 | if kernel == 'linux-android': | |
32 | kernel = 'linux-androideabi' | 33 | kernel = 'linux-androideabi' | |
33 | + elif kernel == 'unknown-netbsd': | 34 | + elif kernel == 'unknown-netbsd': | |
34 | + kernel += '-eabihf' | 35 | + kernel += '-eabihf' | |
35 | else: | 36 | else: | |
36 | kernel += 'eabihf' | 37 | kernel += 'eabihf' | |
37 | elif cputype == 'mips': | 38 | elif cputype == 'mips': | |
39 | @@ -735,7 +746,7 @@ class RustBuild(object): | |||
40 | rpath_entries = [ | |||
41 | # Relative default, all binary and dynamic libraries we ship | |||
42 | # appear to have this (even when `../lib` is redundant). | |||
43 | - "$ORIGIN/../lib", | |||
44 | + "@PREFIX@/lib", | |||
45 | os.path.join(os.path.realpath(nix_deps_dir), "lib") | |||
46 | ] | |||
47 | patchelf_args = ["--set-rpath", ":".join(rpath_entries)] |
@@ -1,25 +1,25 @@ | @@ -1,25 +1,25 @@ | |||
1 | $NetBSD: patch-src_tools_rust-installer_install-template.sh,v 1.12 2024/01/22 11:00:16 adam Exp $ | 1 | $NetBSD: patch-src_tools_rust-installer_install-template.sh,v 1.13 2024/03/03 14:53:33 he Exp $ | |
2 | 2 | |||
3 | No logging to 'install.log'. | 3 | No logging to 'install.log'. | |
4 | Do not create 'uninstall.sh'. | 4 | Do not create 'uninstall.sh'. | |
5 | Do not make file backups (filename.old), so these will not end up in the final package. | 5 | Do not make file backups (filename.old), so these will not end up in the final package. | |
6 | 6 | |||
7 | Rewrite to not use a whole lot of subprocesses just for doing | 7 | Rewrite to not use a whole lot of subprocesses just for doing | |
8 | pattern matching and substitution in the install phase using "grep" | 8 | pattern matching and substitution in the install phase using "grep" | |
9 | and "sed" when shell builtin "case" and "omit shortest match" ops | 9 | and "sed" when shell builtin "case" and "omit shortest match" ops | |
10 | should do just fine. | 10 | should do just fine. | |
11 | 11 | |||
12 | --- src/tools/rust-installer/install-template.sh.orig 2023-12-04 19:48:34.000000000 +0000 | 12 | --- src/tools/rust-installer/install-template.sh.orig 2023-12-21 16:55:28.000000000 +0000 | |
13 | +++ src/tools/rust-installer/install-template.sh | 13 | +++ src/tools/rust-installer/install-template.sh | |
14 | @@ -6,20 +6,12 @@ set -u | 14 | @@ -6,20 +6,12 @@ set -u | |
15 | init_logging() { | 15 | init_logging() { | |
16 | local _abs_libdir="$1" | 16 | local _abs_libdir="$1" | |
17 | local _logfile="$_abs_libdir/$TEMPLATE_REL_MANIFEST_DIR/install.log" | 17 | local _logfile="$_abs_libdir/$TEMPLATE_REL_MANIFEST_DIR/install.log" | |
18 | - rm -f "$_logfile" | 18 | - rm -f "$_logfile" | |
19 | - need_ok "failed to remove old installation log" | 19 | - need_ok "failed to remove old installation log" | |
20 | - touch "$_logfile" | 20 | - touch "$_logfile" | |
21 | - need_ok "failed to create installation log" | 21 | - need_ok "failed to create installation log" | |
22 | LOGFILE="$_logfile" | 22 | LOGFILE="$_logfile" | |
23 | } | 23 | } | |
24 | 24 | |||
25 | log_line() { | 25 | log_line() { |
@@ -1,30 +1,22 @@ | @@ -1,30 +1,22 @@ | |||
1 | $NetBSD: patch-vendor_target-lexicon_src_targets.rs,v 1.12 2023/10/25 05:50:43 pin Exp $ | 1 | $NetBSD: patch-vendor_target-lexicon_src_targets.rs,v 1.13 2024/03/03 14:53:33 he Exp $ | |
2 | 2 | |||
3 | Add aarch64_eb, mipsel and riscv64gc for NetBSD. | 3 | Add aarch64_eb and mipsel for NetBSD. | |
4 | 4 | |||
5 | --- vendor/target-lexicon/src/targets.rs.orig 2021-05-03 21:35:46.000000000 +0000 | 5 | --- vendor/target-lexicon/src/targets.rs.orig 2021-05-03 21:35:46.000000000 +0000 | |
6 | +++ vendor/target-lexicon/src/targets.rs | 6 | +++ vendor/target-lexicon/src/targets.rs | |
7 | @@ -1357,6 +1357,7 @@ mod tests { | 7 | @@ -1526,6 +1526,7 @@ mod tests { | |
8 | "aarch64-unknown-linux-gnu_ilp32", | 8 | "aarch64-unknown-linux-gnu_ilp32", | |
9 | "aarch64-unknown-linux-musl", | 9 | "aarch64-unknown-linux-musl", | |
10 | "aarch64-unknown-netbsd", | 10 | "aarch64-unknown-netbsd", | |
11 | + "aarch64_be-unknown-netbsd", | 11 | + "aarch64_be-unknown-netbsd", | |
12 | "aarch64-unknown-none", | 12 | "aarch64-unknown-none", | |
13 | "aarch64-unknown-none-softfloat", | 13 | "aarch64-unknown-none-softfloat", | |
14 | "aarch64-unknown-openbsd", | 14 | "aarch64-unknown-openbsd", | |
15 | @@ -1441,6 +1442,7 @@ mod tests { | 15 | @@ -1611,6 +1612,7 @@ mod tests { | |
16 | "mipsel-unknown-linux-gnu", | 16 | "mipsel-unknown-linux-gnu", | |
17 | "mipsel-unknown-linux-musl", | 17 | "mipsel-unknown-linux-musl", | |
18 | "mipsel-unknown-linux-uclibc", | 18 | "mipsel-unknown-linux-uclibc", | |
19 | + "mipsel-unknown-netbsd", | 19 | + "mipsel-unknown-netbsd", | |
20 | "mipsel-unknown-none", | 20 | "mipsel-unknown-none", | |
21 | "mipsisa32r6el-unknown-linux-gnu", | 21 | "mipsisa32r6el-unknown-linux-gnu", | |
22 | "mipsisa32r6-unknown-linux-gnu", | 22 | "mipsisa32r6-unknown-linux-gnu", | |
23 | @@ -1478,6 +1480,7 @@ mod tests { | |||
24 | "riscv64gc-unknown-freebsd", | |||
25 | "riscv64gc-unknown-linux-gnu", | |||
26 | "riscv64gc-unknown-linux-musl", | |||
27 | + "riscv64gc-unknown-netbsd", | |||
28 | "riscv64gc-unknown-none-elf", | |||
29 | "riscv64gc-unknown-openbsd", | |||
30 | "riscv64imac-unknown-none-elf", |
@@ -1,15 +1,15 @@ | @@ -1,15 +1,15 @@ | |||
1 | $NetBSD: patch-vendor_libc_src_unix_solarish_mod.rs,v 1.13 2023/10/25 05:50:43 pin Exp $ | 1 | $NetBSD: patch-vendor_libc_src_unix_solarish_mod.rs,v 1.14 2024/03/03 14:53:33 he Exp $ | |
2 | 2 | |||
3 | Fix xattr build. | 3 | Fix xattr build. | |
4 | 4 | |||
5 | --- vendor/libc/src/unix/solarish/mod.rs.orig 2019-05-20 13:47:24.000000000 +0000 | 5 | --- vendor/libc/src/unix/solarish/mod.rs.orig 2019-05-20 13:47:24.000000000 +0000 | |
6 | +++ vendor/libc/src/unix/solarish/mod.rs | 6 | +++ vendor/libc/src/unix/solarish/mod.rs | |
7 | @@ -1215,6 +1215,8 @@ pub const EOWNERDEAD: ::c_int = 58; | 7 | @@ -1523,6 +1523,8 @@ pub const EOWNERDEAD: ::c_int = 58; | |
8 | pub const ENOTRECOVERABLE: ::c_int = 59; | 8 | pub const ENOTRECOVERABLE: ::c_int = 59; | |
9 | pub const ENOSTR: ::c_int = 60; | 9 | pub const ENOSTR: ::c_int = 60; | |
10 | pub const ENODATA: ::c_int = 61; | 10 | pub const ENODATA: ::c_int = 61; | |
11 | +// This is not supported but is required for xattr | 11 | +// This is not supported but is required for xattr | |
12 | +pub const ENOATTR: ::c_int = ::ENODATA; | 12 | +pub const ENOATTR: ::c_int = ::ENODATA; | |
13 | pub const ETIME: ::c_int = 62; | 13 | pub const ETIME: ::c_int = 62; | |
14 | pub const ENOSR: ::c_int = 63; | 14 | pub const ENOSR: ::c_int = 63; | |
15 | pub const ENONET: ::c_int = 64; | 15 | pub const ENONET: ::c_int = 64; |