xref: /netbsd-src/sys/arch/vax/boot/xxboot_ustarfs/Makefile (revision cb37c506c962d1db25df74b273b08d735555b01f)
1#	$NetBSD: Makefile,v 1.9 2020/09/15 05:08:07 mrg Exp $
2
3S=	${.CURDIR}/../../../..
4
5.include <bsd.own.mk>
6
7.PATH:	${.CURDIR}/../xxboot
8
9PROG=	xxboot_ustarfs
10
11SRCS=	start.S bootxx.c romread.S str.S
12
13STRIPFLAG=
14CPPFLAGS+=-D_STANDALONE -DLIBSA_NO_FD_CHECKING -DLIBSA_NO_RAW_ACCESS \
15	-DLIBSA_NO_TWIDDLE -DLIBSA_SINGLE_DEVICE=rom \
16	-DLIBSA_NO_COMPAT_UFS \
17	-DLIBSA_NO_FS_SYMLINK -DLIBSA_NO_FS_CLOSE \
18	-DLIBSA_NO_FS_WRITE -DLIBSA_NO_FS_SEEK \
19	-DNEED_USTARFS
20BINDIR=	/usr/mdec
21
22CFLAGS=	-Os
23LIBC=
24
25SA_AS=	library
26.include "${S}/lib/libsa/Makefile.inc"
27LIBSA=	${SALIB}
28
29KERN_AS=library
30.include "${S}/lib/libkern/Makefile.inc"
31LIBKERN=${KERNLIB}
32
33CLEANFILES+= ${PROG}.out
34
35${PROG}: ${OBJS} ${LIBSA} ${LIBKERN}
36	${LD} -N -Ttext 100000 -o ${PROG}.out ${OBJS} ${LIBSA} ${LIBKERN}
37	${SIZE} ${PROG}.out
38	${OBJCOPY} -O binary ${PROG}.out ${PROG}
39
40COPTS.bootxx.c+=	${${ACTIVE_CC} == "gcc" && ${HAVE_GCC:U0} >= 9:? -Wno-error=array-bounds :}
41
42.include <bsd.prog.mk>
43