Makefile.gzboot revision 1.1
1# $NetBSD: Makefile.gzboot,v 1.1 2002/02/23 05:41:14 thorpej Exp $ 2 3NOMAN= # defined 4 5.include <bsd.own.mk> 6 7EVBARM_STAND= ${S}/arch/evbarm/stand 8 9BASE= gzboot_${PLATFORM}_${RELOC} 10PROG= ${BASE}.sym 11WARNS= 1 12 13NEWVERSWHAT= "Gzip Boot" 14VERSIONFILE= ${EVBARM_STAND}/gzboot/version 15 16BINMODE=644 17 18DBG= -Os 19 20# XXX SHOULD NOT NEED TO DEFINE THESE! 21LIBCRT0= 22LIBC= 23LIBCRTBEGIN= 24LIBCRTEND= 25 26.PATH: ${EVBARM_STAND}/gzboot 27.PATH: ${EVBARM_STAND}/board 28 29SRCS+= gzboot.c image.c 30 31STARTFILE= srtbegin.o 32 33CPPFLAGS+= -nostdinc -I. -I${EVBARM_STAND}/gzboot -I${EVBARM_STAND}/board 34CPPFLAGS+= -I${S} -I${S}/arch -I${S}/lib/libsa 35CPPFLAGS+= -D_STANDALONE 36CPPFLAGS+= -DHEAP_VARIABLE 37CPPFLAGS+= -DRELOC=0x${RELOC} 38 39COPTS+= -ffreestanding 40CWARNFLAGS+= -Wno-main 41 42CLEANFILES+= ${STARTFILE} vers.c ${BASE}.list 43SRCS+= vers.c 44 45.if !make(obj) && !make(clean) && !make(cleandir) 46.BEGIN: machine 47.NOPATH: machine 48.endif 49 50realdepend realall: machine 51CLEANFILES+= arm machine 52 53machine:: 54 -rm -f arm machine 55 ln -s ${S}/arch/evbarm/include machine 56 ln -s ${S}/arch/arm/include arm 57 58${OBJS}: machine 59 60### find out what to use for libkern 61KERN_AS= library 62.include "${S}/lib/libkern/Makefile.inc" 63LIBKERN= ${KERNLIB} 64 65### find out what to use for libz 66Z_AS= library 67.include "${S}/lib/libz/Makefile.inc" 68LIBZ= ${ZLIB} 69 70### find out what to use for libsa 71SA_AS= library 72.include "${S}/lib/libsa/Makefile.inc" 73LIBSA= ${SALIB} 74 75cleandir distclean: cleanlibdir 76 77cleanlibdir: 78 rm -rf lib 79 80LDFLAGS= -M -N -e start 81 82LIBLIST=${LIBSA} ${LIBZ} ${LIBSA} ${LIBKERN} ${LIBSA} 83 84.PHONY: vers.c 85vers.c: ${VERSIONFILE} 86 sh ${S}/conf/newvers_stand.sh ${.ALLSRC} '${PLATFORM}' \ 87 ${NEWVERSWHAT} 88 89${PROG}: ${STARTFILE} ${OBJS} ${LIBSA} ${LIBZ} ${LIBKERN} 90 ${LD} -o ${BASE}.sym ${LDFLAGS} -Ttext 0x${RELOC} ${STARTFILE} \ 91 ${OBJS} ${LIBLIST} > ${BASE}.list 92 93.include <bsd.prog.mk> 94