From d970ee2bae1925bb9265d37adef0b92e2678d666 Mon Sep 17 00:00:00 2001 From: Alan Modra Date: Mon, 8 Apr 2019 14:07:35 +0930 Subject: [PATCH] Fix i386-lynxos and other runtime linker fails Segfaults due to htab->params being NULL. * emulparams/elf64rdos.sh (EXTRA_EM_FILE): Define. * emulparams/i386lynx.sh (EXTRA_EM_FILE): Define. * emulparams/i386nto.sh (EXTRA_EM_FILE): Define. --- ld/ChangeLog | 6 ++++++ ld/emulparams/elf64rdos.sh | 1 + ld/emulparams/i386lynx.sh | 1 + ld/emulparams/i386nto.sh | 1 + 4 files changed, 9 insertions(+) diff --git a/ld/ChangeLog b/ld/ChangeLog index 88044d19903..b1e7b0420d6 100644 --- a/ld/ChangeLog +++ b/ld/ChangeLog @@ -1,3 +1,9 @@ +2019-04-08 Alan Modra + + * emulparams/elf64rdos.sh (EXTRA_EM_FILE): Define. + * emulparams/i386lynx.sh (EXTRA_EM_FILE): Define. + * emulparams/i386nto.sh (EXTRA_EM_FILE): Define. + 2019-04-06 H.J. Lu * Makefile.am (ELF_X86_DEPS): Add $(srcdir)/emultempl/elf-x86.em. diff --git a/ld/emulparams/elf64rdos.sh b/ld/emulparams/elf64rdos.sh index 021bc704689..87164d573aa 100644 --- a/ld/emulparams/elf64rdos.sh +++ b/ld/emulparams/elf64rdos.sh @@ -10,6 +10,7 @@ LARGE_DATA_ADDR=0x80020000000 ARCH="i386:x86-64" MACHINE= TEMPLATE_NAME=elf32 +EXTRA_EM_FILE="elf-x86" GENERATE_SHLIB_SCRIPT=yes GENERATE_PIE_SCRIPT=yes LARGE_SECTIONS=yes diff --git a/ld/emulparams/i386lynx.sh b/ld/emulparams/i386lynx.sh index 93afb3d7f37..b86967bd469 100644 --- a/ld/emulparams/i386lynx.sh +++ b/ld/emulparams/i386lynx.sh @@ -13,6 +13,7 @@ ARCH=i386 MACHINE= NOP=0x9090 TEMPLATE_NAME=elf32 +EXTRA_EM_FILE="elf-x86" GENERATE_SHLIB_SCRIPT=yes ELF_INTERPRETER_NAME=\"/usr/lib/ld.so.1\" diff --git a/ld/emulparams/i386nto.sh b/ld/emulparams/i386nto.sh index bb685f3a015..ab5f84c8bdb 100644 --- a/ld/emulparams/i386nto.sh +++ b/ld/emulparams/i386nto.sh @@ -8,4 +8,5 @@ ARCH=i386 MACHINE= NOP=0x9090 TEMPLATE_NAME=elf32 +EXTRA_EM_FILE="elf-x86" GENERATE_SHLIB_SCRIPT=yes -- 2.30.2