1 1.16 tsutsui # $NetBSD: Makefile.inc,v 1.16 2009/02/28 16:11:39 tsutsui Exp $ 2 1.1 mycroft # 3 1.6 is # Configuration variables (default values are below): 4 1.6 is # 5 1.6 is # S must be set to the top of the 'sys' tree. 6 1.6 is # FPSPDST may be set to the location of the directory where library 7 1.6 is # objects are to be built. Defaults to ${.OBJDIR}/lib/kern. 8 1.6 is # FPSP_AS isn't there. We always build an object file. 9 1.6 is # FPSPMISCCPPFLAGS 10 1.6 is # Miscellaneous cpp flags to be passed to the library's Makefile 11 1.6 is # when building. 12 1.6 is # FPSPMISCMAKEFLAGS 13 1.6 is # Miscellaneous flags to be passed to the library's Makefile when 14 1.6 is # building. See library's Makefile for more details about 15 1.6 is # supported flags and their default values. 16 1.1 mycroft 17 1.6 is # Default values: 18 1.6 is FPSPDST?= ${.OBJDIR}/lib/fpsp 19 1.12 chs FPSPDOTDIR?= ../../. 20 1.1 mycroft 21 1.12 chs FPSPDIR= ${S:S@^.@${FPSPDOTDIR}@:Q}/arch/m68k/fpsp 22 1.6 is FPSPOBJ= ${FPSPDST}/fpsp.o 23 1.16 tsutsui HAS_FPSP!= grep '^\#define FPSP 1$$' opt_fpsp.h || echo 24 1.16 tsutsui .if !empty(HAS_FPSP) 25 1.16 tsutsui FPSP= ${FPSPOBJ} 26 1.16 tsutsui .endif 27 1.1 mycroft 28 1.6 is # CC=${CC:Q} CFLAGS=${CFLAGS:Q} \ 29 1.6 is # AS=${AS:Q} AFLAGS=${AFLAGS:Q} \ 30 1.10 tsutsui # LD=${LD:Q} STRIP=${STRIP:Q} \ 31 1.6 is 32 1.6 is FPSPMAKE= \ 33 1.12 chs cd ${FPSPDST} && ${MAKE} -f ${FPSPDIR:Q}/Makefile \ 34 1.12 chs FPSPDIR=${FPSPDIR:Q} \ 35 1.12 chs CC=${CC:Q} CFLAGS=${CFLAGS:Q} \ 36 1.12 chs LD=${LD:Q} STRIP=${STRIP:Q} \ 37 1.12 chs MACHINE=${MACHINE} \ 38 1.12 chs MACHINE_ARCH=${MACHINE_ARCH:Q} \ 39 1.12 chs FPSPCPPFLAGS=${CPPFLAGS:S@^-I.@-I${FPSPDOTDIR}@g:Q} \ 40 1.6 is FPSPMISCCPPFLAGS=${FPSPMISCCPPFLAGS:Q} \ 41 1.6 is FPSPDIR=${FPSPDIR:Q} \ 42 1.6 is ${FPSPMISCMAKEFLAGS} 43 1.6 is 44 1.6 is ${FPSP}: .NOTMAIN __always_make_fpsp 45 1.6 is @echo making sure the 68040 FPSP is up to date... 46 1.6 is @${FPSPMAKE} fpsp.o 47 1.6 is 48 1.6 is ${FPSPLIB_PROF}: .NOTMAIN __always_make_fpsp 49 1.6 is @echo making sure the profiled 68040 FPSP is up to date... 50 1.6 is @${FPSPMAKE} fpsp.po 51 1.6 is 52 1.6 is clean: .NOTMAIN cleanfpsp 53 1.6 is cleanfpsp: .NOTMAIN __always_make_fpsp 54 1.6 is @echo cleaning the 68040 FPSP objects 55 1.6 is @${FPSPMAKE} clean 56 1.6 is 57 1.8 is cleandir distclean: .NOTMAIN cleandirfpsp 58 1.8 is cleandirfpsp: .NOTMAIN __always_make_fpsp 59 1.8 is # So we don't really need a cleandir target without a depend target. 60 1.8 is # On the other hand, were "make cleandir" in the kernel build 61 1.8 is # directory to fail to remove all the floating point objects, that 62 1.8 is # would tend to violate the principle of least surprise! 63 1.8 is @echo cleandiring the 68040 FPSP objects 64 1.8 is @${FPSPMAKE} clean 65 1.6 is 66 1.6 is #depend: .NOTMAIN dependfpsp 67 1.6 is #dependfpsp: .NOTMAIN __always_make_fpsp 68 1.6 is # @echo depending the 68040 FPSP objects 69 1.6 is # @${FPSPMAKE} depend 70 1.6 is # 71 1.1 mycroft 72 1.6 is __always_make_fpsp: .NOTMAIN 73 1.6 is @(mkdir -p ${FPSPDST}) 74