Home | History | Annotate | Line # | Download | only in bootblk
Makefile revision 1.1.8.2
      1  1.1.8.2  jdolecek #	$NetBSD: Makefile,v 1.1.8.2 2002/06/23 17:41:58 jdolecek Exp $
      2      1.1       mrg 
      3      1.1       mrg CURDIR=	${.CURDIR}
      4      1.1       mrg S=	${CURDIR}/../../../..
      5      1.1       mrg 
      6      1.1       mrg #
      7      1.1       mrg # Override normal settings
      8      1.1       mrg #
      9      1.1       mrg 
     10      1.1       mrg PROG=	bootblk
     11      1.1       mrg SRCS=		bootblk.fth
     12      1.1       mrg OBJS=
     13      1.1       mrg CLEANFILES=	assym.fth.h assym.fth.h.tmp machine sparc \
     14      1.1       mrg 		bootblk bootblk.text bootblk.text.tmp
     15      1.1       mrg 
     16  1.1.8.1   thorpej NOMAN=		# defined
     17      1.1       mrg STRIPFLAG=
     18      1.1       mrg 
     19      1.1       mrg # deal with Solaris vs. NetBSD build environments for now ..
     20      1.1       mrg OS!=uname -s
     21      1.1       mrg .if (${OS} == "NetBSD")
     22      1.1       mrg USE_GENASSYM?=	no
     23      1.1       mrg SVR4=
     24      1.1       mrg .else
     25      1.1       mrg USE_GENASSYM?=	yes
     26      1.1       mrg SVR4=-U__SVR4 -U__svr4__ -D__NetBSD__
     27      1.1       mrg .endif
     28      1.1       mrg 
     29      1.1       mrg INCLUDES=	-I. -I$S/arch -I$S -nostdinc
     30      1.1       mrg CPPFLAGS=	${INCLUDES} ${IDENT} ${PARAM} -D_LKM ${SVR4}
     31      1.1       mrg 
     32      1.1       mrg #all:: bootblk.text bootblk
     33      1.1       mrg 
     34      1.1       mrg #clean:: 
     35      1.1       mrg #	rm assym.fth.h bootblk.text machine bootblk
     36      1.1       mrg 
     37      1.1       mrg sparc:
     38      1.1       mrg 	ln -s ${.CURDIR}/../../../sparc/include sparc
     39      1.1       mrg 
     40      1.1       mrg machine:
     41      1.1       mrg 	ln -s ${.CURDIR}/../../../${MACHINE}/include machine
     42      1.1       mrg 
     43      1.1       mrg assym.fth.h: ${.CURDIR}/genassym.sh genfth.cf machine
     44      1.1       mrg 	sh ${.CURDIR}/genassym.sh ${CC} ${CFLAGS} ${CPPFLAGS} ${PROF} \
     45      1.1       mrg 	    <${.CURDIR}/genfth.cf >assym.fth.h.tmp && \
     46      1.1       mrg 	    mv -f assym.fth.h.tmp assym.fth.h
     47      1.1       mrg 
     48      1.1       mrg bootblk.text: bootblk.fth assym.fth.h
     49      1.1       mrg 	awk '/fload/ { print "#include \"" $$2 "\"" }; !/fload/' \
     50      1.1       mrg 	    ${.CURDIR}/bootblk.fth | /usr/bin/cpp -P >bootblk.text.tmp &&
     51      1.1       mrg 	    mv -f bootblk.text.tmp bootblk.text
     52      1.1       mrg 
     53      1.1       mrg bootblk: bootblk.fth assym.fth.h
     54  1.1.8.2  jdolecek 	${FGEN} -o bootblk ${.CURDIR}/bootblk.fth
     55      1.1       mrg 
     56      1.1       mrg beforedepend:
     57      1.1       mrg 	@touch .depend
     58      1.1       mrg 
     59      1.1       mrg #
     60      1.1       mrg # The following are if you grab the fakeboot program from the Sun website
     61      1.1       mrg #
     62      1.1       mrg 
     63      1.1       mrg fake: bootblk bootblk.text
     64      1.1       mrg 	../fakeboot/fakeboot -elf32 <bootblk >/bootblk
     65      1.1       mrg 	../fakeboot/fakeboot -elf32 <bootblk.text >/bootblk.text
     66      1.1       mrg 
     67      1.1       mrg .include <bsd.prog.mk>
     68