From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp12.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 BU8wCZKTmmPiYQEAbAwnHQ (envelope-from ) for ; Thu, 15 Dec 2022 04:25:06 +0100 Received: from aspmx1.migadu.com ([2001:41d0:2:bcc0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp12.migadu.com with LMTPS id eNpPCJKTmmPCAAAAauVa8A (envelope-from ) for ; Thu, 15 Dec 2022 04:25:06 +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 DD5F9367FF for ; Thu, 15 Dec 2022 04:25:05 +0100 (CET) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1p5eqt-00037p-Hz; Wed, 14 Dec 2022 22:24:07 -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 1p5eqq-00035c-0f for bug-guix@gnu.org; Wed, 14 Dec 2022 22:24:04 -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 1p5eqo-00024i-Q6; Wed, 14 Dec 2022 22:24:02 -0500 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1p5eqo-0004pX-G5; Wed, 14 Dec 2022 22:24:02 -0500 X-Loop: help-debbugs@gnu.org Subject: bug#60056: [PATCH RFC 2/6] build: gnu-build-system2: Remove source from native inputs. Resent-From: Maxim Cournoyer Original-Sender: "Debbugs-submit" Resent-CC: ludo@gnu.org, bug-guix@gnu.org Resent-Date: Thu, 15 Dec 2022 03:24:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 60056 X-GNU-PR-Package: guix X-GNU-PR-Keywords: To: 60056@debbugs.gnu.org Cc: Maxim Cournoyer , ludo@gnu.org X-Debbugs-Original-Xcc: ludo@gnu.org Received: via spool by 60056-submit@debbugs.gnu.org id=B60056.167107463018502 (code B ref 60056); Thu, 15 Dec 2022 03:24:02 +0000 Received: (at 60056) by debbugs.gnu.org; 15 Dec 2022 03:23:50 +0000 Received: from localhost ([127.0.0.1]:42267 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1p5eqb-0004oM-TS for submit@debbugs.gnu.org; Wed, 14 Dec 2022 22:23:50 -0500 Received: from mail-qt1-f181.google.com ([209.85.160.181]:34809) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1p5eqZ-0004nz-Cf for 60056@debbugs.gnu.org; Wed, 14 Dec 2022 22:23:49 -0500 Received: by mail-qt1-f181.google.com with SMTP id g7so4252078qts.1 for <60056@debbugs.gnu.org>; Wed, 14 Dec 2022 19:23:47 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=metnnJZ3mZMf4C0ObVj11/9ywr2GaxY6djbjEG9BLBI=; b=a2NFPPx4MNw9WM/6SIii+WiJ30i05DtzYs1QX52yCfSSS0XuN9ZSJfK8TBFTCfniRV pK1/DxVSyJfwqW6V6BcSuXHDw9+XTLOOZrBmp/i52aV2YROQ/yPiqnANrdpYy5OoiaBk lLaQwNeLChnhQPOAo4yz9hI2gFUWPF9yq5qJpSPdWyYVgwAaEEasP7n8ROxMCPyX+/v1 zvGmFwy3gD4QGHrS2l09JFlwAMqtxLF20l3l342PbdzQXA0h70/s1Lrlk3Wf41Ue8DVG XdTUNZ+wk0JNmDCW3I7Zh7+xp/L22yPeMm2wZecmUL1/tdAnyS81CYuav0AVoGGCqRIn N9Fw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=metnnJZ3mZMf4C0ObVj11/9ywr2GaxY6djbjEG9BLBI=; b=5RFM5sIBoqKl6NVGrxtAcryqLYGV6Kc9clCYKStHvKVluPU2nWWNTQhzRfLMDqmKag M97+hmlmBoH4GhqTpXCeGWOxVb6RS7QxhVsEDLm/akWtzV515jr9bON9+nWbGJ78IOo4 vH/etw0Ny+FDdROvDhiY54hxoirM5qF2fhXSzmjRF+5+/24mIBsufk5G4W3KjSLOFg88 OCLLGYdawJyciidvlXMnLbnlgTKP8E+hkObubihjDZkbTJ0bZrG+Zap0EF6KnDEDmeBF V1Sbvnpj6tGx/RPo3nQsEqUdx1xtsgxNomvF7fz1CSRGSp4MT7LD6EGKBY2JLaTrFqfu 2kaw== X-Gm-Message-State: ANoB5pmV2hjG/mhEPAh5xm6q6USzMjjQQcBOgNs1ViRq/Xl651lj4+Hm CDc22fMZbkPwT9dzlSAU52NN5j0znAWp929y X-Google-Smtp-Source: AA0mqf7MnotT3pQsDQQQtDmLosAE2tqmOA7Wu3VVLjUo8ShY0mzwaL47gaRUIRnvojSzheNqxhYJJA== X-Received: by 2002:ac8:745:0:b0:3a8:325:47e with SMTP id k5-20020ac80745000000b003a80325047emr33251738qth.54.1671074621789; Wed, 14 Dec 2022 19:23:41 -0800 (PST) Received: from localhost.localdomain (dsl-10-129-63.b2b2c.ca. [72.10.129.63]) by smtp.gmail.com with ESMTPSA id c13-20020ac853cd000000b003a7e4129f83sm2763101qtq.85.2022.12.14.19.23.41 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 14 Dec 2022 19:23:41 -0800 (PST) From: Maxim Cournoyer Date: Wed, 14 Dec 2022 22:23:24 -0500 Message-Id: <20221215032328.3368-2-maxim.cournoyer@gmail.com> X-Mailer: git-send-email 2.38.1 In-Reply-To: <20221215032328.3368-1-maxim.cournoyer@gmail.com> References: <20221215032328.3368-1-maxim.cournoyer@gmail.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit 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-Country: US X-Migadu-Flow: FLOW_IN ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1671074705; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: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=metnnJZ3mZMf4C0ObVj11/9ywr2GaxY6djbjEG9BLBI=; b=AATnJmH5cF4m1ZvFRikFUbqXYAH+J75BX0uf+6eRtCl3PvUm4gWb/iJkLSuRteRJvfNp1Z gXxQ2ZGkqiS/ii6RPH1Vk0OLiIJNB6P9e+5LawZtfgqTbe+mjGvr4hXgz9gDnT+j7Kb9/3 pnH5o0opvBrD3GY1oQAXSw/ofTiWKDvrMy6dbNzOqLXMvTGI/y+vX33JhOvbSm9gh8y9kq C1E75djXMre/5ZogcdOKulk9M/t+TR1ssERfENWhSxDObRwU86o4LU5bDH4W90ASAl0wjD JLSPtft/fu1tNiJl1JLy/z/Uc7CKOJAa1C1yKNxhy2Jf0Zr0qExY/VkrQMP7pw== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=gmail.com header.s=20210112 header.b=a2NFPPx4; 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"; dmarc=fail reason="SPF not aligned (relaxed)" header.from=gmail.com (policy=none) ARC-Seal: i=1; s=key1; d=yhetil.org; t=1671074705; a=rsa-sha256; cv=none; b=r/U0njR/FzKZa75Sp+9kPsNKOEOhKvnYQkEOz5Rrg1mFidSiKwWF7JV2CTtV7ILlj3lDf6 6iz4MoZTyH1VJjUR0d9Cxi5Z3rnNNy11f/6kz8Nx8ATph3eTf65lSpppydP0PyCi9UadVG sdyad8n+e8Lb2Voe1E+viS+U7tCcW+MXGkY+SGZg28E4x9Podp/1ADazhb+076+Ku4EqKU +O/kpO6U0jLHyYZRGsUKAi7bG7hOQllzD4YRC04pqYU8D5RJFuC8SIrecN7fAXN7pOKn+q YeU8f/hZf0i28F/TsqGQaCZLe/Pjgoa8xq2PS1AIOjkrUx4rTUVic4n44hZvQQ== X-Migadu-Spam-Score: -1.38 X-Spam-Score: -1.38 X-Migadu-Queue-Id: DD5F9367FF X-Migadu-Scanner: scn1.migadu.com Authentication-Results: aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=gmail.com header.s=20210112 header.b=a2NFPPx4; 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"; dmarc=fail reason="SPF not aligned (relaxed)" header.from=gmail.com (policy=none) X-TUID: uIUEavWsCduD 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. -- 2.38.1