Makefile.bootprogs revision 1.1
11.1Suwe# $NetBSD: Makefile.bootprogs,v 1.1 2006/09/01 21:26:18 uwe Exp $
21.1Suwe
31.1SuweS=		${.CURDIR}/../../../../..
41.1Suwe
51.1SuweNOMAN=		# defined
61.1Suwe
71.1SuweBINDIR=		/usr/mdec
81.1SuweBINMODE=	0444
91.1Suwe
101.1SuwePRIMARY_LOAD_ADDRESS?=0x8c201000
111.1SuweSECONDARY_LOAD_ADDRESS?=0x8ff00000
121.1Suwe
131.1Suwe.include <bsd.own.mk>
141.1Suwe
151.1SuweSTRIPFLAG=	# override
161.1Suwe
171.1SuweLIBCRT0=	# nothing
181.1SuweLIBCRTBEGIN=	# nothing
191.1SuweLIBCRTEND=	# nothing
201.1SuweLIBC=		# nothing
211.1Suwe
221.1Suwe.PATH:	${.CURDIR}/..
231.1Suwe
241.1SuweCOPTS=		-Os -ffreestanding
251.1Suwe
261.1SuweLDFLAGS+=	-N
271.1SuweCFLAGS+=	-Wall -Wmissing-prototypes -Wstrict-prototypes
281.1SuweCPPFLAGS+=	-nostdinc -D_STANDALONE
291.1SuweCPPFLAGS+=	-DSH4
301.1SuweCPPFLAGS+=	-I${.OBJDIR} -I${.CURDIR}/.. -I${.CURDIR}/../../boot -I${S}
311.1Suwe
321.1SuweLANDISK_STAND_DIR?= $S/arch/landisk/stand
331.1Suwe
341.1SuweCLEANFILES+=	machine sh3
351.1Suwe
361.1Suwe.if !make(obj) && !make(clean) && !make(cleandir)
371.1Suwe.BEGIN: machine sh3
381.1Suwe.NOPATH: machine sh3
391.1Suwe
401.1Suwemachine::
411.1Suwe	-rm -f $@
421.1Suwe	ln -s ${S}/arch/${MACHINE}/include $@
431.1Suwe
441.1Suwesh3::
451.1Suwe	-rm -f $@
461.1Suwe	ln -s ${S}/arch/sh3/include $@
471.1Suwe.endif
481.1Suwe
491.1Suwelib:
501.1Suwe.ifdef LIBOBJ
511.1Suwe	-rm -f $@
521.1Suwe	ln -s ${LIBOBJ}/lib .
531.1Suwe	[ -d ${LIBOBJ}/lib ] || mkdir ${LIBOBJ}/lib
541.1Suwe.else
551.1Suwe	mkdir lib
561.1Suwe.endif
571.1Suwe
581.1Suwe### find out what to use for libsa
591.1SuweSA_AS= library
601.1Suwe.include "${S}/lib/libsa/Makefile.inc"
611.1SuweLIBSA= ${SALIB}
621.1SuweCPPFLAGS+=	-I$(SADIR)
631.1Suwe
641.1Suwe### find out what to use for libkern
651.1SuweKERN_AS= library
661.1Suwe.include "${S}/lib/libkern/Makefile.inc"
671.1SuweLIBKERN= ${KERNLIB}
681.1Suwe
691.1Suwe### find out what to use for libz
701.1SuweZ_AS= library
711.1Suwe.include "${S}/lib/libz/Makefile.inc"
721.1SuweLIBZ= ${ZLIB}
731.1Suwe
741.1Suwerealdepend realall: lib
751.1Suwe
761.1Suwecleandir distclean: cleanlibdir
771.1Suwe
781.1Suwecleanlibdir:
791.1Suwe	-rm -rf lib
80