Module Name: src Committed By: tsutsui Date: Thu Apr 16 12:36:06 UTC 2009
Modified Files: src/sys/arch/newsmips/stand/bootxx: Makefile Log Message: Use mips/conf/stand.ldscript on link so that we can use objcopy(1) to create raw bootxx binary. Tested on NWS-5000X. To generate a diff of this commit: cvs rdiff -u -r1.12 -r1.13 src/sys/arch/newsmips/stand/bootxx/Makefile Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
Modified files: Index: src/sys/arch/newsmips/stand/bootxx/Makefile diff -u src/sys/arch/newsmips/stand/bootxx/Makefile:1.12 src/sys/arch/newsmips/stand/bootxx/Makefile:1.13 --- src/sys/arch/newsmips/stand/bootxx/Makefile:1.12 Wed Apr 15 17:15:13 2009 +++ src/sys/arch/newsmips/stand/bootxx/Makefile Thu Apr 16 12:36:06 2009 @@ -1,4 +1,4 @@ -# $NetBSD: Makefile,v 1.12 2009/04/15 17:15:13 tsutsui Exp $ +# $NetBSD: Makefile,v 1.13 2009/04/16 12:36:06 tsutsui Exp $ S!= cd ${.CURDIR}/../../../..; pwd @@ -14,7 +14,8 @@ COMMON!= cd ${.CURDIR}/../common && ${PRINTOBJDIR} -LINKFLAGS= -x -N -Ttext a0004000 -e _start +LDSCRIPT= ${S}/arch/mips/conf/stand.ldscript +LINKFLAGS= -x -N -Ttext a0004000 -T ${LDSCRIPT} -e _start CFLAGS= -Os -ffreestanding -mmemcpy -mno-abicalls -msoft-float -G 0 CFLAGS+= -Wall -Wmissing-prototypes -Wstrict-prototypes -Wpointer-arith @@ -24,7 +25,7 @@ AFLAGS= -D_LOCORE -mno-abicalls CLEANFILES+= machine mips ${PROG}.sym -CLEANFILES+= ${PROG}.bin ${PROG}.tmp +CLEANFILES+= ${PROG}.bin LIBS= ${COMMON}/romcalls.o LIBS+= ${COMMON}/lib/sa/libsa.a ${COMMON}/lib/kern/libkern.a @@ -33,10 +34,7 @@ ${_MKTARGET_LINK} ${LD} ${LINKFLAGS} -o ${.TARGET}.sym ${OBJS} ${LIBS} ${SIZE} ${.TARGET}.sym -# XXX objcopy does not work for prog at KSEG -# ${OBJCOPY} -O binary ${.TARGET}.sym ${.TARGET} - ${STRIP} ${.TARGET}.sym -o ${.TARGET}.tmp - tail -c +177 ${.TARGET}.tmp > ${.TARGET}.bin + ${OBJCOPY} -O binary ${.TARGET}.sym ${.TARGET}.bin mv ${.TARGET}.bin ${.TARGET} .include <bsd.klinks.mk>