1999-08-19 00:01:06 +04:00
|
|
|
# $NetBSD: Makefile,v 1.27 1999/08/18 20:01:06 cgd Exp $
|
1995-11-23 05:33:17 +03:00
|
|
|
|
1997-01-24 01:31:32 +03:00
|
|
|
PROG = boot
|
|
|
|
|
1999-04-02 07:20:00 +04:00
|
|
|
SRCS = start.S boot.c loadfile.c blkdev.c prom.c prom_disp.S OSFpal.c
|
|
|
|
SRCS+= filesystem.c prom_swpal.S booted_dev.c
|
1997-01-24 01:31:32 +03:00
|
|
|
|
1999-08-19 00:01:06 +04:00
|
|
|
# XXX for debugging primary and secondary together
|
|
|
|
# SRCS+= putstr.c putulong.c
|
|
|
|
|
1995-11-23 05:33:17 +03:00
|
|
|
BOOT_RELOC = ${SECONDARY_LOAD_ADDRESS}
|
1997-01-24 01:31:32 +03:00
|
|
|
|
1999-04-02 07:20:00 +04:00
|
|
|
CPPFLAGS += ${SECONDARY_CPPFLAGS} \
|
1999-04-05 10:42:14 +04:00
|
|
|
-DBOOT_TYPE_NAME='"Secondary"' \
|
1999-04-02 07:20:00 +04:00
|
|
|
-DLIBSA_SINGLE_DEVICE=blkdev \
|
|
|
|
-D"blkdevioctl(x,y,z)=EINVAL"
|
1997-01-24 01:31:32 +03:00
|
|
|
|
1999-04-02 07:11:57 +04:00
|
|
|
CLEANFILES+= vers.c vers.o ${PROG}.sym
|
1995-11-23 05:33:17 +03:00
|
|
|
|
1999-04-02 07:11:57 +04:00
|
|
|
${PROG}: ${PROG}.sym
|
|
|
|
@echo creating ${PROG} from ${PROG}.sym...
|
|
|
|
@objcopy --output-target=binary ${PROG}.sym ${PROG}
|
|
|
|
@chmod 644 ${PROG}
|
|
|
|
@ls -l ${PROG}
|
|
|
|
@${CHECKSIZE_CMD} ${PROG}.sym ${PROG} ${SECONDARY_MAX_LOAD} \
|
|
|
|
${SECONDARY_MAX_TOTAL} || (rm -f ${PROG} ; false)
|
1997-01-16 05:59:08 +03:00
|
|
|
|
1999-04-02 07:11:57 +04:00
|
|
|
SAMISCMAKEFLAGS= SA_INCLUDE_NET=no SA_USE_CREAD=yes
|
1998-03-28 03:21:35 +03:00
|
|
|
.include "../Makefile.bootprogs"
|
1995-11-23 05:33:17 +03:00
|
|
|
|
1997-01-24 01:31:32 +03:00
|
|
|
${PROG}.sym: ${OBJS} ${LIBSA} ${LIBZ} ${LIBKERN}
|
1999-04-05 10:56:23 +04:00
|
|
|
sh ${.CURDIR}/../common/newvers.sh ${.CURDIR}/version
|
1995-11-23 05:33:17 +03:00
|
|
|
${COMPILE.c} vers.c
|
1997-01-24 01:31:32 +03:00
|
|
|
${LD} -Ttext ${BOOT_RELOC} -N -e start -o ${PROG}.sym \
|
|
|
|
${OBJS} vers.o ${LIBSA} ${LIBZ} ${LIBSA} ${LIBKERN}
|
1998-03-28 03:21:35 +03:00
|
|
|
${SIZE} ${PROG}.sym
|