Makefile revision 1.32
1# $NetBSD: Makefile,v 1.32 2003/09/30 06:26:37 lukem Exp $ 2 3# The `all' target must appear before bsd.own.mk is pulled in. 4all: 5 @echo "Please understand what you are doing, first." 6 @false 7 8.include <bsd.own.mk> 9.include "${NETBSDSRCDIR}/distrib/common/Makefile.distrib" 10 11SETSENV= DESTDIR=${DESTDIR:Q} \ 12 MACHINE=${MACHINE:Q} MACHINE_ARCH=${MACHINE_ARCH:Q} \ 13 CKSUM=${TOOL_CKSUM:Q} MAKE=${MAKE:Q} MTREE=${TOOL_MTREE:Q} \ 14 MKTEMP=${TOOL_MKTEMP:Q} PAX=${TOOL_PAX:Q} 15 16print_have_gcc3: 17 @echo ${HAVE_GCC3} 18 19print_machine: .PHONY 20 @echo ${MACHINE} 21 22print_machine_arch: .PHONY 23 @echo ${MACHINE_ARCH} 24 25print_machine_cpu: .PHONY 26 @echo ${MACHINE_CPU} 27 28print_object_fmt: .PHONY 29 @echo ${OBJECT_FMT} 30 31print_toolchain_missing: .PHONY 32 @echo "${TOOLCHAIN_MISSING}" 33 34print_use_tools_toolchain: .PHONY 35 @echo "${USE_TOOLS_TOOLCHAIN}" 36 37print_x11_version: .PHONY 38.if defined(USE_XF86_4) && (${USE_XF86_4} != no) 39 @echo 4 40.else 41 @echo 3 42.endif 43 44# This target has debugging value only, really. 45makeflist: .PHONY check_DESTDIR 46 ${SETSENV} ${HOST_SH} ${.CURDIR}/makeflist 47 48# 49# SET BUILDING TARGETS 50# 51 52.if ${MKUNPRIVED} == "no" 53METALOG.unpriv= 54.else 55METALOG.unpriv= -M ${METALOG} 56.endif 57 58.PRECIOUS: checkflist 59checkflist: check_DESTDIR 60 ${SETSENV} ${HOST_SH} ${.CURDIR}/checkflist ${CHECKFLIST_FLAGS} \ 61 ${METALOG.unpriv} 62 63.PRECIOUS: checkflist-x11 64checkflist-x11: check_DESTDIR 65 ${SETSENV} ${HOST_SH} ${.CURDIR}/checkflist -x ${CHECKFLIST_FLAGS} 66 67.PRECIOUS: maketars 68maketars: check_DESTDIR check_RELEASEDIR 69.if defined(DESTDIR) && ${DESTDIR} != "" 70 ${MAKE} checkflist 71.endif 72 mkdir -p ${RELEASEDIR}/${MACHINE}/binary/sets 73 ${SETSENV} ${HOST_SH} ${.CURDIR}/maketars -d ${DESTDIR:S,^$,/,} \ 74 ${METALOG.unpriv} -N ${NETBSDSRCDIR}/etc \ 75 -t ${RELEASEDIR}/${MACHINE}/binary/sets ${MAKETARSETS} 76 77.PRECIOUS: makesrctars 78makesrctars: check_RELEASEDIR 79 mkdir -p ${RELEASEDIR}/source/sets 80 ${SETSENV} ${HOST_SH} ${.CURDIR}/makesrctars \ 81 ${NETBSDSRCDIR} ${RELEASEDIR}/source/sets 82 83.PRECIOUS: makesums 84makesums: check_RELEASEDIR 85 ${SETSENV} ${MAKESUMS} -t ${RELEASEDIR}/${MACHINE}/binary/sets 86 87.PRECIOUS: installsets 88installsets: check_DESTDIR 89.if !defined(INSTALLDIR) 90 @echo "setenv INSTALLDIR before doing that!" 91 @false 92.endif 93 ${SETSENV} ${HOST_SH} ${.CURDIR}/maketars -d ${DESTDIR:S,^$,/,} \ 94 ${METALOG.unpriv} -N ${NETBSDSRCDIR}/etc \ 95 -i ${INSTALLDIR} ${INSTALLSETS} 96 97# 98# MAIN ENTRY POINTS 99# 100 101sets: maketars .WAIT makesums 102 @true 103 104sourcesets: makesrctars 105 @true 106 107.include <bsd.sys.mk> 108