pkgsrc-WIP-changes archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

rust-src: drop the three .orig files we would install.



Module Name:	pkgsrc-wip
Committed By:	Havard Eidnes <he%NetBSD.org@localhost>
Pushed By:	he
Date:		Sat Nov 27 22:22:34 2021 +0100
Changeset:	8b2c3ec62e632c91a3e1843e766ce608196e5673

Modified Files:
	rust-src/Makefile
	rust-src/PLIST

Log Message:
rust-src: drop the three .orig files we would install.

...because they were patched in the main rust package.
Also remove the entries from the manifest.

Easier to do it here than in the main rust package...

To see a diff of this commit:
https://wip.pkgsrc.org/cgi-bin/gitweb.cgi?p=pkgsrc-wip.git;a=commitdiff;h=8b2c3ec62e632c91a3e1843e766ce608196e5673

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

diffstat:
 rust-src/Makefile | 21 +++++++++++++++++----
 rust-src/PLIST    |  3 ---
 2 files changed, 17 insertions(+), 7 deletions(-)

diffs:
diff --git a/rust-src/Makefile b/rust-src/Makefile
index 6c88ee1ac0..95a0bec591 100644
--- a/rust-src/Makefile
+++ b/rust-src/Makefile
@@ -11,7 +11,8 @@ LICENSE=	mit OR apache-2.0
 
 USE_TOOLS+=	bash sh
 
-SRCLIB=			rust-src/lib/rustlib/src/rust/library
+LIBDIR=			lib/rustlib/src/rust/library
+SRCLIB=			rust-src/${LIBDIR}
 REPLACE_BASH+=		install.sh
 REPLACE_BASH+=		${SRCLIB}/backtrace/ci/debuglink.sh
 REPLACE_BASH+=		${SRCLIB}/stdarch/ci/dox.sh
@@ -28,6 +29,12 @@ NO_INTERPRETER+=	${SRCLIB}/backtrace/ci/debuglink-docker.sh
 NO_INTERPRETER+=	${SRCLIB}/backtrace/ci/miri-rustup.sh
 NO_INTERPRETER+=	${SRCLIB}/backtrace/ci/run-docker.sh
 
+ORIG_FILES+=		${LIBDIR}/std/src/sys/unix/mod.rs.orig
+ORIG_FILES+=		${LIBDIR}/std/src/sys/unix/thread.rs.orig
+ORIG_FILES+=		${LIBDIR}/unwind/build.rs.orig
+
+MANIFEST=		${DESTDIR}${PREFIX}/lib/rustlib/manifest-rust-src
+MANIFEST_SRC=		rust-src/manifest.in
 
 do-build:
 	# These do not have an interpreter line...
@@ -38,6 +45,12 @@ do-install:
 	set -e; \
 	\
 	cd ${WRKSRC}; \
+	set -e; \
+	for f in ${ORIG_FILES}; do \
+		rm rust-src/$$f; \
+		grep -v $$f <${MANIFEST_SRC} > ${MANIFEST_SRC}.new; \
+		mv ${MANIFEST_SRC}.new ${MANIFEST_SRC}; \
+	done; \
 	env ${MAKE_ENV} \
 		${TOOLS_BASH} \
 		./install.sh --prefix=${DESTDIR}/${PREFIX};
@@ -45,9 +58,9 @@ do-install:
 	rm -f ${DESTDIR}/${PREFIX}/lib/rustlib/components;
 	rm -f ${DESTDIR}/${PREFIX}/lib/rustlib/rust-installer-version;
 	# fix up install manifest, remove staging ${DESTDIR}
-	MANIFEST=${DESTDIR}${PREFIX}/lib/rustlib/manifest-rust-src; \
-	${SED} -e 's;file:${DESTDIR};file:;' < $${MANIFEST} > $${MANIFEST}.new; \
-	mv $${MANIFEST}.new $${MANIFEST}
+	${SED} -e 's;file:${DESTDIR};file:;' \
+		< ${MANIFEST} > ${MANIFEST}.new; \
+	mv ${MANIFEST}.new ${MANIFEST}
 
 .include "../../lang/python/application.mk"
 .include "../../mk/bsd.pkg.mk"
diff --git a/rust-src/PLIST b/rust-src/PLIST
index c66ad6b83a..8f81b68140 100644
--- a/rust-src/PLIST
+++ b/rust-src/PLIST
@@ -806,7 +806,6 @@ lib/rustlib/src/rust/library/std/src/sys/unix/kernel_copy/tests.rs
 lib/rustlib/src/rust/library/std/src/sys/unix/l4re.rs
 lib/rustlib/src/rust/library/std/src/sys/unix/memchr.rs
 lib/rustlib/src/rust/library/std/src/sys/unix/mod.rs
-lib/rustlib/src/rust/library/std/src/sys/unix/mod.rs.orig
 lib/rustlib/src/rust/library/std/src/sys/unix/mutex.rs
 lib/rustlib/src/rust/library/std/src/sys/unix/net.rs
 lib/rustlib/src/rust/library/std/src/sys/unix/os.rs
@@ -829,7 +828,6 @@ lib/rustlib/src/rust/library/std/src/sys/unix/rwlock.rs
 lib/rustlib/src/rust/library/std/src/sys/unix/stack_overflow.rs
 lib/rustlib/src/rust/library/std/src/sys/unix/stdio.rs
 lib/rustlib/src/rust/library/std/src/sys/unix/thread.rs
-lib/rustlib/src/rust/library/std/src/sys/unix/thread.rs.orig
 lib/rustlib/src/rust/library/std/src/sys/unix/thread_local_dtor.rs
 lib/rustlib/src/rust/library/std/src/sys/unix/thread_local_key.rs
 lib/rustlib/src/rust/library/std/src/sys/unix/time.rs
@@ -1213,7 +1211,6 @@ lib/rustlib/src/rust/library/test/src/time.rs
 lib/rustlib/src/rust/library/test/src/types.rs
 lib/rustlib/src/rust/library/unwind/Cargo.toml
 lib/rustlib/src/rust/library/unwind/build.rs
-lib/rustlib/src/rust/library/unwind/build.rs.orig
 lib/rustlib/src/rust/library/unwind/src/lib.rs
 lib/rustlib/src/rust/library/unwind/src/libunwind.rs
 lib/rustlib/src/rust/src/llvm-project/libunwind/.clang-format


Home | Main Index | Thread Index | Old Index