Sat Dec 17 21:29:44 2022 UTC ()
rust: Stop xz being buildlinked.

The recent xz update broke the API and rust happened to be using it via other
buildlink3 dependencies, even though we try to use the bundled version.  Set
BUILDLINK_FILES_CMD.xz to ${TRUE} to avoid any xz files from being linked, and
ensuring we use the bundled copy.


(jperkin)
diff -r1.275 -r1.276 pkgsrc/lang/rust/Makefile

cvs diff -r1.275 -r1.276 pkgsrc/lang/rust/Makefile (expand / switch to unified diff)

--- pkgsrc/lang/rust/Makefile 2022/12/05 21:44:58 1.275
+++ pkgsrc/lang/rust/Makefile 2022/12/17 21:29:44 1.276
@@ -1,14 +1,14 @@ @@ -1,14 +1,14 @@
1# $NetBSD: Makefile,v 1.275 2022/12/05 21:44:58 jperkin Exp $ 1# $NetBSD: Makefile,v 1.276 2022/12/17 21:29:44 jperkin Exp $
2 2
3DISTNAME= rustc-1.64.0-src 3DISTNAME= rustc-1.64.0-src
4PKGNAME= ${DISTNAME:S/rustc/rust/:S/-src//} 4PKGNAME= ${DISTNAME:S/rustc/rust/:S/-src//}
5CATEGORIES= lang 5CATEGORIES= lang
6MASTER_SITES= https://static.rust-lang.org/dist/ 6MASTER_SITES= https://static.rust-lang.org/dist/
7 7
8MAINTAINER= pkgsrc-users@NetBSD.org 8MAINTAINER= pkgsrc-users@NetBSD.org
9HOMEPAGE= https://www.rust-lang.org/ 9HOMEPAGE= https://www.rust-lang.org/
10COMMENT= Safe, concurrent, practical language 10COMMENT= Safe, concurrent, practical language
11LICENSE= mit OR apache-2.0 11LICENSE= mit OR apache-2.0
12 12
13CONFLICTS+= rust-bin-[0-9]* rust-src-[0-9]* rust-analyzer-[0-9]* 13CONFLICTS+= rust-bin-[0-9]* rust-src-[0-9]* rust-analyzer-[0-9]*
14 14
@@ -54,27 +54,29 @@ CONFIGURE_ARGS+= ${ADD_CONFIGURE_ARGS} @@ -54,27 +54,29 @@ CONFIGURE_ARGS+= ${ADD_CONFIGURE_ARGS}
54 54
55# Getting RPATH with $ORIGIN into bootstrap may be troublesome, so 55# Getting RPATH with $ORIGIN into bootstrap may be troublesome, so
56# uncommenting the LD_LIBRARY_PATH setting may be required to run 56# uncommenting the LD_LIBRARY_PATH setting may be required to run
57# the bootstrap 57# the bootstrap
58PKGSRC_MAKE_ENV+= LD_LIBRARY_PATH=${RUST_BOOTSTRAP_PATH:Q}/lib 58PKGSRC_MAKE_ENV+= LD_LIBRARY_PATH=${RUST_BOOTSTRAP_PATH:Q}/lib
59 59
60# This should allow us to perform "offline" builds (so cargo doesn't fetch 60# This should allow us to perform "offline" builds (so cargo doesn't fetch
61# dependencies during the build stage) but this isn't hooked up yet. 61# dependencies during the build stage) but this isn't hooked up yet.
62CONFIGURE_ARGS+= --enable-vendor 62CONFIGURE_ARGS+= --enable-vendor
63 63
64# cargo defaults to using the number of available CPUs 64# cargo defaults to using the number of available CPUs
65MAKE_ENV+= CARGO_BUILD_JOBS=${_MAKE_JOBS_N} 65MAKE_ENV+= CARGO_BUILD_JOBS=${_MAKE_JOBS_N}
66 66
67# Ensure we use a bundled lzma rather than relying on finding one. 67# Ensure we use a bundled lzma rather than relying on finding one, and avoid
 68# xz being buildlinked if it's pulled in via dependencies.
 69BUILDLINK_FILES_CMD.xz= ${TRUE}
68MAKE_ENV+= LZMA_API_STATIC=1 70MAKE_ENV+= LZMA_API_STATIC=1
69 71
70# MacOS X 10.7 is the oldest supported version. See 72# MacOS X 10.7 is the oldest supported version. See
71# ${WRKSRC}/src/bootstrap/lib.rs 73# ${WRKSRC}/src/bootstrap/lib.rs
72MAKE_ENV.Darwin+= MACOSX_DEPLOYMENT_TARGET="10.7" 74MAKE_ENV.Darwin+= MACOSX_DEPLOYMENT_TARGET="10.7"
73 75
74CFLAGS.SunOS+= -D_POSIX_PTHREAD_SEMANTICS 76CFLAGS.SunOS+= -D_POSIX_PTHREAD_SEMANTICS
75MAKE_ENV.SunOS+= AR=gar 77MAKE_ENV.SunOS+= AR=gar
76 78
77UNLIMIT_RESOURCES+= cputime stacksize datasize virtualsize 79UNLIMIT_RESOURCES+= cputime stacksize datasize virtualsize
78 80
79TEST_TARGET= check 81TEST_TARGET= check
80 82