🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: linux.gentoo.dev
Article #100

[gentoo-dev] [PATCH 1/4] cargo.eclass: cargo_live_src_unpack don't cd to ${S}

#100
From: kangie
Date: Thu, 05 Nov 2026 07:00
34 lines
2270 bytes
From: Matt Jolly <kangie@gentoo.org>

Changing directory to ${S} inside this function means that Rust sources in
subdirectories are unable to fetch their dependencies.

Signed-off-by: Matt Jolly <kangie@gentoo.org>
---
 eclass/cargo.eclass | 4 ----
 1 file changed, 4 deletions(-)

diff --git a/eclass/cargo.eclass b/eclass/cargo.eclass
index c6415e4f1484..863e37a4dda3 100644
--- a/eclass/cargo.eclass
+++ b/eclass/cargo.eclass
@@ -637,8 +637,6 @@ cargo_live_src_unpack() {
 		umask "${EVCS_UMASK}" || die "Bad options to umask: ${EVCS_UMASK}"
 	fi
 
-	pushd "${S}" > /dev/null || die
-
 	# Respect user settings before cargo_gen_config is called.
 	if [[ ! ${CARGO_TERM_COLOR} ]]; then
 		[[ "${NOCOLOR}" = true || "${NOCOLOR}" = yes ]] && export CARGO_TERM_COLOR=never
@@ -669,8 +667,6 @@ cargo_live_src_unpack() {
 		ln -sv "${ECARGO_REGISTRY_DIR}/git" "${ECARGO_HOME}/git" || die
 	fi
 
-	popd > /dev/null || die
-
 	# Restore settings if needed.
 	[[ ${unset_color} ]] && unset CARGO_TERM_COLOR
 	[[ ${unset_verbose} ]] && unset CARGO_TERM_VERBOSE
-- 
2.56.0
Technical Details
Message-ID: <NVZC2-9WC8-15@gated-at.bofh.it>
Path: mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!usenet.blueworldhosting.com!diablo1.usenet.blueworldhosting.com!2.eu.feeder.erje.net!feeder.erje.net!fu-berlin.de!bofh.it!news.nic.it!robomod
References: <NVZC2-9WC8-3@gated-at.bofh.it>

Show Full Headers
Complete Article Headers
Path: mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!usenet.blueworldhosting.com!diablo1.usenet.blueworldhosting.com!2.eu.feeder.erje.net!feeder.erje.net!fu-berlin.de!bofh.it!news.nic.it!robomod
From: kangie@gentoo.org
Newsgroups: linux.gentoo.dev
Subject: [gentoo-dev] [PATCH 1/4] cargo.eclass: cargo_live_src_unpack don't cd to ${S}
Date: Thu, 05 Nov 2026 08:00:02 +0100
Message-ID: <NVZC2-9WC8-15@gated-at.bofh.it>
References: <NVZC2-9WC8-3@gated-at.bofh.it>
X-Original-To: gentoo-dev@lists.gentoo.org
X-Mailer: git-send-email 2.56.0
List-ID: Gentoo Linux mail <gentoo-dev.gentoo.org>
Reply-To: gentoo-dev@lists.gentoo.org
X-Auto-Response-Suppress: DR, RN, NRN, OOF, AutoReply
MIME-Version: 1.0
Content-Transfer-Encoding: 8bit
Approved: robomod@news.nic.it
Lines: 34
Organization: linux.* mail to news gateway
Sender: robomod@news.nic.it
X-Original-Cc: rust@gentoo.org,
	Matt Jolly <kangie@gentoo.org>
X-Original-Date: Thu,  5 Nov 2026 16:51:48 +1000
X-Original-Message-ID: <20261105065151.1114836-2-kangie@gentoo.org>
X-Original-References: <20261105065151.1114836-1-kangie@gentoo.org>