commit:     0831622e109dde6f781219c904f7b275c1b8877f
Author:     Sam James <sam <AT> gentoo <DOT> org>
AuthorDate: Sat May  4 08:39:43 2024 +0000
Commit:     Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Fri May 10 17:27:03 2024 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=0831622e

perl-module.eclass: respect toolchain variables for Module::Build via --config 
...

Based off 
https://github.com/Perl-Toolchain-Gang/Module-Build/blob/a2ecdf98c25af7dfc7070280232513e8ccec4986/lib/Module/Build/Cookbook.pm#L63.

Bug: https://bugs.gentoo.org/261375
Signed-off-by: Sam James <sam <AT> gentoo.org>

 eclass/perl-module.eclass | 11 ++++++++++-
 1 file changed, 10 insertions(+), 1 deletion(-)

diff --git a/eclass/perl-module.eclass b/eclass/perl-module.eclass
index 029fc78e4a85..fd1af4f945b1 100644
--- a/eclass/perl-module.eclass
+++ b/eclass/perl-module.eclass
@@ -1,4 +1,4 @@
-# Copyright 1999-2023 Gentoo Authors
+# Copyright 1999-2024 Gentoo Authors
 # Distributed under the terms of the GNU General Public License v2
 
 # @ECLASS: perl-module.eclass
@@ -274,6 +274,15 @@ perl-module_src_configure() {
                        --libdoc= \
                        --destdir="${D}" \
                        --create_packlist=1 \
+                       --config ar="$(tc-getAR)" \
+                       --config cc="$(tc-getCC)" \
+                       --config ld="$(tc-getCC)" \
+                       --config cpp="$(tc-getCPP)" \
+                       --config nm="$(tc-getNM)" \
+                       --config ranlib="$(tc-getRANLIB)" \
+                       --config ccflags="${CFLAGS}" \
+                       --config optimize="${CFLAGS}" \
+                       --config ldflags="${LDFLAGS}" \
                        "${myconf_local[@]}"
                einfo "perl Build.PL" "$@"
                perl Build.PL "$@" <<< "${pm_echovar}" \

Reply via email to