Makefile.powerpc revision 1.20
1#	$NetBSD: Makefile.powerpc,v 1.20 2001/12/09 05:00:49 atatat 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/powerpc/conf/``machineid''
9# after which you should do
10#	config machineid
11# Machine generic makefile changes should be made in
12#	/sys/arch/powerpc/conf/Makefile.powerpc
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=powerpc
21USETOOLS?=	no
22NEED_OWN_INSTALL_TARGET?=no
23.include <bsd.own.mk>
24
25##
26## (1) port identification
27##
28THISPPC=	$S/arch/${MACHINE}
29POWERPC=	$S/arch/powerpc
30GENASSYM=	${THISPPC}/${MACHINE}/genassym.cf
31.-include "${THISPPC}/conf/Makefile.${MACHINE}.inc"
32
33##
34## (2) compile settings
35##
36CPPFLAGS+=	-D${MACHINE}
37CWARNFLAGS+=	-Wreturn-type
38CFLAGS+=	-msoft-float ${CCPUOPTS}
39AFLAGS+=	${AOPTS}
40
41##
42## (3) libkern and compat
43##
44
45##
46## (4) local objects, compile rules, and dependencies
47##
48MD_OBJS=	locore.o
49MD_CFILES=
50MS_SFILES=	${THISPPC}/${MACHINE}/locore.S
51
52locore.o: ${THISPPC}/${MACHINE}/locore.S assym.h
53	${NORMAL_S}
54
55##
56## (5) link settings
57##
58TEXTADDR?=	0x100000
59LINKFORMAT=	-N
60ENTRYPOINT=	__start
61
62.if defined(NEED_SREC)
63SYSTEM_LD_TAIL_EXTRA=; \
64		${OBJCOPY} -v -O srec $@ $@.srec
65.endif
66
67##
68## (6) port specific target dependencies
69##
70
71# depend on CPU configuration
72locore.o machdep.o: Makefile
73
74##
75## (7) misc settings
76##
77
78##
79## (8) config(8) generated machinery
80##
81%INCLUDES
82
83%OBJS
84
85%CFILES
86
87%SFILES
88
89%LOAD
90
91%RULES
92
93##
94## (9) port independent kernel machinery
95##
96.include "$S/conf/Makefile.kern.inc"
97