GNU bug report logs - #63341
[PATCH] gnu: Add dummy linker for riscv64-elf.

Previous Next

Package: guix-patches;

Reported by: iyzsong <at> envs.net

Date: Sun, 7 May 2023 01:32:01 UTC

Severity: normal

Tags: patch

Done: 宋文武 <iyzsong <at> envs.net>

Bug is archived. No further changes may be made.

Full log


Message #11 received at 63341 <at> debbugs.gnu.org (full text, mbox):

From: 宋文武 <iyzsong <at> envs.net>
To: Efraim Flashner <efraim <at> flashner.co.il>
Cc: 63341 <at> debbugs.gnu.org, 宋文武 <iyzsong <at> member.fsf.org>
Subject: Re: [bug#63341] [PATCH] gnu: Add dummy linker for riscv64-elf.
Date: Sun, 07 May 2023 21:22:25 +0800
[Message part 1 (text/plain, inline)]
Efraim Flashner <efraim <at> flashner.co.il> writes:

> I have a couple of dummy *-elf systems I sometimes add and remove
> depending on what I'm working on. What do you think about adding and
> entry for ((string-suffix? "-elf" system) "no-ld.so") and being done
> with these one-off targets?

I think that's fine, or how about only error for '-linux' or '-gnu'
systems, i think that's where a glibc linker is needed.


[0001-gnu-Use-dummy-linker-for-systems-without-a-linux-or-.patch (text/x-patch, inline)]
From 2a972a30b9fcf743036bf9e81044e79854b62fde Mon Sep 17 00:00:00 2001
Message-Id: <2a972a30b9fcf743036bf9e81044e79854b62fde.1683465580.git.iyzsong <at> member.fsf.org>
From: =?UTF-8?q?=E5=AE=8B=E6=96=87=E6=AD=A6?= <iyzsong <at> member.fsf.org>
Date: Sun, 7 May 2023 21:15:20 +0800
Subject: [PATCH] gnu: Use dummy linker for systems without a 'linux' or 'gnu'
 suffix.

* gnu/packages/bootstrap.scm (glibc-dynamic-linker): Use dummy linker for
systems without a 'linux' or 'gnu' suffix.
---
 gnu/packages/bootstrap.scm | 18 +++++-------------
 1 file changed, 5 insertions(+), 13 deletions(-)

diff --git a/gnu/packages/bootstrap.scm b/gnu/packages/bootstrap.scm
index 9a46f97c81..12a84b8265 100644
--- a/gnu/packages/bootstrap.scm
+++ b/gnu/packages/bootstrap.scm
@@ -323,19 +323,11 @@ (define* (glibc-dynamic-linker
      ((string=? system "powerpc64-linux") "/lib/ld64.so.1")
      ((string=? system "alpha-linux") "/lib/ld-linux.so.2")
 
-     ;; XXX: This one is used bare-bones, without a libc, so add a case
-     ;; here just so we can keep going.
-     ((string=? system "arm-elf") "no-ld.so")
-     ((string=? system "arm-eabi") "no-ld.so")
-     ((string=? system "xtensa-elf") "no-ld.so")
-     ((string=? system "avr") "no-ld.so")
-     ((string=? system "propeller-elf") "no-ld.so")
-     ((string=? system "i686-mingw") "no-ld.so")
-     ((string=? system "x86_64-mingw") "no-ld.so")
-     ((string=? system "vc4-elf") "no-ld.so")
-
-     (else (error "dynamic linker name not known for this system"
-                  system)))))
+     ((or (string-suffix? "-linux" system) (string-suffix? "-gnu" system))
+      (error "dynamic linker name not known for this system" system))
+
+     ;; For bare-bones without a libc, eg: arm-elf, arm-eabi, xtensa-elf, etc.
+     (else "no-ld.so"))))
 
 
 ;;;

base-commit: 7612610c44f16fc8f2ff395d9a2d58101a7356aa
-- 
2.39.2

[Message part 3 (text/plain, inline)]

(I'm unable to write a satisfied commit message..)

This bug report was last modified 2 years and 63 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.