From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp0.migadu.com ([2001:41d0:303:e16b::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms13.migadu.com with LMTPS id 8DPJF69xXmfObAEAqHPOHw:P1 (envelope-from ) for ; Sun, 15 Dec 2024 06:05:35 +0000 Received: from aspmx1.migadu.com ([2001:41d0:303:e16b::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp0.migadu.com with LMTPS id 8DPJF69xXmfObAEAqHPOHw (envelope-from ) for ; Sun, 15 Dec 2024 07:05:35 +0100 X-Envelope-To: larch@yhetil.org Authentication-Results: aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=debbugs.gnu.org header.s=debbugs-gnu-org header.b=pcbRGg3V; dkim=fail ("headers rsa verify failed") header.d=protonmail.com header.s=protonmail3 header.b="UA2W/UQ5"; 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=pass (policy=none) header.from=gnu.org ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1734242734; h=from:from:sender:sender:reply-to:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding:resent-to: 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=XcPxsNJermvg68RF98fJTZOkJyMtIXr60mJL0kIcltw=; b=JF+L9r6wtK4SRc0GbUjhGVKvRQCE4cCDzq5UpaizPhhOSETMQzm5wjVKxaKH261sfmSwef vgTs9/wkLaR6TtGio401cIxngI1rm9V46r3oXtvGxL73bkNkFagD/KzO7yjO+GFOiKweE5 kXuRDl/z35T7UCKSbBJT0ILZzcWqEEBLYD9KL+CjExZfKybhntnssdJw2enWc0eT7D0L9q AKgdXlguYasj0zgrOMX/7uqaoTDO9FabpwSLSX9IGF1UAUI0e52ElK/KV+HLO3uUaYEk1W 2/aQWfs6zPAMfI6uhJHSMvTAqetgFrmbXSi5Sbxv5SwmJcpV60CvNsw+XdVqCg== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=debbugs.gnu.org header.s=debbugs-gnu-org header.b=pcbRGg3V; dkim=fail ("headers rsa verify failed") header.d=protonmail.com header.s=protonmail3 header.b="UA2W/UQ5"; 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=pass (policy=none) header.from=gnu.org ARC-Seal: i=1; s=key1; d=yhetil.org; t=1734242734; a=rsa-sha256; cv=none; b=MWCf2x4BNgf/meIIL1iwA6h8clr8LUJG1JbSNzNMB+Wf1AvqMzDsCnDi2LVnhsBZ2NkuSx 5qB6u1JOk7RkzHrEdAeWZEaghj4PSmDqU0Iz/xoMAe+nOg81CmZCgQvUR97LvqqYR9JrPK kmOKpldUva7WLc6cVL9ntk/scr8nC5P+N9Ay5U+rRf26POtf50PZN7MBihuXxJSc1N/JPH yEk53sgxkPvJ35mmx9n6omYStNsFQ6k50TN3o6uUBYWcax5fToQnCf9cnsKOXjfHXvwDeW Gq+bYKiups9hVexlmi3JWZrTFWr4V95L5Swe5xkYihbf4EK3NjB3Qm3DGBJ1Jg== 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 D68C95D9B3 for ; Sun, 15 Dec 2024 07:05:34 +0100 (CET) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1tMhkX-0006Zj-6s; Sun, 15 Dec 2024 01:05:05 -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 1tMhkU-0006Z3-Kx for bug-guix@gnu.org; Sun, 15 Dec 2024 01:05:02 -0500 Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1tMhkU-0000dF-5W for bug-guix@gnu.org; Sun, 15 Dec 2024 01:05:02 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=debbugs.gnu.org; s=debbugs-gnu-org; h=MIME-Version:References:In-Reply-To:From:Date:To:Subject; bh=XcPxsNJermvg68RF98fJTZOkJyMtIXr60mJL0kIcltw=; b=pcbRGg3VsKJQas1K3wiWiSTKxNOB5EZOM/dHWPyqsS6folhSOVj/ruxfy07jOBWmXewLoip20vDg4x0QvXwjqzaFtsLJ0kt0/hZ4mlBsr0I5VZ7SY5u5hlD+ok4KtzClql+2DWHobg1Q5IPYMbteLCMQnAIT2zw3Zb8PcdrSsI2CK61qzjHRZtXXj+8bB4L46wT3SGITAAC2ebNaXjnfJxhkzwEBZCi4wx87mDUmTKKPkCgfzrDLK2tF9zVCkrE4auLLQwHlHghCCQ81jOErAVBHP4Etf5W5nxxZwWQBeMMtgVUrRapfHzv7dkXjCl7Oovil/qoUobcy1Z80ZVIMHg==; Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1tMhkT-00016k-W5 for bug-guix@gnu.org; Sun, 15 Dec 2024 01:05:02 -0500 Subject: bug#62917: [bug#73799] [PATCH] Fix 'guix shell: error: symlink: File exists: "/bin/cc"' Resent-From: John Kehayias Original-Sender: "Debbugs-submit" Resent-To: bug-guix@gnu.org Resent-Date: Sun, 15 Dec 2024 06:05:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: cc-closed 62917 X-GNU-PR-Package: guix X-GNU-PR-Keywords: patch To: 62917-done@debbugs.gnu.org Cc: Ludovic =?UTF-8?Q?Court=C3=A8s?= , Marco Fortina , Maxim Cournoyer Mail-Followup-To: 62917@debbugs.gnu.org, john.kehayias@protonmail.com, zamfofex@twdb.moe Received: via spool by 62917-done@debbugs.gnu.org id=D62917.17342426714189 (code D ref 62917); Sun, 15 Dec 2024 06:05:01 +0000 Received: (at 62917-done) by debbugs.gnu.org; 15 Dec 2024 06:04:31 +0000 Received: from localhost ([127.0.0.1]:49297 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1tMhjy-00015V-Pq for submit@debbugs.gnu.org; Sun, 15 Dec 2024 01:04:31 -0500 Received: from mail-10628.protonmail.ch ([79.135.106.28]:51643) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1tMhjv-00015C-Hw for 62917-done@debbugs.gnu.org; Sun, 15 Dec 2024 01:04:29 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=protonmail.com; s=protonmail3; t=1734242659; x=1734501859; bh=XcPxsNJermvg68RF98fJTZOkJyMtIXr60mJL0kIcltw=; h=Date:To:From:Cc:Subject:Message-ID:In-Reply-To:References: Feedback-ID:From:To:Cc:Date:Subject:Reply-To:Feedback-ID: Message-ID:BIMI-Selector:List-Unsubscribe:List-Unsubscribe-Post; b=UA2W/UQ51f20DfcYe8GrIKhEM6fiakRX0atmtIe34lQ47nvZdnxl2SCwzsNWj/VFF SpErVGlsZ0RkmtvDhVQRhwgOmXSPTHImWw0S0Ymmu8Vb141Uia/bYl7exuOJZlUMiB fJ6UCIY1yr5DcuMQXxNAPZUpp44q2hyfqS1Fx0NLbEmpd5Hr9gPKYEIHbBxgrjDw6C heccpz3gyeVdcKgiUx4+GPmmoCLXN49EcuNi/h3CXep3nRNgvqpDnPBOvUICpdqtdS YkcLUQAgKGOQKI0zvh42Ol3F799cji42KPHha70oJqgJIO46DfwrmaJ5m1txxk2bgw RZTCbBKQsvPNA== Date: Sun, 15 Dec 2024 06:04:15 +0000 Message-ID: <874j355vot.fsf@protonmail.com> In-Reply-To: <87zfkxy34e.fsf@gmail.com> References: <87zfkxy34e.fsf@gmail.com> Feedback-ID: 7805494:user:proton X-Pm-Message-ID: 01a88eb54be57d6cf8def57a0110463fa3a45b64 MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable 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: , Reply-to: John Kehayias From: John Kehayias via Bug reports for GNU Guix 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 X-Migadu-Queue-Id: D68C95D9B3 X-Migadu-Scanner: mx13.migadu.com X-Migadu-Spam-Score: -1.72 X-Spam-Score: -1.72 X-TUID: 6JSGLBvRgStG On Sun, Dec 15, 2024 at 01:36 PM, Maxim Cournoyer wrote: > Hi Marco, > > Marco Fortina writes: > >> This patch closes issue when running "guix shell --container --emulate-f= hs clang-toolchain gcc-toolchain" or "guix shell --container --emulate-fhs = clang-toolchain gcc-toolchain": >> >> >> diff --git a/guix/scripts/environment.scm b/guix/scripts/environment.scm >> index a219b2ac89..37f11395f9 100644 >> --- a/guix/scripts/environment.scm >> +++ b/guix/scripts/environment.scm >> @@ -464,7 +464,8 @@ (define (setup-fhs profile) >> ;; /bin since that already has the sh symlink and the other (optional= ) FHS >> ;; bin directories will link to /bin. >> (let ((gcc-path (string-append profile "/bin/gcc"))) >> - (if (file-exists? gcc-path) >> + (if (and (file-exists? gcc-path) >> + (not (file-exists? "/bin/cc"))) >> (symlink gcc-path "/bin/cc"))) >> >> ;; Guix's ldconfig doesn't search in FHS default locations, so provid= e a > > I see Ludovic pushed a variant of the above fix with > 23ab6fc29f28b0fa9ad94bf2ceed135ee3fdea34, and attributed your discovery > of the problem. > > Good. Thanks for the report and patch! Thanks for the followup, closing this. John