Home | History | Annotate | Line # | Download | only in conf
Makefile.xen revision 1.7
      1 #	$NetBSD: Makefile.xen,v 1.7 2005/06/07 18:11:34 sjg Exp $
      2 #	NetBSD: Makefile.i386,v 1.132 2003/07/05 16:56:10 simonb Exp 
      3 
      4 # Makefile for NetBSD
      5 #
      6 # This makefile is constructed from a machine description:
      7 #	config machineid
      8 # Most changes should be made in the machine description
      9 #	/sys/arch/xen/conf/``machineid''
     10 # after which you should do
     11 #	config machineid
     12 # Machine generic makefile changes should be made in
     13 #	/sys/arch/xen/conf/Makefile.xen
     14 # after which config should be rerun for all machines of that type.
     15 #
     16 # To specify debugging, add the config line: makeoptions DEBUG="-g"
     17 # A better way is to specify -g only for a few files.
     18 #
     19 #	makeoptions DEBUGLIST="uvm* trap if_*"
     20 
     21 .include "$S/arch/xen/conf/Makefile.arch.inc"
     22 MACHINE_ARCH?=	i386
     23 USETOOLS?=	no
     24 NEED_OWN_INSTALL_TARGET?=no
     25 .include <bsd.own.mk>
     26 
     27 ##
     28 ## (1) port identification
     29 ##
     30 XEN=		$S/arch/xen
     31 GENASSYM_CONF=	${XEN}/${XEN_BUILD}/genassym.cf
     32 
     33 ##
     34 ## (2) compile settings
     35 ##
     36 CPPFLAGS+=	-D${XEN_BUILD}
     37 AFLAGS+=	-x assembler-with-cpp -traditional-cpp ${DBG}
     38 EXTRA_INCLUDES=	-I${.CURDIR}/xen-ma
     39 
     40 ##
     41 ## (3) libkern and compat
     42 ##
     43 KERN_AS=	obj
     44 
     45 ##
     46 ## (4) local objects, compile rules, and dependencies
     47 ##
     48 MD_OBJS=	locore.o spl.o vector.o
     49 MD_CFILES=
     50 MD_SFILES=	${XEN}/${XEN_BUILD}/locore.S ${XEN}/${XEN_BUILD}/spl.S \
     51 		${XEN}/${XEN_BUILD}/vector.S
     52 
     53 locore.o: ${XEN}/${XEN_BUILD}/locore.S assym.h
     54 	${NORMAL_S}
     55 
     56 spl.o: ${XEN}/${XEN_BUILD}/spl.S assym.h
     57 	${NORMAL_S}
     58 
     59 vector.o: ${XEN}/${XEN_BUILD}/vector.S assym.h
     60 	${NORMAL_S}
     61 
     62 .ifndef noBEGIN
     63 .if !make(obj) && !make(clean) && !make(cleandir)
     64 .BEGIN:
     65 .for A in ${XEN_MACHINE_ARCHS}
     66 	rm -f ${A}
     67 	ln -s $S/arch/${A}/include ${A}
     68 .endfor
     69 	-rm -rf xen-ma
     70 	mkdir xen-ma
     71 	ln -s ../${XEN_BUILD} xen-ma/machine
     72 .endif
     73 .endif
     74 
     75 ##
     76 ## (5) link settings
     77 ##
     78 TEXTADDR?=	c0100000
     79 LINKFLAGS_NORMAL=	-X
     80 .if (${OBJECT_FMT} == "ELF")
     81 KERN_LDSCRIPT?=	kern.ldscript
     82 LINKFORMAT=	-T $S/arch/${XEN_BUILD}/conf/${KERN_LDSCRIPT}
     83 .else
     84 LINKFORMAT=	-z
     85 .endif
     86 
     87 ##
     88 ## (6) port specific target dependencies
     89 ##
     90 
     91 freebsd_sigcode.o ibcs2_sigcode.o linux_sigcode.o: assym.h
     92 svr4_sigcode.o mach_sigcode.o: assym.h
     93 apmcall.o in_cksum.o pnpbioscall.o bioscall.o: assym.h
     94 mptramp.o: assym.h
     95 clock.o: config_time.h
     96 
     97 ##
     98 ## (7) misc settings
     99 ##
    100 
    101 ##
    102 ## (8) config(8) generated machinery
    103 ##
    104 %INCLUDES
    105 
    106 %OBJS
    107 
    108 %CFILES
    109 
    110 %SFILES
    111 
    112 %LOAD
    113 
    114 %RULES
    115 
    116 ##
    117 ## (9) port independent kernel machinery
    118 ##
    119 .include "$S/conf/Makefile.kern.inc"
    120 
    121 ##
    122 ## (10) Appending make options.
    123 ##
    124 %MAKEOPTIONSAPPEND
    125