1 1.19.2.3 nathanw # $NetBSD: Makefile.powerpc,v 1.19.2.3 2002/01/11 23:38:41 nathanw Exp $ 2 1.19.2.2 nathanw # 3 1.19.2.2 nathanw # Makefile for NetBSD 4 1.19.2.2 nathanw # 5 1.19.2.2 nathanw # This makefile is constructed from a machine description: 6 1.19.2.2 nathanw # config machineid 7 1.19.2.2 nathanw # Most changes should be made in the machine description 8 1.19.2.2 nathanw # /sys/arch/powerpc/conf/``machineid'' 9 1.19.2.2 nathanw # after which you should do 10 1.19.2.2 nathanw # config machineid 11 1.19.2.2 nathanw # Machine generic makefile changes should be made in 12 1.19.2.2 nathanw # /sys/arch/powerpc/conf/Makefile.powerpc 13 1.19.2.2 nathanw # after which config should be rerun for all machines of that type. 14 1.19.2.2 nathanw # 15 1.19.2.2 nathanw # To specify debugging, add the config line: makeoptions DEBUG="-g" 16 1.19.2.2 nathanw # A better way is to specify -g only for a few files. 17 1.19.2.2 nathanw # 18 1.19.2.2 nathanw # makeoptions DEBUGLIST="uvm* trap if_*" 19 1.19.2.2 nathanw 20 1.19.2.2 nathanw MACHINE_ARCH=powerpc 21 1.19.2.2 nathanw USETOOLS?= no 22 1.19.2.2 nathanw NEED_OWN_INSTALL_TARGET?=no 23 1.19.2.2 nathanw .include <bsd.own.mk> 24 1.19.2.2 nathanw 25 1.19.2.2 nathanw ## 26 1.19.2.2 nathanw ## (1) port identification 27 1.19.2.2 nathanw ## 28 1.19.2.2 nathanw THISPPC= $S/arch/${MACHINE} 29 1.19.2.2 nathanw POWERPC= $S/arch/powerpc 30 1.19.2.2 nathanw GENASSYM= ${THISPPC}/${MACHINE}/genassym.cf 31 1.19.2.2 nathanw .-include "${THISPPC}/conf/Makefile.${MACHINE}.inc" 32 1.19.2.2 nathanw 33 1.19.2.2 nathanw ## 34 1.19.2.2 nathanw ## (2) compile settings 35 1.19.2.2 nathanw ## 36 1.19.2.2 nathanw CPPFLAGS+= -D${MACHINE} 37 1.19.2.2 nathanw CWARNFLAGS+= -Wreturn-type 38 1.19.2.2 nathanw CFLAGS+= -msoft-float ${CCPUOPTS} 39 1.19.2.2 nathanw AFLAGS+= ${AOPTS} 40 1.19.2.2 nathanw 41 1.19.2.2 nathanw ## 42 1.19.2.2 nathanw ## (3) libkern and compat 43 1.19.2.2 nathanw ## 44 1.19.2.2 nathanw 45 1.19.2.2 nathanw ## 46 1.19.2.2 nathanw ## (4) local objects, compile rules, and dependencies 47 1.19.2.2 nathanw ## 48 1.19.2.2 nathanw MD_OBJS= locore.o 49 1.19.2.2 nathanw MD_CFILES= 50 1.19.2.3 nathanw MD_SFILES= ${THISPPC}/${MACHINE}/locore.S 51 1.19.2.2 nathanw 52 1.19.2.2 nathanw locore.o: ${THISPPC}/${MACHINE}/locore.S assym.h 53 1.19.2.2 nathanw ${NORMAL_S} 54 1.19.2.2 nathanw 55 1.19.2.2 nathanw ## 56 1.19.2.2 nathanw ## (5) link settings 57 1.19.2.2 nathanw ## 58 1.19.2.2 nathanw TEXTADDR?= 0x100000 59 1.19.2.2 nathanw LINKFORMAT= -N 60 1.19.2.2 nathanw ENTRYPOINT= __start 61 1.19.2.2 nathanw 62 1.19.2.2 nathanw .if defined(NEED_SREC) 63 1.19.2.2 nathanw SYSTEM_LD_TAIL_EXTRA=; \ 64 1.19.2.2 nathanw ${OBJCOPY} -v -O srec $@ $@.srec 65 1.19.2.2 nathanw .endif 66 1.19.2.2 nathanw 67 1.19.2.2 nathanw ## 68 1.19.2.2 nathanw ## (6) port specific target dependencies 69 1.19.2.2 nathanw ## 70 1.19.2.2 nathanw 71 1.19.2.2 nathanw # depend on CPU configuration 72 1.19.2.2 nathanw locore.o machdep.o: Makefile 73 1.19.2.2 nathanw 74 1.19.2.2 nathanw ## 75 1.19.2.2 nathanw ## (7) misc settings 76 1.19.2.2 nathanw ## 77 1.19.2.2 nathanw 78 1.19.2.2 nathanw ## 79 1.19.2.2 nathanw ## (8) config(8) generated machinery 80 1.19.2.2 nathanw ## 81 1.19.2.2 nathanw %INCLUDES 82 1.19.2.2 nathanw 83 1.19.2.2 nathanw %OBJS 84 1.19.2.2 nathanw 85 1.19.2.2 nathanw %CFILES 86 1.19.2.2 nathanw 87 1.19.2.2 nathanw %SFILES 88 1.19.2.2 nathanw 89 1.19.2.2 nathanw %LOAD 90 1.19.2.2 nathanw 91 1.19.2.2 nathanw %RULES 92 1.19.2.2 nathanw 93 1.19.2.2 nathanw ## 94 1.19.2.2 nathanw ## (9) port independent kernel machinery 95 1.19.2.2 nathanw ## 96 1.19.2.2 nathanw .include "$S/conf/Makefile.kern.inc" 97