Home | History | Annotate | Line # | Download | only in sboot
Makefile revision 1.12
      1 #	$NetBSD: Makefile,v 1.12 2002/02/09 09:36:01 lukem Exp $
      2 
      3 #
      4 # sboot would like a newer GNU ld because it can generate S-Records.
      5 # Until then, we convert.
      6 #
      7 
      8 COMPILE.s= $(CC) -x assembler-with-cpp -traditional-cpp \
      9 	$(ASFLAGS) $(CPPFLAGS) $(INCPATH) -c -o $*.o
     10 
     11 RELOC=	0x4000
     12 SRCS=	start.s clock.c console.c etherfun.c le_poll.c oc_cksum.s sboot.c
     13 SRTOBJ=
     14 PROG=		sboot
     15 PROGNAME=	sboot.srec
     16 LIBS=		${LIBSA}
     17 DPADD=		${LIBS}
     18 CLEANFILES+=	srec sboot.srec
     19 
     20 PROGDEPENDS=	${OBJS} ${LIBS}
     21 PROGLINKOBJS=	${OBJS} ${LIBS}
     22 
     23 sboot.srec:	${PROG} srec
     24 	${OBJCOPY} -O binary ${.OBJDIR}/sboot
     25 	${.OBJDIR}/srec 4 0x4000 ${.OBJDIR}/sboot \
     26 	> ${.TARGET} < ${.OBJDIR}/sboot
     27 
     28 srec: srec.c
     29 	${HOST_CC} ${COPTS} ${.IMPSRC} -o ${.TARGET}
     30 
     31 .include "../Makefile.booters"
     32 
     33 all realall:	sboot.srec
     34 
     35 install:	sboot.srec
     36 	${INSTALL_FILE} ${STRIPFLAG} -o ${BINOWN} -g ${BINGRP} -m ${BINMODE} \
     37 		${.OBJDIR}/sboot.srec ${DESTDIR}${MDEC_DIR}/sboot
     38 
     39 .include <bsd.prog.mk>
     40