Makefile revision 1.18
1#	$NetBSD: Makefile,v 1.18 2002/12/12 08:54:25 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		MAKE=${MAKE:Q} MTREE=${MTREE:Q} PAX=${PAX:Q} 
14
15print_machine: .PHONY
16	@echo ${MACHINE}
17
18print_machine_arch: .PHONY
19	@echo ${MACHINE_ARCH}
20
21print_machine_cpu: .PHONY
22	@echo ${MACHINE_CPU}
23
24print_object_fmt: .PHONY
25	@echo ${OBJECT_FMT}
26
27print_toolchain_missing: .PHONY
28	@echo "${TOOLCHAIN_MISSING}"
29
30print_x11_version: .PHONY
31.if defined(USE_XF86_4) && (${USE_XF86_4} != no)
32	@echo 4
33.else
34	@echo 3
35.endif
36
37# This target has debugging value only, really.
38makeflist: .PHONY check_DESTDIR
39	${SETSENV} sh ${.CURDIR}/makeflist
40
41#
42# SET BUILDING TARGETS
43#
44
45.PRECIOUS: checkflist
46checkflist: check_DESTDIR
47	${SETSENV} sh ${.CURDIR}/checkflist ${UNPRIVED:D-M ${METALOG}}
48
49.PRECIOUS: checkflist-x11
50checkflist-x11: check_DESTDIR
51	${SETSENV} sh ${.CURDIR}/checkflist -x11
52
53.PRECIOUS: maketars
54maketars: check_DESTDIR check_RELEASEDIR
55.if (${DESTDIR} != "")
56	${MAKE} checkflist
57.endif
58	${SETSENV} sh ${.CURDIR}/maketars ${UNPRIVED:D-M ${METALOG}} \
59		-d ${DESTDIR} -t ${RELEASEDIR}/binary/sets ${MAKETARSETS}
60
61.PRECIOUS: makesums
62makesums: check_RELEASEDIR
63	${SETSENV} ${MAKESUMS} -t ${RELEASEDIR}/binary/sets
64
65.PRECIOUS: installsets
66installsets: check_DESTDIR
67.if !defined(INSTALLDIR)
68	@echo "setenv INSTALLDIR before doing that!"
69	@false
70.endif
71	${SETSENV} sh ${.CURDIR}/maketars ${UNPRIVED:D-M ${METALOG}} \
72		-d ${DESTDIR} -i ${INSTALLDIR} ${INSTALLSETS}
73
74#
75# MAIN ENTRY POINTS
76#
77
78sets: maketars .WAIT makesums
79	@true
80
81.include <bsd.sys.mk>
82