mirror of
https://github.com/gentoo-mirror/gentoo.git
synced 2026-11-21 22:47:14 -08:00
zig.eclass: prefer source from WORKDIR if it exists
Some dependencies are fetched from Git and can't be in SRC_URI, so we use a vendor "tarball-tarball". However, when the tarball-tarball gets extracted, the resulting deps land in WORKDIR, not DESTDIR, and zig fetch can't find them. Try to see if the dep exists in WORKDIR, and use it if present. Signed-off-by: sin-ack <sin-ack@protonmail.com> Part-of: https://github.com/gentoo/gentoo/pull/47039 Signed-off-by: Sam James <sam@gentoo.org>
This commit is contained in:
+5
-1
@@ -513,7 +513,11 @@ zig_src_unpack() {
|
||||
touch build.zig || die
|
||||
for zig_dep in "${zig_deps[@]}"; do
|
||||
# Hide now-spammy hash from stdout
|
||||
ezig fetch --save-exact="${zig_dep##-*}" "${DISTDIR}/${zig_dep}" > /dev/null
|
||||
if [[ -f "${WORKDIR}/${zig_dep}" ]]; then
|
||||
ezig fetch --save-exact="${zig_dep##-*}" "${WORKDIR}/${zig_dep}" > /dev/null
|
||||
else
|
||||
ezig fetch --save-exact="${zig_dep##-*}" "${DISTDIR}/${zig_dep}" > /dev/null
|
||||
fi
|
||||
done
|
||||
|
||||
# For 0.17 and later:
|
||||
|
||||
Reference in New Issue
Block a user