summaryrefslogtreecommitdiff
path: root/gnu/usr.bin/binutils
diff options
context:
space:
mode:
authorMichael Shalayeff <mickey@cvs.openbsd.org>2002-06-05 19:16:25 +0000
committerMichael Shalayeff <mickey@cvs.openbsd.org>2002-06-05 19:16:25 +0000
commit4f08339035a7245eb7d769f923b0201bea1c39d3 (patch)
treebef92b7a50a387198830ff74ace770fa3d1d523f /gnu/usr.bin/binutils
parentbf25e3be19dae34e7edb1d58cd7025eed11ab205 (diff)
provide our own path for generating the ldscripts and tweak it accordingly; fgsch@ ok
Diffstat (limited to 'gnu/usr.bin/binutils')
-rw-r--r--gnu/usr.bin/binutils/ld/Makefile.am2
-rw-r--r--gnu/usr.bin/binutils/ld/Makefile.in8
-rw-r--r--gnu/usr.bin/binutils/ld/emulparams/hppaobsd.sh9
-rw-r--r--gnu/usr.bin/binutils/ld/scripttempl/hppaobsd.sc35
4 files changed, 42 insertions, 12 deletions
diff --git a/gnu/usr.bin/binutils/ld/Makefile.am b/gnu/usr.bin/binutils/ld/Makefile.am
index 7b75c791c3a..19590adc7b3 100644
--- a/gnu/usr.bin/binutils/ld/Makefile.am
+++ b/gnu/usr.bin/binutils/ld/Makefile.am
@@ -563,7 +563,7 @@ ehppalinux.c: $(srcdir)/emulparams/hppalinux.sh \
${GENSCRIPTS} hppalinux "$(tdir_hppalinux)"
ehppaobsd.c: $(srcdir)/emulparams/hppaobsd.sh \
$(srcdir)/emultempl/elf32.em $(srcdir)/emultempl/hppaelf.em \
- $(srcdir)/scripttempl/elf.sc ${GEN_DEPENDS}
+ $(srcdir)/scripttempl/hppaobsd.sc ${GEN_DEPENDS}
${GENSCRIPTS} hppaobsd "$(tdir_hppaobsd)"
ei386aout.c: $(srcdir)/emulparams/i386aout.sh \
$(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/aout.sc ${GEN_DEPENDS}
diff --git a/gnu/usr.bin/binutils/ld/Makefile.in b/gnu/usr.bin/binutils/ld/Makefile.in
index b6c00a4f76d..5560640e749 100644
--- a/gnu/usr.bin/binutils/ld/Makefile.in
+++ b/gnu/usr.bin/binutils/ld/Makefile.in
@@ -273,10 +273,6 @@ deffilep.c ldgram.c ldlex.c
DISTFILES = $(DIST_COMMON) $(SOURCES) $(HEADERS) $(TEXINFOS) $(EXTRA_DIST)
-# Target to use for installing unformatted man-pages. Some systems may not
-# want them installed.
-INSTALL_MAN = install-man
-
TAR = tar
GZIP_ENV = --best
SOURCES = $(ld_new_SOURCES) $(EXTRA_ld_new_SOURCES)
@@ -728,7 +724,7 @@ all-recursive-am: config.h
install-exec-am: install-exec-local
install-exec: install-exec-recursive
-install-data-am: $(INSTALL_MAN) install-data-local
+install-data-am: install-man install-data-local
install-data: install-data-recursive
install-am: all-am
@@ -1093,7 +1089,7 @@ ehppalinux.c: $(srcdir)/emulparams/hppalinux.sh \
${GENSCRIPTS} hppalinux "$(tdir_hppalinux)"
ehppaobsd.c: $(srcdir)/emulparams/hppaobsd.sh \
$(srcdir)/emultempl/elf32.em $(srcdir)/emultempl/hppaelf.em \
- $(srcdir)/scripttempl/elf.sc ${GEN_DEPENDS}
+ $(srcdir)/scripttempl/hppaobsd.sc ${GEN_DEPENDS}
${GENSCRIPTS} hppaobsd "$(tdir_hppaobsd)"
ei386aout.c: $(srcdir)/emulparams/i386aout.sh \
$(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/aout.sc ${GEN_DEPENDS}
diff --git a/gnu/usr.bin/binutils/ld/emulparams/hppaobsd.sh b/gnu/usr.bin/binutils/ld/emulparams/hppaobsd.sh
index a7764fd9e08..63a4567a991 100644
--- a/gnu/usr.bin/binutils/ld/emulparams/hppaobsd.sh
+++ b/gnu/usr.bin/binutils/ld/emulparams/hppaobsd.sh
@@ -1,15 +1,14 @@
SCRIPT_NAME=elf
ELFSIZE=32
OUTPUT_FORMAT="elf32-hppa"
-TEXT_START_ADDR=0x10000
-TARGET_PAGE_SIZE=0x10000
-MAXPAGESIZE=0x10000
+TEXT_START_ADDR=0x1000
+TARGET_PAGE_SIZE=0x1000
+MAXPAGESIZE=0x1000
ARCH=hppa
MACHINE=hppa1.1 # We use 1.1 specific features.
NOP=0x08000240
START="_start"
-OTHER_READONLY_SECTIONS="
- .PARISC.unwind ${RELOCATING-0} : { *(.PARISC.unwind) }"
+OTHER_READONLY_SECTIONS='.PARISC.unwind : { *(.PARISC.unwind) } '
DATA_START_SYMBOLS='PROVIDE ($global$ = .);'
DATA_PLT=
GENERATE_SHLIB_SCRIPT=yes
diff --git a/gnu/usr.bin/binutils/ld/scripttempl/hppaobsd.sc b/gnu/usr.bin/binutils/ld/scripttempl/hppaobsd.sc
new file mode 100644
index 00000000000..ee525c4cc0e
--- /dev/null
+++ b/gnu/usr.bin/binutils/ld/scripttempl/hppaobsd.sc
@@ -0,0 +1,35 @@
+test "$LD_FLAG" = "N" && DATA_ADDR=.
+cat <<EOF
+OUTPUT_FORMAT("${OUTPUT_FORMAT}")
+OUTPUT_ARCH(${ARCH})
+ENTRY("\$START\$")
+${RELOCATING+${LIB_SEARCH_DIRS}}
+SECTIONS
+{
+ .text 0x1000 ${RELOCATING++${TEXT_START_ADDR}}:
+ {
+ ${RELOCATING+__text_start = .};
+ CREATE_OBJECT_SYMBOLS
+ *(.PARISC.stubs)
+ *(.text)
+ ${RELOCATING+etext = .};
+ ${RELOCATING+_etext = .};
+ }
+ .data :
+ {
+ ${RELOCATING+ . = ALIGN(0x1000) };
+ ${RELOCATING+__data_start = .};
+ *(.data)
+ ${CONSTRUCTING+CONSTRUCTORS}
+ ${RELOCATING+edata = .};
+ ${RELOCATING+_edata = .};
+ }
+ .bss :
+ {
+ *(.bss)
+ *(COMMON)
+ ${RELOCATING+end = . };
+ ${RELOCATING+_end = . };
+ }
+}
+EOF