Home | History | Annotate | Line # | Download | only in common
Makefile revision 1.10
      1 #	$NetBSD: Makefile,v 1.10 2009/01/12 06:50:31 tsutsui Exp $
      2 
      3 S= ${.CURDIR}/../../../..
      4 
      5 NOMAN= # defined
      6 
      7 CFLAGS= -Os -Wall
      8 CFLAGS+= -Wmissing-prototypes -Wstrict-prototypes -Wpointer-arith
      9 
     10 CPPFLAGS+= -D_STANDALONE
     11 CPPFLAGS+= -DLIBSA_USE_MEMCPY -DLIBSA_USE_MEMSET
     12 CPPFLAGS+= -nostdinc -I${.OBJDIR} -I${S} -I.
     13 CPPFLAGS+= -D__daddr_t=int32_t
     14 AFLAGS= -D_LOCORE
     15 
     16 CLEANFILES+= machine m68k
     17 
     18 .if !make(obj) && !make(clean) && !make(cleandir)
     19 .PHONY: machine-links
     20 beforedepend: machine-links
     21 machine-links:
     22 	-rm -f machine
     23 	ln -s ${S}/arch/${MACHINE}/include machine
     24 	-rm -f ${MACHINE_ARCH}
     25 	ln -s ${S}/arch/${MACHINE_ARCH}/include ${MACHINE_ARCH}
     26 .endif
     27 
     28 .include <bsd.prog.mk>
     29 
     30 ### find out what to use for libkern
     31 KERN_AS= library
     32 .include "${S}/lib/libkern/Makefile.inc"
     33 LIBKERN= ${KERNLIB}
     34 
     35 ### find out what to use for libz
     36 Z_AS= library
     37 .include "${S}/lib/libz/Makefile.inc"
     38 LIBZ= ${ZLIB}
     39 
     40 ### find out what to use for libsa
     41 SA_AS= library
     42 SAMISCMAKEFLAGS= SA_USE_CREAD=yes SA_USE_LOADFILE=yes
     43 .include "${S}/lib/libsa/Makefile.inc"
     44 LIBSA= ${SALIB}
     45 
     46 LIBS= ${LIBSA} ${LIBZ} ${LIBKERN}
     47 
     48 realall: machine-links ${LIBS}
     49 
     50 cleandir distclean: cleanlibdir
     51 
     52 cleanlibdir:
     53 	-rm -rf lib
     54