1 1.14 chs # $NetBSD: Makefile,v 1.14 2002/09/21 01:18:40 chs Exp $ 2 1.1 thorpej 3 1.1 thorpej S= ${.CURDIR}/../../../.. 4 1.1 thorpej 5 1.1 thorpej PROG= ofwboot 6 1.10 thorpej SRCS= Locore.c alloc.c boot.c ofdev.c net.c netif_of.c vers.c 7 1.10 thorpej CFLAGS+= -msoft-float -Wno-main 8 1.10 thorpej #CPPFLAGS+= -DDEBUG -DNETIF_DEBUG 9 1.10 thorpej CPPFLAGS+= -D_STANDALONE -DSUPPORT_DHCP -I${.CURDIR} 10 1.10 thorpej DBG= -Os -mmultiple 11 1.10 thorpej 12 1.1 thorpej SRCS+= ofwmagic.S 13 1.5 sakamoto .PATH: ${S}/arch/powerpc/powerpc 14 1.12 itojun 15 1.12 itojun SRCS+= byteorder.c 16 1.12 itojun .PATH: ${S}/lib/libsa 17 1.10 thorpej 18 1.11 tv NOMAN= # defined 19 1.2 thorpej STRIPFLAG= 20 1.1 thorpej BINMODE= 444 21 1.1 thorpej 22 1.1 thorpej NEWVERSWHAT= "OpenFirmware Boot" 23 1.1 thorpej 24 1.1 thorpej # For now... 25 1.1 thorpej RELOC= 20000 26 1.1 thorpej 27 1.1 thorpej ENTRY= _start 28 1.1 thorpej 29 1.14 chs CLEANFILES+= vers.c 30 1.1 thorpej 31 1.10 thorpej CPPFLAGS+= -I. -I${.CURDIR}/../../.. -I${.CURDIR}/../../../.. 32 1.1 thorpej CPPFLAGS+= -DRELOC=0x${RELOC} 33 1.1 thorpej CPPFLAGS+= -DFIRMWORKSBUGS 34 1.3 drochner CPPFLAGS+= -DCOMPAT_386BSD_MBRPART 35 1.1 thorpej 36 1.7 wrstuden .BEGIN: 37 1.7 wrstuden @[ -h machine ] || ln -s ${S}/arch/${MACHINE}/include machine 38 1.7 wrstuden @[ -h powerpc ] || ln -s ${S}/arch/powerpc/include powerpc 39 1.8 mycroft .NOPATH: machine powerpc 40 1.8 mycroft CLEANFILES+= machine powerpc 41 1.5 sakamoto 42 1.1 thorpej ### find out what to use for libkern 43 1.1 thorpej KERN_AS= library 44 1.1 thorpej .include "${S}/lib/libkern/Makefile.inc" 45 1.1 thorpej LIBKERN= ${KERNLIB} 46 1.1 thorpej 47 1.1 thorpej ### find out what to use for libz 48 1.1 thorpej Z_AS= library 49 1.1 thorpej .include "${S}/lib/libz/Makefile.inc" 50 1.1 thorpej LIBZ= ${ZLIB} 51 1.1 thorpej 52 1.1 thorpej ### find out what to use for libsa 53 1.1 thorpej SA_AS= library 54 1.10 thorpej SAMISCMAKEFLAGS= SA_USE_CREAD=yes SA_USE_LOADFILE=yes 55 1.1 thorpej .include "${S}/lib/libsa/Makefile.inc" 56 1.1 thorpej LIBSA= ${SALIB} 57 1.1 thorpej 58 1.9 jdolecek .PHONY: vers.c 59 1.9 jdolecek vers.c: version 60 1.9 jdolecek sh ${S}/conf/newvers_stand.sh ${.CURDIR}/version "ofppc" ${NEWVERSWHAT} 61 1.13 chs 62 1.1 thorpej ${PROG}: ${OBJS} ${LIBSA} ${LIBZ} ${LIBKERN} 63 1.13 chs ${LD} -s -N -Ttext ${RELOC} -Bstatic -e ${ENTRY} -o ${PROG}.X \ 64 1.9 jdolecek ${OBJS} ${LIBSA} ${LIBZ} ${LIBKERN} 65 1.13 chs mv -f ${PROG}.X ${PROG} 66 1.1 thorpej 67 1.1 thorpej .include <bsd.prog.mk> 68