Home | History | Annotate | Line # | Download | only in sboot
Makefile revision 1.4
      1 #	$NetBSD: Makefile,v 1.4 1998/08/01 11:22:53 scw 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= $(AS) $(ASFLAGS) -o $*.o
      9 LDFLAGS=-x -N -Ttext 0x4000 -e start
     10 NOMAN=
     11 SRCS=	start.s clock.c console.c etherfun.c le_poll.c libc_sa.c \
     12 		oc_cksum.s sboot.c
     13 OBJS=	${SRCS:N*.h:R:S/$/.o/g}
     14 CLEANFILES+= srec sboot sboot.srec
     15 
     16 BOOTS=	sboot.srec
     17 
     18 all: ${BOOTS}
     19 
     20 sboot.srec: sboot srec
     21 	dd ibs=32 skip=1 if=sboot | ${.OBJDIR}/srec 4 0x4000 sboot > ${.TARGET}
     22 
     23 sboot: ${OBJS}
     24 	${LD} ${LDFLAGS} -o ${.TARGET} ${OBJS}
     25 
     26 srec: ${.CURDIR}/srec.c
     27 	${CC} ${CFLAGS} ${.CURDIR}/srec.c -o ${.TARGET}
     28 
     29 install:
     30 	${INSTALL} -c -m 444 -g bin -o bin sboot.srec \
     31 	    ${DESTDIR}${MDEC_DIR}/sboot
     32 
     33 .include <bsd.prog.mk>
     34