Skip to contentSkip to conversation

gcc-8.3: add back GLIBC_DYNAMIC_LINKER riscv changes

PATCH In review Ricardo Salveti 2 participants 3 messages Mar 26, 2019 – Jul 3, 2019

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 gcc-8.3: add back GLIBC_DYNAMIC_LINKER riscv changes

The riscv GLIBC_DYNAMIC_LINKER changes were dropped during the gcc 8.3 update, breaking usrmerge support.

---
 ...NAMIC_LINKER-and-UCLIBC_DYNAMIC_LINKE.patch | 18 ++++++++++++++++--
 1 file changed, 16 insertions(+), 2 deletions(-)
meta/recipes-devtools/gcc/gcc-8.3/0012-Define-GLIBC_DYNAMIC_LINKER-and-UCLIBC_DYNAMIC_LINKE.patch +16 -2
index 91a55c556f..d3be10f207 100644
@@ -1,4 +1,4 @@
-From 4a697387eeab14ece2796c01382cca30e8467ffa Mon Sep 17 00:00:00 2001
+From 6f8649936df3677109b8396f563c716ae8b237fe Mon Sep 17 00:00:00 2001
 From: Khem Raj <[email protected]>
 Date: Fri, 29 Mar 2013 09:24:50 +0400
 Subject: [PATCH 12/40] Define GLIBC_DYNAMIC_LINKER and UCLIBC_DYNAMIC_LINKER
@@ -23,11 +23,12 @@ Upstream-Status: Inappropriate [OE configuration]
  gcc/config/i386/linux64.h    |  6 +++---
  gcc/config/linux.h           |  8 ++++----
  gcc/config/mips/linux.h      | 12 ++++++------
+ gcc/config/riscv/linux.h     |  2 +-
  gcc/config/rs6000/linux64.h  | 16 ++++++----------
  gcc/config/sh/linux.h        |  2 +-
  gcc/config/sparc/linux.h     |  2 +-
  gcc/config/sparc/linux64.h   |  4 ++--
- 11 files changed, 29 insertions(+), 33 deletions(-)
+ 12 files changed, 30 insertions(+), 34 deletions(-)
 
 diff --git a/gcc/config/alpha/linux-elf.h b/gcc/config/alpha/linux-elf.h
 index 36b74dc1993..02373578af8 100644
@@ -152,6 +153,19 @@ index 2dfd0c18b90..12057c51b5e 100644
  
  #undef MUSL_DYNAMIC_LINKER32
  #define MUSL_DYNAMIC_LINKER32 \
+diff --git a/gcc/config/riscv/linux.h b/gcc/config/riscv/linux.h
+index aa8a28d5d31..ebf9551c955 100644
+--- a/gcc/config/riscv/linux.h
++++ b/gcc/config/riscv/linux.h
+@@ -22,7 +22,7 @@ along with GCC; see the file COPYING3.  If not see
+     GNU_USER_TARGET_OS_CPP_BUILTINS();				\
+   } while (0)
+ 
+-#define GLIBC_DYNAMIC_LINKER "/lib/ld-linux-riscv" XLEN_SPEC "-" ABI_SPEC ".so.1"
++#define GLIBC_DYNAMIC_LINKER SYSTEMLIBS_DIR "ld-linux-riscv" XLEN_SPEC "-" ABI_SPEC ".so.1"
+ 
+ #define MUSL_ABI_SUFFIX \
+   "%{mabi=ilp32:-sf}" \
 diff --git a/gcc/config/rs6000/linux64.h b/gcc/config/rs6000/linux64.h
 index 44eab40a234..54aa8d957e7 100644
 --- a/gcc/config/rs6000/linux64.h
Signature · 1 line
2.17.1
#1 lore raw
Quoted 4 lines · Ricardo Salveti

The riscv GLIBC_DYNAMIC_LINKER changes were dropped during the gcc 8.3 update, breaking usrmerge support.

ah thanks for noticing that, this should be fine to apply

Quoted 52 lines
---
 ...NAMIC_LINKER-and-UCLIBC_DYNAMIC_LINKE.patch | 18 ++++++++++++++++--
 1 file changed, 16 insertions(+), 2 deletions(-)
meta/recipes-devtools/gcc/gcc-8.3/0012-Define-GLIBC_DYNAMIC_LINKER-and-UCLIBC_DYNAMIC_LINKE.patch +16 -3
index 91a55c556f..d3be10f207 100644
@@ -1,4 +1,4 @@
-From 4a697387eeab14ece2796c01382cca30e8467ffa Mon Sep 17 00:00:00 2001
+From 6f8649936df3677109b8396f563c716ae8b237fe Mon Sep 17 00:00:00 2001
 From: Khem Raj <[email protected]>
 Date: Fri, 29 Mar 2013 09:24:50 +0400
 Subject: [PATCH 12/40] Define GLIBC_DYNAMIC_LINKER and UCLIBC_DYNAMIC_LINKER
@@ -23,11 +23,12 @@ Upstream-Status: Inappropriate [OE configuration]
  gcc/config/i386/linux64.h    |  6 +++---
  gcc/config/linux.h           |  8 ++++----
  gcc/config/mips/linux.h      | 12 ++++++------
+ gcc/config/riscv/linux.h     |  2 +-
  gcc/config/rs6000/linux64.h  | 16 ++++++----------
  gcc/config/sh/linux.h        |  2 +-
  gcc/config/sparc/linux.h     |  2 +-
  gcc/config/sparc/linux64.h   |  4 ++--
- 11 files changed, 29 insertions(+), 33 deletions(-)
+ 12 files changed, 30 insertions(+), 34 deletions(-)
 
 diff --git a/gcc/config/alpha/linux-elf.h b/gcc/config/alpha/linux-elf.h
 index 36b74dc1993..02373578af8 100644
@@ -152,6 +153,19 @@ index 2dfd0c18b90..12057c51b5e 100644
 
  #undef MUSL_DYNAMIC_LINKER32
  #define MUSL_DYNAMIC_LINKER32 \
+diff --git a/gcc/config/riscv/linux.h b/gcc/config/riscv/linux.h
+index aa8a28d5d31..ebf9551c955 100644
+--- a/gcc/config/riscv/linux.h
++++ b/gcc/config/riscv/linux.h
+@@ -22,7 +22,7 @@ along with GCC; see the file COPYING3.  If not see
+     GNU_USER_TARGET_OS_CPP_BUILTINS();                                \
+   } while (0)
+
+-#define GLIBC_DYNAMIC_LINKER "/lib/ld-linux-riscv" XLEN_SPEC "-" ABI_SPEC ".so.1"
++#define GLIBC_DYNAMIC_LINKER SYSTEMLIBS_DIR "ld-linux-riscv" XLEN_SPEC "-" ABI_SPEC ".so.1"
+
+ #define MUSL_ABI_SUFFIX \
+   "%{mabi=ilp32:-sf}" \
 diff --git a/gcc/config/rs6000/linux64.h b/gcc/config/rs6000/linux64.h
 index 44eab40a234..54aa8d957e7 100644
 --- a/gcc/config/rs6000/linux64.h
--

2.17.1

#2 lore raw
Quoted 6 lines · Khem Raj
Quoted 3 lines · Ricardo Salveti

The riscv GLIBC_DYNAMIC_LINKER changes were dropped during the gcc 8.3 update, breaking usrmerge support.

ah thanks for noticing that, this should be fine to apply

Looks like the same change was dropped with gcc 9.1, will send it again :-)

Cheers,

Signature · 1 line
Ricardo Salveti