Use custom linker script for building ECOFF kernel images. The PROM loader
is fussy about the order of sections and location of memory gaps so we must produce a firmware friendly version of the kernel as netbsd.ecoff for network booting The ELF version uses the standard mips linker script which can be loaded by the new bootstrap routines
This commit is contained in:
parent
972d156775
commit
8e913e0c2a
|
@ -1,4 +1,4 @@
|
|||
# $NetBSD: Makefile.mipsco.inc,v 1.1 2000/12/03 04:51:26 matt Exp $
|
||||
# $NetBSD: Makefile.mipsco.inc,v 1.2 2001/01/22 01:54:03 wdk Exp $
|
||||
|
||||
# Used if DEBUG != ""
|
||||
DEBUG_SYSTEM_LD_TAIL+=; \
|
||||
|
@ -6,7 +6,13 @@ DEBUG_SYSTEM_LD_TAIL+=; \
|
|||
echo ${STRIP} ${STRIPFLAGS} -o $@ $@.gdb; \
|
||||
${STRIP} ${STRIPFLAGS} -o $@ $@.gdb
|
||||
|
||||
# XXX
|
||||
POST_STRIP_SYSTEM_LD_TAIL=; \
|
||||
echo objcopy --output-target=ecoff-bigmips $@ $@.ecoff; \
|
||||
objcopy --output-target=ecoff-bigmips $@ $@.ecoff
|
||||
# build ECOFF image that can be booted directly from firmware
|
||||
LD_ECOFF= ${LD} -N -Ttext ${TEXTADDR} -e start ${GP} \
|
||||
-T ${THISMIPS}/conf/kern.ldscript -x -oformat ecoff-bigmips
|
||||
|
||||
SYSTEM_LD_TAIL= @echo ${LD_ECOFF} -o $@.ecoff '$${SYSTEM_OBJ}' vers.o ; \
|
||||
${LD_ECOFF} -o $@.ecoff ${SYSTEM_OBJ} vers.o swapnetbsd.o
|
||||
|
||||
SYSTEM_LD_TAIL+=; \
|
||||
${SIZE} $@ $@.ecoff; chmod 755 $@ $@.ecoff
|
||||
|
||||
|
|
Loading…
Reference in New Issue