xref: /netbsd-src/sys/arch/zaurus/stand/zbsdmod/Makefile (revision b05cccc3368896d6476b70402d5c4b19c52e0639)
1#	$NetBSD: Makefile,v 1.12 2019/10/26 10:10:14 tsutsui Exp $
2
3WARNS?=	4
4
5.include <bsd.init.mk>
6
7S=	${.CURDIR}/../../../..
8
9OBJS=	zbsdmod.o
10SRCS=	zbsdmod.c
11NOMAN=	# defined
12
13OBJCOPY_FLAGS=			\
14	-R .debug_abbrev	\
15	-R .debug_aranges	\
16	-R .debug_info		\
17	-R .debug_line		\
18	-R .debug_loc		\
19	-R .debug_ranges	\
20	-R .debug_str		\
21	-R .eh_frame
22
23realall: ${OBJS}
24	${OBJCOPY} ${OBJCOPY_FLAGS} ${.OBJDIR}/zbsdmod.o
25
26.include <bsd.klinks.mk>
27.include <bsd.prog.mk>
28
29afterinstall:
30	${INSTALL_FILE} ${INSTALL_COPY} -o root -g wheel -m 644 \
31		${OBJS} ${DESTDIR}/${BINDIR}
32
33CPUFLAGS=
34DBG=		-Os
35CFLAGS+=	-fno-strict-aliasing
36CFLAGS+=	-ffreestanding -nostdinc
37CFLAGS+=	${ARM_APCS_FLAGS} -mcpu=xscale
38CPPFLAGS+=	-DMACHINE=\"${MACHINE}\" -DUTS_RELEASE=\"2.4.20\"
39CPPFLAGS+=	-D_STANDALONE
40CPPFLAGS+=	-I${.OBJDIR} -I${S}
41
42release: check_RELEASEDIR
43	${HOST_INSTALL_FILE} -m ${NONBINMODE} ${OBJS} \
44	    ${RELEASEDIR}/${RELEASEMACHINEDIR}/installation
45