2021-01-12 13:03:48 +01:00
|
|
|
From 3ad56b9d46401577a02f06338049654cc5ef7039 Mon Sep 17 00:00:00 2001
|
|
|
|
From: Emery Hemingway <ehmry@posteo.net>
|
|
|
|
Date: Tue, 12 Jan 2021 15:24:52 +0100
|
|
|
|
Subject: [PATCH] Add Genode target support
|
2020-05-30 20:50:44 +02:00
|
|
|
|
2021-01-12 13:03:48 +01:00
|
|
|
---
|
|
|
|
bfd/config.bfd | 6 +++---
|
|
|
|
gas/configure.tgt | 4 +++-
|
|
|
|
ld/configure.tgt | 8 ++++----
|
|
|
|
3 files changed, 10 insertions(+), 8 deletions(-)
|
2020-05-30 20:50:44 +02:00
|
|
|
|
2020-03-24 13:47:30 +01:00
|
|
|
diff --git a/bfd/config.bfd b/bfd/config.bfd
|
2021-01-12 13:03:48 +01:00
|
|
|
index 14523caf0c..9b3e2a5e3f 100644
|
2020-03-24 13:47:30 +01:00
|
|
|
--- a/bfd/config.bfd
|
|
|
|
+++ b/bfd/config.bfd
|
2020-05-30 20:50:44 +02:00
|
|
|
@@ -229,7 +229,7 @@ case "${targ}" in
|
|
|
|
targ_archs="$targ_archs bfd_i386_arch bfd_powerpc_arch bfd_rs6000_arch"
|
|
|
|
want64=true
|
|
|
|
;;
|
|
|
|
- aarch64-*-elf | aarch64-*-rtems*)
|
|
|
|
+ aarch64-*-elf | aarch64-*-rtems* | aarch64-*-genode*)
|
|
|
|
targ_defvec=aarch64_elf64_le_vec
|
|
|
|
targ_selvecs="aarch64_elf64_be_vec aarch64_elf32_le_vec aarch64_elf32_be_vec arm_elf32_le_vec arm_elf32_be_vec"
|
|
|
|
want64=true
|
2021-01-12 13:03:48 +01:00
|
|
|
@@ -555,7 +555,7 @@ case "${targ}" in
|
2020-03-24 13:47:30 +01:00
|
|
|
targ_selvecs=hppa_elf32_vec
|
|
|
|
;;
|
2020-05-30 20:50:44 +02:00
|
|
|
|
2020-03-24 13:47:30 +01:00
|
|
|
- i[3-7]86-*-elf* | i[3-7]86-*-rtems*)
|
|
|
|
+ i[3-7]86-*-elf* | i[3-7]86-*-rtems* | i[3-7]86-*-genode*)
|
|
|
|
targ_defvec=i386_elf32_vec
|
|
|
|
targ_selvecs="iamcu_elf32_vec i386_coff_vec"
|
|
|
|
;;
|
2021-01-12 13:03:48 +01:00
|
|
|
@@ -653,7 +653,7 @@ case "${targ}" in
|
2020-03-24 13:47:30 +01:00
|
|
|
targ_selvecs="i386_elf32_vec iamcu_elf32_vec l1om_elf64_vec k1om_elf64_vec"
|
|
|
|
want64=true
|
|
|
|
;;
|
|
|
|
- x86_64-*-elf* | x86_64-*-rtems* | x86_64-*-fuchsia)
|
|
|
|
+ x86_64-*-elf* | x86_64-*-rtems* | x86_64-*-fuchsia | x86_64-*-genode*)
|
|
|
|
targ_defvec=x86_64_elf64_vec
|
|
|
|
targ_selvecs="i386_elf32_vec iamcu_elf32_vec x86_64_elf32_vec l1om_elf64_vec k1om_elf64_vec"
|
|
|
|
case "${targ}" in
|
|
|
|
diff --git a/gas/configure.tgt b/gas/configure.tgt
|
2021-01-12 13:03:48 +01:00
|
|
|
index 337249597c..0030a40d7d 100644
|
2020-03-24 13:47:30 +01:00
|
|
|
--- a/gas/configure.tgt
|
|
|
|
+++ b/gas/configure.tgt
|
2020-05-30 20:50:44 +02:00
|
|
|
@@ -123,6 +123,7 @@ generic_target=${cpu_type}-$vendor-$os
|
|
|
|
case ${generic_target} in
|
|
|
|
aarch64*-*-elf*) fmt=elf;;
|
|
|
|
aarch64*-*-fuchsia*) fmt=elf;;
|
|
|
|
+ aarch64*-*-genode*) fmt=elf;;
|
|
|
|
aarch64*-*-linux*) fmt=elf em=linux
|
|
|
|
case ${cpu}-${os} in
|
|
|
|
aarch64*-linux-gnu_ilp32) arch=aarch64:32 ;;
|
2021-01-12 13:03:48 +01:00
|
|
|
@@ -139,7 +140,7 @@ case ${generic_target} in
|
2020-05-30 20:50:44 +02:00
|
|
|
|
2020-03-24 13:47:30 +01:00
|
|
|
arm-*-phoenix*) fmt=elf ;;
|
|
|
|
arm-*-elf) fmt=elf ;;
|
|
|
|
- arm-*-eabi* | arm-*-rtems*) fmt=elf em=armeabi ;;
|
2021-01-12 13:03:48 +01:00
|
|
|
+ arm-*-eabi* | arm-*-rtems* | arm-*-genode*) fmt=elf em=armeabi ;;
|
2020-03-24 13:47:30 +01:00
|
|
|
arm-*-symbianelf*) fmt=elf em=symbian ;;
|
|
|
|
arm-*-kaos*) fmt=elf ;;
|
|
|
|
arm-*-conix*) fmt=elf ;;
|
2021-01-12 13:03:48 +01:00
|
|
|
@@ -219,6 +220,7 @@ case ${generic_target} in
|
2020-03-24 13:47:30 +01:00
|
|
|
i386-*-elfiamcu) fmt=elf arch=iamcu ;;
|
|
|
|
i386-*-elf*) fmt=elf ;;
|
|
|
|
i386-*-fuchsia*) fmt=elf ;;
|
|
|
|
+ i386-*-genode*) fmt=elf ;;
|
|
|
|
i386-*-bsd*) fmt=aout em=386bsd ;;
|
2021-01-12 13:03:48 +01:00
|
|
|
i386-*-netbsdpe*) fmt=coff em=pe ;;
|
|
|
|
i386-*-netbsd*-gnu* | \
|
2020-03-24 13:47:30 +01:00
|
|
|
diff --git a/ld/configure.tgt b/ld/configure.tgt
|
2021-01-12 13:03:48 +01:00
|
|
|
index 87c7d9a4ca..dafcc4812c 100644
|
2020-03-24 13:47:30 +01:00
|
|
|
--- a/ld/configure.tgt
|
|
|
|
+++ b/ld/configure.tgt
|
2021-01-12 13:03:48 +01:00
|
|
|
@@ -46,7 +46,7 @@ case "${targ}" in
|
2020-05-30 20:50:44 +02:00
|
|
|
aarch64_be-*-elf) targ_emul=aarch64elfb
|
2021-01-12 13:03:48 +01:00
|
|
|
targ_extra_emuls="aarch64elf aarch64elf32 aarch64elf32b armelfb armelf"
|
|
|
|
;;
|
2020-05-30 20:50:44 +02:00
|
|
|
-aarch64-*-elf | aarch64-*-rtems*)
|
2021-01-12 13:03:48 +01:00
|
|
|
++aarch64-*-elf | aarch64-*-rtems* | aarch64-*-genode*)
|
2020-05-30 20:50:44 +02:00
|
|
|
targ_emul=aarch64elf
|
2021-01-12 13:03:48 +01:00
|
|
|
targ_extra_emuls="aarch64elf32 aarch64elf32b aarch64elfb armelf armelfb"
|
|
|
|
;;
|
|
|
|
@@ -148,7 +148,7 @@ arm-*-phoenix*) targ_emul=armelf
|
2020-03-24 13:47:30 +01:00
|
|
|
armeb-*-elf | armeb-*-eabi*)
|
2021-01-12 13:03:48 +01:00
|
|
|
targ_emul=armelfb
|
|
|
|
;;
|
2020-03-24 13:47:30 +01:00
|
|
|
-arm-*-elf | arm*-*-eabi* | arm-*-rtems*)
|
|
|
|
+arm-*-elf | arm*-*-eabi* | arm-*-rtems* | arm-*-genode*)
|
2021-01-12 13:03:48 +01:00
|
|
|
targ_emul=armelf
|
|
|
|
;;
|
2020-03-24 13:47:30 +01:00
|
|
|
arm*-*-symbianelf*) targ_emul=armsymbian;;
|
2021-01-12 13:03:48 +01:00
|
|
|
@@ -354,7 +354,7 @@ i[3-7]86-*-netbsdpe*) targ_emul=i386pe
|
2020-03-24 13:47:30 +01:00
|
|
|
i[3-7]86-*-elfiamcu) targ_emul=elf_iamcu
|
2021-01-12 13:03:48 +01:00
|
|
|
targ_extra_emuls=elf_i386
|
|
|
|
;;
|
2020-03-24 13:47:30 +01:00
|
|
|
-i[3-7]86-*-elf* | i[3-7]86-*-rtems*)
|
|
|
|
+i[3-7]86-*-elf* | i[3-7]86-*-rtems* | i[3-7]86-*-genode*)
|
|
|
|
targ_emul=elf_i386
|
2021-01-12 13:03:48 +01:00
|
|
|
targ_extra_emuls=elf_iamcu
|
|
|
|
;;
|
|
|
|
@@ -954,7 +954,7 @@ x86_64-*-netbsd* | x86_64-*-openbsd*)
|
|
|
|
sed -e 's/netbsd/netbsdelf/'`;;
|
|
|
|
esac
|
|
|
|
;;
|
2020-03-24 13:47:30 +01:00
|
|
|
-x86_64-*-elf* | x86_64-*-rtems* | x86_64-*-fuchsia*)
|
|
|
|
+x86_64-*-elf* | x86_64-*-rtems* | x86_64-*-fuchsia* | x86_64-*-genode*)
|
|
|
|
targ_emul=elf_x86_64
|
|
|
|
targ_extra_emuls="elf_i386 elf_iamcu elf32_x86_64 elf_l1om elf_k1om"
|
|
|
|
targ_extra_libpath="elf_i386 elf_iamcu elf32_x86_64 elf_l1om elf_k1om"
|
2021-01-12 13:03:48 +01:00
|
|
|
--
|
|
|
|
2.29.2
|
|
|
|
|