Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 06 Sep 2004 16:11:43 -0600 (MDT)
From:      "M. Warner Losh" <imp@bsdimp.com>
To:        arch@freebsd.org
Subject:   Change to output
Message-ID:  <20040906.161143.77047315.imp@bsdimp.com>

next in thread | raw e-mail | index | archive | help
----Next_Part(Mon_Sep__6_16:11:43_2004_055)--
Content-Type: Text/Plain; charset=us-ascii
Content-Transfer-Encoding: 7bit

Consider the following patch.  It includes the target being built as
well as the subdir in output for subdirectory recursion.  For small
projects, I'm sure that the current way of dealing is sufficent, but
it is hard to know what's going on in the middle of makeworld, and
this helps.  Here's some sample output from a world I'm running:

===> usr.sbin/zic (obj)
===> usr.sbin/zic/zic (obj)
===> usr.sbin/zic/zdump (obj)
===> usr.sbin/zzz (obj)
--------------------------------------------------------------
>>> stage 2.3: build tools
--------------------------------------------------------------
===> bin/csh (obj,build-tools)
===> bin/sh (obj,build-tools)
===> rescue/rescue (obj,build-tools)
===> rescue/rescue/rtquery (obj)
===> rescue/rescue/common (obj)
===> rescue/rescue/dst (obj)
===> rescue/rescue/minires (obj)
===> rescue/rescue/omapip (obj)
===> rescue/rescue/dhcpctl (obj)
===> rescue/rescue/client (obj)
===> rescue/rescue/omshell (obj)
===> rescue/rescue/doc (obj)
===> rescue/rescue/doc (obj)
===> lib/libncurses (obj,build-tools)
===> share/syscons/scrnmaps (obj,build-tools)
===> usr.bin/awk (obj,build-tools)
===> lib/libmagic (obj,build-tools)
===> usr.sbin/sysinstall (obj,build-tools)
===> gnu/usr.bin/cc/cc_tools (obj,depend,all)
===> kerberos5/tools (obj,depend,all)
===> kerberos5/tools/make-print-version (obj)
===> kerberos5/tools/make-roken (obj)
===> kerberos5/tools/asn1_compile (obj)
===> kerberos5/tools/make-print-version (depend)
===> kerberos5/tools/make-roken (depend)
===> kerberos5/tools/asn1_compile (depend)
===> kerberos5/tools/make-print-version (all)
===> kerberos5/tools/make-roken (all)
===> kerberos5/tools/asn1_compile (all)

notice how it explains nicely why it appears that asn1_compile is
built 3 times (it really isn't, but you have to do the obj, depend and
all parts).

I've been running these patches, or variations on the theme for over
two years now.  I'm thinking it would be good to commit to head.

Comments?

Warner


----Next_Part(Mon_Sep__6_16:11:43_2004_055)--
Content-Type: Text/Plain; charset=us-ascii
Content-Transfer-Encoding: 7bit
Content-Disposition: inline; filename="mk.diff"

Index: Makefile.inc1
===================================================================
RCS file: /home/imp/FreeBSD/CVS/src/Makefile.inc1,v
retrieving revision 1.443
diff -u -r1.443 Makefile.inc1
--- Makefile.inc1	26 Aug 2004 10:24:25 -0000	1.443
+++ Makefile.inc1	6 Sep 2004 16:40:18 -0000
@@ -675,7 +675,7 @@
 #
 legacy:
 .for _tool in tools/build
-	${_+_}@${ECHODIR} "===> ${_tool}"; \
+	${_+_}@${ECHODIR} "===> ${_tool} (obj,includes,depend,all,install)"; \
 	    cd ${.CURDIR}/${_tool}; \
 	    ${MAKE} DIRPRFX=${_tool}/ obj; \
 	    ${MAKE} DIRPRFX=${_tool}/ DESTDIR=${MAKEOBJDIRPREFIX}/legacy includes; \
@@ -750,7 +750,7 @@
     ${_crunchgen} \
     ${_gensnmptree} \
     ${_kbdcontrol}
-	${_+_}@${ECHODIR} "===> ${_tool}"; \
+	${_+_}@${ECHODIR} "===> ${_tool} (obj,depend,all,install)"; \
 		cd ${.CURDIR}/${_tool}; \
 		${MAKE} DIRPRFX=${_tool}/ obj; \
 		${MAKE} DIRPRFX=${_tool}/ depend; \
@@ -788,7 +788,7 @@
     usr.bin/awk \
     lib/libmagic \
     usr.sbin/sysinstall
-	${_+_}@${ECHODIR} "===> ${_tool}"; \
+	${_+_}@${ECHODIR} "===> ${_tool} (obj,build-tools)"; \
 		cd ${.CURDIR}/${_tool}; \
 		${MAKE} DIRPRFX=${_tool}/ obj; \
 		${MAKE} DIRPRFX=${_tool}/ build-tools
@@ -796,7 +796,7 @@
 .for _tool in \
     gnu/usr.bin/cc/cc_tools \
     ${_kerberos5_tools}
-	${_+_}@${ECHODIR} "===> ${_tool}"; \
+	${_+_}@${ECHODIR} "===> ${_tool} (obj,depend,all)"; \
 		cd ${.CURDIR}/${_tool}; \
 		${MAKE} DIRPRFX=${_tool}/ obj; \
 		${MAKE} DIRPRFX=${_tool}/ depend; \
@@ -840,7 +840,7 @@
     ${_crunchide} \
     ${_elf2exe} \
     ${_kgzip}
-	${_+_}@${ECHODIR} "===> ${_tool}"; \
+	${_+_}@${ECHODIR} "===> ${_tool} (obj,depend,all,install)"; \
 		cd ${.CURDIR}/${_tool}; \
 		${MAKE} DIRPRFX=${_tool}/ obj; \
 		${MAKE} DIRPRFX=${_tool}/ depend; \
@@ -933,7 +933,7 @@
 .for _lib in ${_startup_libs} ${_prebuild_libs:Nlib/libpam} ${_generic_libs}
 ${_lib}__L: .PHONY
 .if exists(${.CURDIR}/${_lib})
-	${_+_}@${ECHODIR} "===> ${_lib}"; \
+	${_+_}@${ECHODIR} "===> ${_lib} (depend,all,install)"; \
 		cd ${.CURDIR}/${_lib}; \
 		${MAKE} DIRPRFX=${_lib}/ depend; \
 		${MAKE} DIRPRFX=${_lib}/ all; \
@@ -945,7 +945,7 @@
 # static PAM library, and dynamic PAM library before dynamic PAM
 # modules.
 lib/libpam__L: .PHONY
-	${_+_}@${ECHODIR} "===> lib/libpam"; \
+	${_+_}@${ECHODIR} "===> lib/libpam (depend,all,install)"; \
 		cd ${.CURDIR}/lib/libpam; \
 		${MAKE} DIRPRFX=lib/libpam/ depend; \
 		${MAKE} DIRPRFX=lib/libpam/ -D_NO_LIBPAM_SO_YET all; \
@@ -959,11 +959,11 @@
 .for entry in ${SUBDIR}
 ${entry}.${__target}__D: .PHONY
 	${_+_}@if test -d ${.CURDIR}/${entry}.${MACHINE_ARCH}; then \
-		${ECHODIR} "===> ${DIRPRFX}${entry}.${MACHINE_ARCH}"; \
+		${ECHODIR} "===> ${DIRPRFX}${entry}.${MACHINE_ARCH} (${__target})"; \
 		edir=${entry}.${MACHINE_ARCH}; \
 		cd ${.CURDIR}/$${edir}; \
 	else \
-		${ECHODIR} "===> ${DIRPRFX}${entry}"; \
+		${ECHODIR} "===> ${DIRPRFX}${entry} (${__target})"; \
 		edir=${entry}; \
 		cd ${.CURDIR}/$${edir}; \
 	fi; \
Index: share/mk/bsd.subdir.mk
===================================================================
RCS file: /home/imp/FreeBSD/CVS/src/share/mk/bsd.subdir.mk,v
retrieving revision 1.45
diff -u -r1.45 bsd.subdir.mk
--- share/mk/bsd.subdir.mk	9 Aug 2004 10:54:05 -0000	1.45
+++ share/mk/bsd.subdir.mk	6 Sep 2004 16:25:36 -0000
@@ -44,11 +44,11 @@
 .if defined(SUBDIR) && !empty(SUBDIR) && !defined(NO_SUBDIR)
 	@${_+_}for entry in ${SUBDIR}; do \
 		if test -d ${.CURDIR}/$${entry}.${MACHINE_ARCH}; then \
-			${ECHODIR} "===> ${DIRPRFX}$${entry}.${MACHINE_ARCH}"; \
+			${ECHODIR} "===> ${DIRPRFX}$${entry}.${MACHINE_ARCH} (${.TARGET:realinstall=install})"; \
 			edir=$${entry}.${MACHINE_ARCH}; \
 			cd ${.CURDIR}/$${edir}; \
 		else \
-			${ECHODIR} "===> ${DIRPRFX}$$entry"; \
+			${ECHODIR} "===> ${DIRPRFX}$$entry (${.TARGET:realinstall=install})"; \
 			edir=$${entry}; \
 			cd ${.CURDIR}/$${edir}; \
 		fi; \

----Next_Part(Mon_Sep__6_16:11:43_2004_055)----



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20040906.161143.77047315.imp>