2000-12-01 01:26:26 +03:00
|
|
|
# $NetBSD: Makefile,v 1.9 2000/11/30 22:26:27 scw Exp $
|
1995-07-26 03:11:53 +04:00
|
|
|
|
|
|
|
#
|
1996-09-07 23:23:03 +04:00
|
|
|
# sboot would like a newer GNU ld because it can generate S-Records.
|
|
|
|
# Until then, we convert.
|
1995-07-26 03:11:53 +04:00
|
|
|
#
|
|
|
|
|
2000-12-01 01:26:26 +03:00
|
|
|
COMPILE.s= $(CC) -x assembler-with-cpp -traditional-cpp \
|
|
|
|
$(ASFLAGS) $(CPPFLAGS) -c -o $*.o
|
1996-09-07 23:23:03 +04:00
|
|
|
LDFLAGS=-x -N -Ttext 0x4000 -e start
|
2000-07-24 22:39:01 +04:00
|
|
|
SRCS= start.s clock.c console.c etherfun.c le_poll.c oc_cksum.s sboot.c
|
|
|
|
CLEANFILES+= srec sboot
|
|
|
|
# OPTS= -Os
|
1995-07-26 03:11:53 +04:00
|
|
|
|
2000-07-24 22:39:01 +04:00
|
|
|
PROG= sboot.srec
|
|
|
|
PROGNAME= sboot
|
|
|
|
DPADD= srec sboot
|
1995-07-26 03:11:53 +04:00
|
|
|
|
2000-07-24 22:39:01 +04:00
|
|
|
${PROG}:
|
2000-12-01 01:26:26 +03:00
|
|
|
${.OBJDIR}/srec 4 0x4000 ${.OBJDIR}/sboot > ${.TARGET} < ${.OBJDIR}/sboot
|
1996-09-07 23:23:03 +04:00
|
|
|
|
|
|
|
sboot: ${OBJS}
|
2000-07-24 22:39:01 +04:00
|
|
|
${LD} ${LDFLAGS} -o ${.TARGET} ${OBJS} ${LIBSA}
|
2000-12-01 01:26:26 +03:00
|
|
|
${OBJCOPY} -O binary ${.OBJDIR}/sboot
|
1995-07-26 03:11:53 +04:00
|
|
|
|
2000-07-24 22:39:01 +04:00
|
|
|
srec: srec.c
|
2000-12-01 01:26:26 +03:00
|
|
|
${HOST_CC} ${COPTS} ${.IMPSRC} -o ${.TARGET}
|
1996-09-07 23:23:03 +04:00
|
|
|
|
2000-07-24 22:39:01 +04:00
|
|
|
all: ${OBJS} ${PROG}
|
1996-09-07 23:23:03 +04:00
|
|
|
|
2000-07-24 22:39:01 +04:00
|
|
|
.include "../Makefile.booters"
|
2000-06-25 20:39:05 +04:00
|
|
|
|
1996-09-07 23:23:03 +04:00
|
|
|
.include <bsd.prog.mk>
|