Makefile.alpha revision 1.69
1# $NetBSD: Makefile.alpha,v 1.69 2001/11/20 12:56:19 lukem Exp $
2
3# Makefile for NetBSD
4#
5# This makefile is constructed from a machine description:
6#	config machineid
7# Most changes should be made in the machine description
8#	/sys/arch/alpha/conf/``machineid''
9# after which you should do
10#	config machineid
11# Machine generic makefile changes should be made in
12#	/sys/arch/alpha/conf/Makefile.alpha
13# after which config should be rerun for all machines of that type.
14#
15# To specify debugging, add the config line: makeoptions DEBUG="-g"
16# A better way is to specify -g only for a few files.
17#
18#	makeoptions DEBUGLIST="uvm* trap if_*"
19
20MACHINE_ARCH=	alpha
21USETOOLS?=	no
22NEED_OWN_INSTALL_TARGET?=no
23.include <bsd.own.mk>
24
25##
26## (1) port identification
27##
28ALPHA=		$S/arch/alpha
29GENASSYM=	${ALPHA}/alpha/genassym.cf
30MD_CPPFLAGS=	-Dalpha
31
32##
33## (2) compile settings
34##
35CPPFLAGS=	${INCLUDES} ${IDENT} ${PARAM} -D_KERNEL -D_KERNEL_OPT \
36		${MD_CPPFLAGS}
37COPTS?=		-O2
38CFLAGS=		${DEBUG} ${COPTS} ${CWARNFLAGS} -mno-fp-regs
39AFLAGS=		-traditional -D_LOCORE
40NORMAL_S=	${CPP} ${AFLAGS} ${CPPFLAGS} $< | sed -e 's,^\#.*,,' | ${AS} -o ${.TARGET}
41
42##
43## (3) libkern and compat
44##
45
46##
47## (4) local objects, compile rules, and dependencies
48##
49MD_OBJS=	locore.o transfer.o
50MD_CFILES=
51MD_SFILES=	${ALPHA}/alpha/locore.s ${ALPHA}/alpha/transfer.s
52
53locore.o: ${ALPHA}/alpha/locore.s assym.h
54	${NORMAL_S}
55
56transfer.o: ${ALPHA}/alpha/transfer.s
57	${NORMAL_S}
58
59##
60## (5) link settings
61##
62LINKFORMAT=	-N
63TEXTADDR?=	fffffc0000300000
64EXTRA_LINKFLAGS=	-G 4
65LINKFLAGS_DEBUG=	-X
66LINKFLAGS_NORMAL=	-S
67STRIPFLAGS=	-g -X
68
69##
70## (6) port specific target dependencies
71##
72
73# depend on CPU configuration
74clock.o apecs.o cia.o lca.o ioasic.o scc.o icasic.o: Makefile
75
76##
77## (7) misc settings
78##
79MKDEP_AFLAGS=	-x assembler-with-cpp ${AFLAGS}
80
81##
82## (8) config(8) generated machinery
83##
84%INCLUDES
85
86%OBJS
87
88%CFILES
89
90%SFILES
91
92%LOAD
93
94%RULES
95
96##
97## (9) port independent kernel machinery
98##
99.include "$S/conf/Makefile.kern.inc"
100