Home | History | Annotate | Line # | Download | only in altboot
Makefile revision 1.8.2.3
      1  1.8.2.2  rmind #	$NetBSD: Makefile,v 1.8.2.3 2011/04/21 01:41:22 rmind Exp $
      2  1.8.2.2  rmind 
      3  1.8.2.2  rmind S=		${.CURDIR}/../../../..
      4  1.8.2.2  rmind 
      5  1.8.2.2  rmind PROG=		altboot
      6  1.8.2.2  rmind FILES+=		${PROG}.bin ${PROG}.img
      7  1.8.2.2  rmind NOMAN=		# defined
      8  1.8.2.3  rmind SRCS=		entry.S main.c brdsetup.c pci.c devopen.c dev_net.c memfs.c
      9  1.8.2.3  rmind SRCS+=		nif.c fxp.c tlp.c rge.c skg.c stg.c
     10  1.8.2.3  rmind SRCS+=		dsk.c pciide.c siisata.c
     11  1.8.2.3  rmind SRCS+=		printf.c vers.c
     12  1.8.2.2  rmind CLEANFILES+=	vers.c ${PROG} ${PROG}.bin ${PROG}.img
     13  1.8.2.2  rmind CFLAGS+=	-Wall -Wno-main -ffreestanding -msoft-float -mmultiple
     14  1.8.2.2  rmind CFLAGS+=	-Wmissing-prototypes -Wstrict-prototypes -Wpointer-arith
     15  1.8.2.2  rmind CPPFLAGS+=	-D_STANDALONE -DSUPPORT_DHCP
     16  1.8.2.2  rmind #CPPFLAGS+=	-DCONSNAME=\"com\" -DCONSPORT=0x3f8 -DCONSSPEED=115200
     17  1.8.2.2  rmind #CPPFLAGS+=	-DCONSNAME=\"eumb\" -DCONSPORT=0x4600 -DCONSSPEED=57600
     18  1.8.2.2  rmind CPPFLAGS+=	-nostdinc -I. -I${.OBJDIR} -I${S}
     19  1.8.2.2  rmind DBG=		-Os
     20  1.8.2.2  rmind 
     21  1.8.2.2  rmind .include <bsd.own.mk>
     22  1.8.2.2  rmind 
     23  1.8.2.2  rmind # XXX SHOULD NOT NEED TO DEFINE THESE!
     24  1.8.2.2  rmind LIBCRT0=
     25  1.8.2.2  rmind LIBC=
     26  1.8.2.2  rmind LIBCRTBEGIN=
     27  1.8.2.2  rmind LIBCRTEND=
     28  1.8.2.2  rmind 
     29  1.8.2.2  rmind STRIPFLAG=
     30  1.8.2.2  rmind BINMODE=	444
     31  1.8.2.2  rmind 
     32  1.8.2.2  rmind RELOC=		1000000
     33  1.8.2.2  rmind ENTRY=		_start
     34  1.8.2.2  rmind 
     35  1.8.2.2  rmind .if !make(obj) && !make(clean) && !make(cleandir)
     36  1.8.2.2  rmind .BEGIN:
     37  1.8.2.2  rmind 	@[ -h machine ] || ln -s ${S}/arch/${MACHINE}/include machine
     38  1.8.2.2  rmind 	@[ -h powerpc ] || ln -s ${S}/arch/powerpc/include powerpc
     39  1.8.2.2  rmind .NOPATH: machine powerpc
     40  1.8.2.2  rmind .endif
     41  1.8.2.2  rmind CLEANFILES+= machine powerpc
     42  1.8.2.2  rmind 
     43  1.8.2.2  rmind ### find out what to use for libkern
     44  1.8.2.2  rmind KERN_AS=	library
     45  1.8.2.2  rmind .include "${S}/lib/libkern/Makefile.inc"
     46  1.8.2.2  rmind LIBKERN=	${KERNLIB}
     47  1.8.2.2  rmind 
     48  1.8.2.2  rmind ### find out what to use for libz
     49  1.8.2.2  rmind Z_AS=		library
     50  1.8.2.2  rmind .include "${S}/lib/libz/Makefile.inc"
     51  1.8.2.2  rmind LIBZ=		${ZLIB}
     52  1.8.2.2  rmind 
     53  1.8.2.2  rmind ### find out what to use for libsa
     54  1.8.2.2  rmind SA_AS=		library
     55  1.8.2.2  rmind SAMISCMAKEFLAGS= SA_USE_CREAD=yes SA_USE_LOADFILE=yes
     56  1.8.2.2  rmind .include "${S}/lib/libsa/Makefile.inc"
     57  1.8.2.2  rmind LIBSA=		${SALIB}
     58  1.8.2.2  rmind 
     59  1.8.2.2  rmind .PHONY: vers.c
     60  1.8.2.2  rmind vers.c: version
     61  1.8.2.2  rmind 	${HOST_SH} ${S}/conf/newvers_stand.sh -K \
     62  1.8.2.2  rmind 	    ${${MKREPRO} == "yes" :?:-D} ${.CURDIR}/version "sandpoint"
     63  1.8.2.2  rmind 
     64  1.8.2.2  rmind ${PROG}: ${OBJS} ${LIBSA} ${LIBZ} ${LIBKERN}
     65  1.8.2.2  rmind 	${LD} -N -Ttext ${RELOC} -Bstatic -e ${ENTRY} -o ${PROG} \
     66  1.8.2.2  rmind 	    ${OBJS} ${LIBSA} ${LIBZ} ${LIBKERN}
     67  1.8.2.2  rmind 	${OBJCOPY} -S -O binary ${PROG} ${PROG}.bin
     68  1.8.2.2  rmind 	${TOOL_MKUBOOTIMAGE} -A powerpc -T kernel -C none -O linux \
     69  1.8.2.2  rmind 	    -a 0x${RELOC} -n ${PROG} ${PROG}.bin ${PROG}.img
     70  1.8.2.2  rmind 
     71  1.8.2.2  rmind .include <bsd.prog.mk>
     72