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 D3920159C9C for ; Tue, 6 Aug 2024 08:47:22 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 9089B2BC05F; Tue, 6 Aug 2024 08:47:20 +0000 (UTC) Received: from smtp.gentoo.org (woodpecker.gentoo.org [140.211.166.183]) (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 502C02BC05E for ; Tue, 6 Aug 2024 08:47:20 +0000 (UTC) Received: from oystercatcher.gentoo.org (oystercatcher.gentoo.org [148.251.78.52]) (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 smtp.gentoo.org (Postfix) with ESMTPS id 3303E343005 for ; Tue, 6 Aug 2024 08:47:19 +0000 (UTC) Received: from localhost.localdomain (localhost [IPv6:::1]) by oystercatcher.gentoo.org (Postfix) with ESMTP id 4BEE61EC4 for ; Tue, 6 Aug 2024 08:47:16 +0000 (UTC) From: "Michał Górny" To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Michał Górny" Message-ID: <1722933015.83739e9677a6835c9fa49c0c98e9d7bc1e331413.mgorny@gentoo> Subject: [gentoo-commits] repo/gentoo:master commit in: eclass/ X-VCS-Repository: repo/gentoo X-VCS-Files: eclass/distutils-r1.eclass X-VCS-Directories: eclass/ X-VCS-Committer: mgorny X-VCS-Committer-Name: Michał Górny X-VCS-Revision: 83739e9677a6835c9fa49c0c98e9d7bc1e331413 X-VCS-Branch: master Date: Tue, 6 Aug 2024 08:47:16 +0000 (UTC) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-commits@lists.gentoo.org X-Auto-Response-Suppress: DR, RN, NRN, OOF, AutoReply X-Archives-Salt: af27e7ed-7150-46dc-815d-a6efd6a601d9 X-Archives-Hash: eae6ab2a6a468a5cf609d4b9682eebdd commit: 83739e9677a6835c9fa49c0c98e9d7bc1e331413 Author: James Le Cuirot gentoo org> AuthorDate: Thu Jul 25 21:20:02 2024 +0000 Commit: Michał Górny gentoo org> CommitDate: Tue Aug 6 08:30:15 2024 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=83739e96 distutils-r1.eclass: Support cross-compiling with PyO3 Only one variable needs to be set. For details, see https://pyo3.rs/latest/building-and-distribution.html#cross-compiling. Signed-off-by: James Le Cuirot gentoo.org> Signed-off-by: Michał Górny gentoo.org> Closes: https://github.com/gentoo/gentoo/pull/37708 Signed-off-by: Michał Górny gentoo.org> eclass/distutils-r1.eclass | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/eclass/distutils-r1.eclass b/eclass/distutils-r1.eclass index 129ba21ab0d4..0f9dc8d14d5e 100644 --- a/eclass/distutils-r1.eclass +++ b/eclass/distutils-r1.eclass @@ -1391,6 +1391,11 @@ distutils_pep517_install() { ;; esac + # https://pyo3.rs/latest/building-and-distribution.html#cross-compiling + if tc-is-cross-compiler; then + local -x PYO3_CROSS_LIB_DIR=${SYSROOT}/$(python_get_stdlib) + fi + local build_backend=$(_distutils-r1_get_backend) einfo " Building the wheel for ${PWD#${WORKDIR}/} via ${build_backend}" cmd+=(