| @@ -1,18 +1,19 @@ | | | @@ -1,18 +1,19 @@ |
1 | # $NetBSD: Makefile,v 1.300 2024/01/08 08:16:52 tnn Exp $ | | 1 | # $NetBSD: Makefile,v 1.301 2024/01/13 23:21:58 rillig Exp $ |
2 | | | 2 | |
3 | DISTNAME= rustc-1.74.1-src | | 3 | DISTNAME= rustc-1.74.1-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 |
6 | MASTER_SITES= https://static.rust-lang.org/dist/ | | 7 | MASTER_SITES= https://static.rust-lang.org/dist/ |
7 | | | 8 | |
8 | MAINTAINER= pkgsrc-users@NetBSD.org | | 9 | MAINTAINER= pkgsrc-users@NetBSD.org |
9 | HOMEPAGE= https://www.rust-lang.org/ | | 10 | HOMEPAGE= https://www.rust-lang.org/ |
10 | COMMENT= Safe, concurrent, practical language | | 11 | COMMENT= Safe, concurrent, practical language |
11 | LICENSE= mit OR apache-2.0 | | 12 | LICENSE= mit OR apache-2.0 |
12 | | | 13 | |
13 | CONFLICTS+= rust-bin-[0-9]* | | 14 | CONFLICTS+= rust-bin-[0-9]* |
14 | | | 15 | |
15 | # LLVM uses -std=c++17 | | 16 | # LLVM uses -std=c++17 |
16 | USE_CXX_FEATURES+= c++17 | | 17 | USE_CXX_FEATURES+= c++17 |
17 | | | 18 | |
18 | USE_GCC_RUNTIME= yes | | 19 | USE_GCC_RUNTIME= yes |
| @@ -568,26 +569,31 @@ do-build: | | | @@ -568,26 +569,31 @@ do-build: |
568 | | | 569 | |
569 | do-test: | | 570 | do-test: |
570 | ${RUN}${_ULIMIT_CMD} \ | | 571 | ${RUN}${_ULIMIT_CMD} \ |
571 | cd ${WRKSRC} && \ | | 572 | cd ${WRKSRC} && \ |
572 | ${SETENV} ${MAKE_ENV} \ | | 573 | ${SETENV} ${MAKE_ENV} \ |
573 | ${PYTHONBIN} ./x.py -v test -j ${_MAKE_JOBS_N} | | 574 | ${PYTHONBIN} ./x.py -v test -j ${_MAKE_JOBS_N} |
574 | | | 575 | |
575 | do-install: | | 576 | do-install: |
576 | ${RUN}${_ULIMIT_CMD} \ | | 577 | ${RUN}${_ULIMIT_CMD} \ |
577 | cd ${WRKSRC} && \ | | 578 | cd ${WRKSRC} && \ |
578 | ${SETENV} ${MAKE_ENV} ${INSTALL_ENV} \ | | 579 | ${SETENV} ${MAKE_ENV} ${INSTALL_ENV} \ |
579 | ${PYTHONBIN} ./x.py -v install -j ${_MAKE_JOBS_N} | | 580 | ${PYTHONBIN} ./x.py -v install -j ${_MAKE_JOBS_N} |
580 | | | 581 | |
| | | 582 | SUBST_CLASSES+= destdir |
| | | 583 | SUBST_STAGE.destdir= post-install |
| | | 584 | SUBST_FILES.destdir= ${DESTDIR}${PREFIX}/lib/rustlib/manifest-* |
| | | 585 | SUBST_SED.destdir= -e 's|file:${DESTDIR}${PREFIX}|file:${PREFIX}|' |
| | | 586 | |
581 | GENERATE_PLIST+= ${FIND} ${DESTDIR}${PREFIX} \( -type f -o -type l \) -print | \ | | 587 | GENERATE_PLIST+= ${FIND} ${DESTDIR}${PREFIX} \( -type f -o -type l \) -print | \ |
582 | ${SED} -e 's,${DESTDIR}${PREFIX}/,,' | ${SORT} ; | | 588 | ${SED} -e 's,${DESTDIR}${PREFIX}/,,' | ${SORT} ; |
583 | | | 589 | |
584 | # Create a relocatable stage2 bootstrap from the bits we just built that can be | | 590 | # Create a relocatable stage2 bootstrap from the bits we just built that can be |
585 | # used to build the next version of rust. Currently only tested on SmartOS. | | 591 | # used to build the next version of rust. Currently only tested on SmartOS. |
586 | # | | 592 | # |
587 | # Use the alternate BOOTSTRAP_NAME when creating a nightly release. | | 593 | # Use the alternate BOOTSTRAP_NAME when creating a nightly release. |
588 | # | | 594 | # |
589 | #BOOTSTRAP_NAME= ${PKGNAME_NOREV:C/rust/rust-nightly/}-${RUST_ARCH} | | 595 | #BOOTSTRAP_NAME= ${PKGNAME_NOREV:C/rust/rust-nightly/}-${RUST_ARCH} |
590 | BOOTSTRAP_NAME= ${PKGNAME_NOREV}-${RUST_ARCH} | | 596 | BOOTSTRAP_NAME= ${PKGNAME_NOREV}-${RUST_ARCH} |
591 | BOOTSTRAP_TMPDIR= ${WRKDIR}/${BOOTSTRAP_NAME} | | 597 | BOOTSTRAP_TMPDIR= ${WRKDIR}/${BOOTSTRAP_NAME} |
592 | USE_TOOLS+= gtar | | 598 | USE_TOOLS+= gtar |
593 | | | 599 | |