ld: Move Solaris/sparcv9 TEXT_START_ADDR to elf64_sparc_sol2.sh

While looking at the Solaris versions of the program header p_vaddr and
p_align values of the text and data segments, I noticed that the
Solaris/sparcv9 version of TEXT_START_ADDR is defined in a shared file.
Since there's a Solaris/sparcv9 specific file now
(ld/emulparams/elf64_sparc_sol2.sh), it seems cleaner to move it there.

Tested on {sparcv9,sparc}-sun-solaris2.11 and
{sparc64,sparc}-unknown-linux-gnu.

2025-07-29  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>

	ld:
	* emulparams/elf64_sparc.sh (TEXT_START_ADDR): Move ...
	* emulparams/elf64_sparc_sol2.sh (TEXT_START_ADDR): ... here.
This commit is contained in:
Rainer Orth
2025-08-31 12:14:36 +02:00
parent 125bb0a7bf
commit dde82ebef9
3 changed files with 7 additions and 9 deletions

View File

@@ -1,3 +1,8 @@
2025-08-31 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
* emulparams/elf64_sparc.sh (TEXT_START_ADDR): Move ...
* emulparams/elf64_sparc_sol2.sh (TEXT_START_ADDR): ... here.
2025-08-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
* testsuite/ld-shared/shared.exp (shared (non PIC)): Update

View File

@@ -12,15 +12,7 @@ GENERATE_SHLIB_SCRIPT=yes
GENERATE_PIE_SCRIPT=yes
NOP=0x01000000
NO_SMALL_DATA=yes
case "$target" in
sparc*-solaris*)
TEXT_START_ADDR=0x100000000
;;
*)
TEXT_START_ADDR=0x100000
;;
esac
TEXT_START_ADDR=0x100000
# Treat a host that matches the target with the possible exception of "64"
# and "v7", "v8", "v9" in the name as if it were native.

View File

@@ -1,4 +1,5 @@
source_sh ${srcdir}/emulparams/elf64_sparc.sh
source_sh ${srcdir}/emulparams/solaris2.sh
TEXT_START_ADDR=0x100000000
EXTRA_EM_FILE=solaris2
OUTPUT_FORMAT="elf64-sparc-sol2"