Makefile.cats.inc revision 1.11
1#	$NetBSD: Makefile.cats.inc,v 1.11 2002/11/03 21:43:32 chris Exp $
2
3.if (${OBJECT_FMT} == "ELF")
4# Need to convert the kernel from ELF to a.out so that OpenFirmware
5# can load it.
6
7# ZMAGIC a.out includes the a.out header in front of the text
8# segment, so if we link the kernel at the normal load address,
9# it will be wrong once the a.out header is stuck in the file.
10# XXX HOWEVER, by linking it +32 bytes to compensate, the resulting
11# XXX ELF kernel cannot be booted itself.
12LOADADDRESS=0xF0000020
13
14SYSTEM_LD_TAIL_EXTRA+=; \
15	echo "${DBSYM} $@ || true"; \
16	${DBSYM} $@ || true; \
17	echo OBJCOPY=${OBJCOPY:Q} SIZE=${SIZE:Q} \
18	    ${ARM}/conf/elf2aout.sh $@ $@.aout; \
19	OBJCOPY=${OBJCOPY:Q} SIZE=${SIZE:Q} \
20	    ${ARM}/conf/elf2aout.sh $@ $@.aout
21.endif
22