2000-01-23 20:04:03 +03:00
|
|
|
# $NetBSD: Makefile.buildboot,v 1.11 2000/01/23 17:04:05 mycroft Exp $
|
1997-02-04 06:51:37 +03:00
|
|
|
|
|
|
|
S= ${.CURDIR}/../../../..
|
|
|
|
|
|
|
|
.PATH: ${.CURDIR}/../common
|
|
|
|
|
|
|
|
PROG= ${PROGAOUT}.lif
|
|
|
|
|
|
|
|
SRCS= ${COMMONSOURCE} ${DRIVERSOURCE} ${PROGSOURCE}
|
1999-02-13 05:54:17 +03:00
|
|
|
MKMAN= no
|
1997-04-17 11:27:46 +04:00
|
|
|
STRIPFLAG=
|
1997-02-04 06:51:37 +03:00
|
|
|
BINMODE= 444
|
|
|
|
|
1999-12-22 00:06:26 +03:00
|
|
|
.PHONY: machine-links
|
|
|
|
beforedepend: machine-links
|
|
|
|
# ${MACHINE} then ${MACHINE_ARCH}
|
|
|
|
machine-links:
|
|
|
|
-rm -f machine && \
|
|
|
|
ln -s $S/arch/hp300/include machine
|
|
|
|
-rm -f hp300 && \
|
|
|
|
ln -s $S/arch/hp300/include hp300
|
|
|
|
CLEANFILES+=machine hp300
|
|
|
|
|
2000-01-23 20:04:03 +03:00
|
|
|
realall: machine-links ${PROG}
|
1999-12-22 00:06:26 +03:00
|
|
|
|
1997-02-04 06:51:37 +03:00
|
|
|
CLEANFILES+= ${PROGAOUT} vers.c vers.o
|
|
|
|
|
1999-12-22 00:06:26 +03:00
|
|
|
CPPFLAGS+= -I${.CURDIR}/../../.. -I${.CURDIR}/../../../.. -I${.OBJDIR}
|
1999-12-15 00:38:31 +03:00
|
|
|
CFLAGS= -Os -msoft-float
|
1997-02-04 06:51:37 +03:00
|
|
|
|
1999-12-14 23:54:04 +03:00
|
|
|
CPPFLAGS+= -DBOOT_AOUT
|
|
|
|
#CPPFLAGS+= -DBOOT_ELF
|
|
|
|
|
1997-02-04 06:51:37 +03:00
|
|
|
${PROG}: ${PROGAOUT} ${MKBOOT_PROG}
|
|
|
|
${MKBOOT_PROG} ${PROGAOUT} ${PROG}
|
|
|
|
|
|
|
|
.include <bsd.prog.mk>
|
|
|
|
|
1999-11-14 00:17:56 +03:00
|
|
|
### find out what to use for libkern
|
|
|
|
KERN_AS= library
|
|
|
|
.include "${S}/lib/libkern/Makefile.inc"
|
|
|
|
LIBKERN= ${KERNLIB}
|
|
|
|
|
1997-02-04 22:28:50 +03:00
|
|
|
### find out what to use for libz
|
|
|
|
Z_AS= library
|
|
|
|
.include "${S}/lib/libz/Makefile.inc"
|
|
|
|
LIBZ= ${ZLIB}
|
|
|
|
|
1997-02-04 06:51:37 +03:00
|
|
|
### find out what to use for libsa
|
|
|
|
SA_AS= library
|
1999-12-14 23:54:04 +03:00
|
|
|
SAMISCMAKEFLAGS+="SA_USE_CREAD=yes"
|
|
|
|
SAMISCMAKEFLAGS+="SA_USE_LOADFILE=yes"
|
1997-02-04 06:51:37 +03:00
|
|
|
.include "${S}/lib/libsa/Makefile.inc"
|
|
|
|
LIBSA= ${SALIB}
|
|
|
|
|
1999-11-14 00:17:56 +03:00
|
|
|
${PROGAOUT}: ${OBJS} ${LIBSA} ${LIBZ} ${LIBKERN}
|
1997-02-04 06:51:37 +03:00
|
|
|
sh ${.CURDIR}/../common/newvers.sh ${.CURDIR}/version ${NEWVERSWHAT}
|
|
|
|
${COMPILE.c} vers.c
|
|
|
|
${LD} -N -T ${RELOC} -e begin -o ${PROGAOUT} \
|
1999-11-14 00:17:56 +03:00
|
|
|
${OBJS} vers.o ${LIBSA} ${LIBZ} ${LIBKERN}
|
1997-02-04 06:51:37 +03:00
|
|
|
@size ${PROGAOUT}
|
|
|
|
@echo ${PROGAOUT} total size should not exceed 1044480 bytes
|