[continued from previous message]
-# Also installs documentation via "einstalldocs".
+# Calls "ezig build install" with DESTDIR and previously set ZBS_ARGS.
+# Args passed to this function will be passed after ZBS_ARGS.
+# Also installs documentation via "einstalldocs".
zig-build_src_install() {
pushd "${BUILD_DIR}" > /dev/null || die
- DESTDIR="${D}" ezig build install "${ZBS_ARGS[@]}" "${@}" || die "ZBS: installing failed"
+ local args=( "${ZBS_ARGS[@]}" "${@}" )
+ DESTDIR="${D}" nonfatal ezig build install "${args[@]}" \
+ || die "ZBS: installing failed"
popd > /dev/null || die
pushd "${S}" > /dev/null || die
einstalldocs
popd > /dev/null || die
}
fi
if [[ ! ${ZIG_OPTIONAL} ]]; then
EXPORT_FUNCTIONS pkg_setup src_unpack src_prepare src_configure src_compile src_test src_install
fi
diff --git a/eclass/zig-toolchain.eclass b/eclass/zig-toolchain.eclass
index 6297c9fc9cdd..42a3f8ec3706 100644
--- a/eclass/zig-toolchain.eclass
+++ b/eclass/zig-toolchain.eclass
@@ -1,336 +1,375 @@
# Copyright 2024 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
# @ECLASS: zig-toolchain.eclass
# @MAINTAINER:
# Eric Joldasov <
bratishkaerik@landless-city.net>
# @AUTHOR:
# Eric Joldasov <
bratishkaerik@landless-city.net>
# @SUPPORTED_EAPIS: 8
-# @BLURB: Prepare Zig toolchain and set environment variables.
+# @BLURB: Prepare Zig toolchain and set environment variables
# @DESCRIPTION:
-# Prepare Zig toolchain and set environment variables. Supports Zig 0.13+.
+# Prepare Zig toolchain and set environment variables.
+# Supports Zig 0.13+.
# Does not set any default function, ebuilds must call them manually.
# Generally, only "zig-toolchain_populate_env_vars" is needed.
#
# Intended to be used by ebuilds that call "zig build-exe/lib/obj"
# or "zig test" directly and by "dev-lang/zig".
# For ebuilds with ZBS (Zig Build System), it's usually better
# to