From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp10.migadu.com ([2001:41d0:2:bcc0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms5.migadu.com with LMTPS id YG2IE54DkGOzXgAAbAwnHQ (envelope-from ) for ; Wed, 07 Dec 2022 04:08:14 +0100 Received: from aspmx1.migadu.com ([2001:41d0:2:bcc0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp10.migadu.com with LMTPS id cAWREp4DkGN7+gAAG6o9tA (envelope-from ) for ; Wed, 07 Dec 2022 04:08:14 +0100 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id C5ECB47A4B for ; Wed, 7 Dec 2022 04:08:13 +0100 (CET) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1p2kmx-0004RJ-OL; Tue, 06 Dec 2022 22:08:03 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1p2kmw-0004Qv-I9 for bug-guix@gnu.org; Tue, 06 Dec 2022 22:08:02 -0500 Received: from debbugs.gnu.org ([209.51.188.43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1p2kmw-0003sG-AO for bug-guix@gnu.org; Tue, 06 Dec 2022 22:08:02 -0500 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1p2kmv-0003do-Mb for bug-guix@gnu.org; Tue, 06 Dec 2022 22:08:01 -0500 X-Loop: help-debbugs@gnu.org Subject: bug#44924: [PATCH v2 core-updates] build: gnu-build-system: Remove source from native inputs. Resent-From: Maxim Cournoyer Original-Sender: "Debbugs-submit" Resent-CC: bug-guix@gnu.org Resent-Date: Wed, 07 Dec 2022 03:08:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 44924 X-GNU-PR-Package: guix X-GNU-PR-Keywords: To: =?UTF-8?Q?=E5=AE=8B=E6=96=87=E6=AD=A6?= Cc: 44924@debbugs.gnu.org, GNU Debbugs , Ludovic =?UTF-8?Q?Court=C3=A8s?= Received: via spool by 44924-submit@debbugs.gnu.org id=B44924.167038244513982 (code B ref 44924); Wed, 07 Dec 2022 03:08:01 +0000 Received: (at 44924) by debbugs.gnu.org; 7 Dec 2022 03:07:25 +0000 Received: from localhost ([127.0.0.1]:46794 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1p2kmL-0003dR-Bf for submit@debbugs.gnu.org; Tue, 06 Dec 2022 22:07:25 -0500 Received: from mail-qt1-f170.google.com ([209.85.160.170]:41823) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1p2kmI-0003dI-PG; Tue, 06 Dec 2022 22:07:23 -0500 Received: by mail-qt1-f170.google.com with SMTP id c15so15320289qtw.8; Tue, 06 Dec 2022 19:07:22 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=mime-version:user-agent:message-id:in-reply-to:date:references :subject:cc:to:from:from:to:cc:subject:date:message-id:reply-to; bh=YWAe3HBcptUTV083l66ZXQ4vx5fZSj1SFLR+aAI/nFg=; b=EFC1+K+zHRuQkaFFp48MZ1OMgCUFg+IGGF4gZ8V/72Qpaxm1t4rELlu6KMZ+4jfc3V 59z/lojxgknWnSKc4wVfqxvI8V7zXnCa3R/Y9QYIBDMeBjdnBPoShnRk4hE1Il9eFzLh NspneE2y6XGkyz3qw6O2hyDlKXnzjyjbBQ3V+dmYG2gzXYINbkpI0hr6uytfH5vt+lFG agICi/Z8v+9E/8q2q33FHz1pDZpSHBAU9r1k40ZllENSLhqzGhIqDKSU3RNc0GwB+rI1 Y/Fo3s+E/AIuSO1V0LLdyv1iKJv2sS9M4HHMzZZw9aKEIqfnPMmwJpU1/TK2bcYNNWpD UJOA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=mime-version:user-agent:message-id:in-reply-to:date:references :subject:cc:to:from:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=YWAe3HBcptUTV083l66ZXQ4vx5fZSj1SFLR+aAI/nFg=; b=NUZFD+a3JVL/KCRqFpMWzVwxt6pEP7Q8PlmqC6m6qpCMQksJgb25NPkDjBNEWvIHYs iRNsJkMi85MBfoUTyAjMXOfZjbGGHSFDkW0z7sqSqUlkBfaMYn0VjpGz5bgJSqKzPFqR VzjFfAOvgBwyd7rBvTLRO5bPECp6GBgVEnwxA0AFSTvjq2xeeNcM6YetSMYk78Lm6gBd sedjiVmQM4epVQ4Fc7c5Tzj2Cdt6seO6G7+jFRptnNMXqkm2l6g7+iaFESrrFimpjH6d mZwGm+lZA1PP1/UquU4D28CTdKDx5Vy+Nt8pJn++vv9R5uHMGNCOmfmumnB+2zXX2aB8 4Ftw== X-Gm-Message-State: ANoB5pnpp3Dr3Kyzsjoj+JiCRNHecHSsVqvxz7hsgSJBuo6T3L3015rf LmxudQydfBWwhqVliV9OIS0= X-Google-Smtp-Source: AA0mqf504YYZgfm3j8jNf154NI4J9G7WSNzs5AmTz/+RO2Sm2fMcd9Zk0GVccfTkPorvoO94Rp/zEw== X-Received: by 2002:ac8:478c:0:b0:3a5:7262:4836 with SMTP id k12-20020ac8478c000000b003a572624836mr682245qtq.42.1670382437334; Tue, 06 Dec 2022 19:07:17 -0800 (PST) Received: from hurd (dsl-205-233-124-140.b2b2c.ca. [205.233.124.140]) by smtp.gmail.com with ESMTPSA id he33-20020a05622a602100b0039c7b9522ecsm12470508qtb.35.2022.12.06.19.07.15 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 06 Dec 2022 19:07:16 -0800 (PST) From: Maxim Cournoyer References: <87mtyuddyc.fsf@gnu.org> <874ju89edb.fsf@gmail.com> Date: Tue, 06 Dec 2022 22:07:15 -0500 In-Reply-To: <874ju89edb.fsf@gmail.com> (Maxim Cournoyer's message of "Tue, 06 Dec 2022 20:44:32 -0500") Message-ID: <87zgbz9ajg.fsf_-_@gmail.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.2 (gnu/linux) MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: bug-guix@gnu.org List-Id: Bug reports for GNU Guix List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-guix-bounces+larch=yhetil.org@gnu.org Sender: bug-guix-bounces+larch=yhetil.org@gnu.org X-Migadu-Flow: FLOW_IN X-Migadu-Country: US ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1670382494; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type:resent-cc:resent-from:resent-sender: resent-message-id:in-reply-to:in-reply-to:references:references: list-id:list-help:list-unsubscribe:list-subscribe:list-post: dkim-signature; bh=YWAe3HBcptUTV083l66ZXQ4vx5fZSj1SFLR+aAI/nFg=; b=pUomcOEZjNym/AcOqoeAZ7hVbFjOOp/mGJhoDGqV3xH178xULE5ofWwks+mIi1i/lWtZ3C bvN4fQYSVgaV+vFuluihmFdW6SnVI8d0BjF+INvtnJR4hQTwbTCStDyB5/gVzzBqR1pztp yCe1t/mWoVfx/LvsX4fzTqMmUQnARpHPWkTW1OqyCqziPSAqx7nBzDOsWYSg0ZWOYf0G65 I0WyWSAyvoQ3o/dhSO7bcOB7Bf1qyHOpr+qpMV50LLLPMybjT/wFFIU7vR9PUKNt0RJTda 81kHwRqFUGOf3ZoHr83+q+oMvVO83JHvJ/R3ROpXEs0wp+v4GRPEPFt3y/KF3Q== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1670382494; a=rsa-sha256; cv=none; b=BQPye1k0KGjnBn8KxNFtQyKceLd54pIxh6rdB2yEa5X2kq7Tl0yGcgO1Y7ttVDPdwpesCh SWRJeQM7AqReoj78U2r8x3CGvFND6wPXVZUAUmSw5oO7DU15JlMyhYzxU3VXFxv/eKvU79 INPd/r5RqKpFC+9IUz3F/H4n4tsism2H9DnTcd23+p0ZD8273hrZXzr1iqerphk7Ts7k+C /6LCWY3dU9va5yb5opEIG2OJldAmQTrnLoyRMwel+loVR93QI9FS2w8Ca8Jibzrg5z7Kzr d7EKav3NpV71slhwucZzzymekRMtX8XCHqurDaXvnvzdlmi0JKJtIGUG9O1uPw== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=gmail.com header.s=20210112 header.b=EFC1+K+z; dmarc=fail reason="SPF not aligned (relaxed)" header.from=gmail.com (policy=none); spf=pass (aspmx1.migadu.com: domain of "bug-guix-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="bug-guix-bounces+larch=yhetil.org@gnu.org" X-Migadu-Spam-Score: 6.03 Authentication-Results: aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=gmail.com header.s=20210112 header.b=EFC1+K+z; dmarc=fail reason="SPF not aligned (relaxed)" header.from=gmail.com (policy=none); spf=pass (aspmx1.migadu.com: domain of "bug-guix-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="bug-guix-bounces+larch=yhetil.org@gnu.org" X-Migadu-Queue-Id: C5ECB47A4B X-Spam-Score: 6.03 X-Migadu-Scanner: scn1.migadu.com X-TUID: MqRAeqoEhF/c --=-=-= Content-Type: text/plain Hi again, Here's a v2, which guards against a #f native-inputs (when no cross-compiling). --=-=-= Content-Type: text/x-patch Content-Disposition: attachment; filename=0001-build-gnu-build-system-Remove-source-from-native-inp.patch >From 8d2f8fafb66288969f41fcab7705de65f6d09432 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Tue, 6 Dec 2022 20:44:54 -0500 Subject: [PATCH] build: gnu-build-system: Remove source from native inputs. Fixes , in a cross-compilation context. Having the source in inputs when computing search paths can break builds. One example is a git checkout of the Linux source tree, where the source (a directory) 'include' subdirectory gets picked up in C_INCLUDE_PATH and causes conflicts with the includes provided by glibc. * guix/build/gnu-build-system2.scm (set-paths): Remove any "source" native input. --- guix/build/gnu-build-system2.scm | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/guix/build/gnu-build-system2.scm b/guix/build/gnu-build-system2.scm index 54129549c2..1766f9d474 100644 --- a/guix/build/gnu-build-system2.scm +++ b/guix/build/gnu-build-system2.scm @@ -83,10 +83,12 @@ (define input-directories dir))) (define native-input-directories - (match native-inputs + ;; When cross-compiling, the source appears in native-inputs rather than + ;; inputs. + (match (and=> native-inputs (cut alist-delete "source" <>)) (((_ . dir) ...) dir) - (#f ; not cross compiling + (#f ;not cross-compiling '()))) ;; Tell 'ld-wrapper' to disallow non-store libraries. base-commit: b94724e8b2102be0fe9d19e9dfe44d6f7101bd4b prerequisite-patch-id: ef7cada25908a9dec368cede7033b0fe6869ac97 prerequisite-patch-id: 660177fb9eee55d11983ea9360c072730d0d21a5 prerequisite-patch-id: 3af7d5aabc4b70d4709fcb150f072ae1ff16a859 prerequisite-patch-id: fd4074fb4cf068ccac3122c19138f098a610542a prerequisite-patch-id: 51cecbabc04c69d4338addaece536c42a075660f prerequisite-patch-id: 98e04821d56efe50aeb9bdcf640c25bebc2823c6 prerequisite-patch-id: b9b6f21a2db3f7a5ef82bb11ed23f69749cc6b3d prerequisite-patch-id: 2c67bfd85b343a65440e6c63451e5417129dea6f prerequisite-patch-id: a4a0de47739cb0fa71f5c3fd60ba31164a631812 prerequisite-patch-id: cc499b2ffd8c21315cd3760ed4107afc25b3f632 -- 2.38.1 --=-=-= Content-Type: text/plain -- Thanks, Maxim --=-=-=--