From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits)) (No client certificate requested) by finch.gentoo.org (Postfix) with ESMTPS id 3B54E158020 for ; Tue, 11 Oct 2022 22:57:01 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 9B7E4E0953; Tue, 11 Oct 2022 22:55:15 +0000 (UTC) Received: from smtp.gentoo.org (dev.gentoo.org [IPv6:2001:470:ea4a:1:5054:ff:fec7:86e4]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits)) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id 658BFE094F for ; Tue, 11 Oct 2022 22:55:15 +0000 (UTC) From: Sam James To: gentoo-dev@lists.gentoo.org Cc: dist-kernel@gentoo.org, kernel@gentoo.org, Sam James Subject: [gentoo-dev] [PATCH 7/8] kernel-build.eclass: use pigz for parallel compression if available Date: Tue, 11 Oct 2022 23:54:43 +0100 Message-Id: <20221011225444.56032-7-sam@gentoo.org> X-Mailer: git-send-email 2.38.0 In-Reply-To: <20221011225444.56032-1-sam@gentoo.org> References: <20221011225444.56032-1-sam@gentoo.org> Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-dev@lists.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 X-Archives-Salt: be7cc754-7c4a-4afe-825b-1ba6599b42e5 X-Archives-Hash: 6beb1376d15443b18f995fa2eaddbf5f Note that this will only take effect if compressing modules with gzip (COMPRESS_MODULE_GZIP is set) or compressing the kernel with gzip (CONFIG_KERNEL_GZIP is set). Signed-off-by: Sam James --- eclass/kernel-build.eclass | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/eclass/kernel-build.eclass b/eclass/kernel-build.eclass index 936258e9e8af..faf36d763d08 100644 --- a/eclass/kernel-build.eclass +++ b/eclass/kernel-build.eclass @@ -98,6 +98,13 @@ kernel-build_src_configure() { export ZSTD_NBTHREADS="$(makeopts_jobs)" fi + # pigz needs to take an argument, not an env var, + # for its options, which won't work because of how the kernel build system + # uses the variables (e.g. passes directly to tar as an executable). + if type -P pigz ; then + MAKEARGS+=( KGZIP="pigz" ) + fi + restore_config .config [[ -f .config ]] || die "Ebuild error: please copy default config into .config" -- 2.38.0