Makefile revision 1.1
11.1SisNOPROG=	installboot
21.1SisMAN=installboot.8
31.1Sis
41.1SisSUBDIR=aout2bb txlt
51.1Sis
61.1SisTXLT=txlt/txlt
71.1Sis
81.1SisOBJS = configure.o main.o
91.1SisOBJS += console.o xd.o
101.1Sis
111.1Sis# libsa library replacements:
121.1SisOBJS += alloc.o printf.o twiddle.o
131.1Sis
141.1Sis# libkern replacements:
151.1SisOBJS += bcopy.o bzero.o ashrdi3.o muldi3.o
161.1Sis
171.1Sis# machine language startup code:
181.1SisOBJS += startit.o
191.1Sis
201.1SisSRCS = installboot.sh configure.c main.c console.c xd.c 
211.1SisSRCS+= twiddle.c
221.1SisSRCS+= bbstart.s libstubs.s alloc.s printf.s startit.s
231.1SisSRCS+= bcopy.s bzero.c ashrdi3.s muldi3.s
241.1Sis
251.1SisCLEANFILES = $(OBJS) $(BOOTBLOCKS) x.out xxstart.s f.out fdstart.s
261.1Sis
271.1SisS=	${.CURDIR}/../../../..
281.1SisINCPATH=-I${.CURDIR} -I${.CURDIR}/../.. -I${S} -I${S}/lib/libsa
291.1SisCOPTIM=	-O2 -fomit-frame-pointer -fno-function-cse -Wa,-l -m68060 -Wa,-m68030
301.1SisCFLAGS = ${COPTIM} ${INCPATH} ${DEFS}
311.1SisCOPTS += -Wall -Wstrict-prototypes
321.1Sis
331.1SisBOOTBLOCKS=xxboot # XXX  fdboot is too large at the moment.
341.1Sis
351.1Sis.s.o: ; $(CC) $(CAFLAGS) $(COPTS) -x assembler-with-cpp -o $*.o -c $*.s
361.1Sis
371.1Sis#libs:
381.1Sis
391.1Sis.include "${.CURDIR}/libsa/Makefile.inc"
401.1SisLIBSA=  ${SA_LIB}
411.1Sis
421.1Sis# libstubs should really be a library, but we don't care for now.
431.1SisLIBS=	${LIBSA} ${LIBKERN} libstubs.o
441.1Sis
451.1Sisall: $(BOOTBLOCKS) installboot
461.1Sis
471.1Sis$(OBJS): txlt
481.1Sis
491.1Sisxxstart.s: bbstart.s
501.1Sis	cpp bbstart.s > $@
511.1Sis	
521.1Sisfdstart.s: bbstart.s
531.1Sis	cpp -DAUTOLOAD=8192 bbstart.s > $@
541.1Sis
551.1Sisx.out: xxstart.o $(OBJS) $(LIBS)
561.1Sis	$(LD) $(LDFLAGS) -r -dc -e _start -o x.out xxstart.o $(OBJS) $(LIBS)
571.1Sis	size x.out
581.1Sis
591.1Sisf.out: fdstart.o $(OBJS) $(LIBS)
601.1Sis	$(LD) $(LDFLAGS) -r -dc -e _start -o f.out fdstart.o $(OBJS) $(LIBS)
611.1Sis	size f.out
621.1Sis
631.1Sis
641.1Sis$(BOOTBLOCKS): aout2bb
651.1Sis
661.1Sisxxboot: x.out
671.1Sis	rm -f $@
681.1Sis	aout2bb/aout2bb x.out $@ || nm -u x.out
691.1Sis
701.1Sisfdboot: f.out
711.1Sis	rm -f $@
721.1Sis	aout2bb/aout2bb -F f.out $@ || nm -u f.out
731.1Sis
741.1Sisclean::
751.1Sis	rm -f $(OBJS) fdstart.[os] xxstart.[os] f.out x.out installboot
761.1Sis
771.1Sisinstall: all maninstall
781.1Sis	install -o $(BINOWN) -g $(BINGRP) $(BOOTBLOCKS) /usr/mdec
791.1Sis	install -o $(BINOWN) -g $(BINGRP) installboot /usr/sbin
801.1Sis
811.1Sisci:
821.1Sis	ci -l $(SRCS) Makefile
831.1Sis
841.1Sistar:
851.1Sis	(cd ..; tar \
861.1Sis		--exclude '*.o' --exclude RCS --exclude .depend \
871.1Sis		--exclude '*.out' --exclude fdstart.s --exclude xxstart.s \
881.1Sis		--exclude aout2bb/aout2bb --exclude libsa.a \
891.1Sis		-czvf boot.tar.gz boot)
901.1Sis
911.1Sistest: xxtest fdtest
921.1Sis
931.1Sisxxtest: xxboot
941.1Sis	dd if=$? of=/dev/rsd1e bs=8192 count=1
951.1Sis
961.1Sisfdtest: fdboot
971.1Sis	dd if=$? of=/dev/rfd0a bs=8192 count=1
981.1Sis
991.1Sis.include <bsd.prog.mk>
1001.1Sis.include "Makefile.txlt"
101