From 0c401657e1ee979812445197b44ba8cdad773d86 Mon Sep 17 00:00:00 2001 From: Kelly O'Hair Date: Thu, 3 Sep 2009 17:44:28 -0700 Subject: [PATCH] 6855174: Improve log output when builds transition from one workspace to another Reviewed-by: jjg --- make/Defs-internal.gmk | 17 +++++++++++++++++ make/corba-rules.gmk | 4 ++++ make/deploy-rules.gmk | 8 ++++++-- make/hotspot-rules.gmk | 2 ++ make/install-rules.gmk | 10 ++++++++++ make/jaxp-rules.gmk | 4 ++++ make/jaxws-rules.gmk | 4 ++++ make/jdk-rules.gmk | 8 ++++++++ make/langtools-rules.gmk | 8 ++++++-- make/sponsors-rules.gmk | 4 +++- 10 files changed, 64 insertions(+), 5 deletions(-) diff --git a/make/Defs-internal.gmk b/make/Defs-internal.gmk index 45f80ecaf97..e3c6a2db7b2 100644 --- a/make/Defs-internal.gmk +++ b/make/Defs-internal.gmk @@ -28,6 +28,23 @@ # not contain rules. # +# Indicate that we are visiting a separate repo or component +define MakeStart +$(PRINTF) "\n\n%s\n%s\n##### %-60.60s #####\n%s\n" \ +"########################################################################" \ +"########################################################################" \ +"Entering $1 for target $2" \ +"########################################################################" +endef + +define MakeFinish +$(PRINTF) "%s\n##### %-60.60s #####\n%s\n%s\n\n" \ +"########################################################################" \ +"Leaving $1 for target $2" \ +"########################################################################" \ +"########################################################################" +endef + ifdef OPENJDK ifneq ($(OPENJDK),true) x:=$(error "OPENJDK (if defined) can only be set to true") diff --git a/make/corba-rules.gmk b/make/corba-rules.gmk index bcd89f32ef7..6d8a98e0942 100644 --- a/make/corba-rules.gmk +++ b/make/corba-rules.gmk @@ -40,13 +40,17 @@ endif corba: corba-build corba-build: $(MKDIR) -p $(CORBA_OUTPUTDIR) + @$(call MakeStart, corba, all) ($(CD) $(CORBA_TOPDIR)/make && \ $(MAKE) $(CORBA_BUILD_ARGUMENTS) all) + @$(call MakeFinish, corba, all) corba-clobber:: $(MKDIR) -p $(CORBA_OUTPUTDIR) + @$(call MakeStart, corba, clobber) ($(CD) $(CORBA_TOPDIR)/make && \ $(MAKE) $(CORBA_BUILD_ARGUMENTS) clobber) + @$(call MakeFinish, corba, clobber) .PHONY: corba corba-build corba-clobber diff --git a/make/deploy-rules.gmk b/make/deploy-rules.gmk index afec0ea267a..10e10ff5ed6 100644 --- a/make/deploy-rules.gmk +++ b/make/deploy-rules.gmk @@ -121,14 +121,18 @@ endif deploy-build: ifeq ($(BUILD_DEPLOY), true) + @$(call MakeStart, deploy, $(DEPLOY_BUILD_TARGETS)) ($(CD) $(DEPLOY_TOPDIR)/make && \ - $(MAKE) $(DEPLOY_BUILD_TARGETS) $(DEPLOY_BUILD_ARGUMENTS)) + $(MAKE) $(DEPLOY_BUILD_TARGETS) $(DEPLOY_BUILD_ARGUMENTS)) + @$(call MakeFinish, deploy, $(DEPLOY_BUILD_TARGETS)) endif deploy-clobber:: ifeq ($(BUILD_DEPLOY), true) + @$(call MakeStart, deploy, clobber) ($(CD) $(DEPLOY_TOPDIR)/make && \ - $(MAKE) clobber $(DEPLOY_BUILD_ARGUMENTS)) + $(MAKE) clobber $(DEPLOY_BUILD_ARGUMENTS)) + @$(call MakeFinish, deploy, clobber) endif deploy-sanity:: diff --git a/make/hotspot-rules.gmk b/make/hotspot-rules.gmk index 6bae44cadd8..baa9988a863 100644 --- a/make/hotspot-rules.gmk +++ b/make/hotspot-rules.gmk @@ -88,8 +88,10 @@ endif hotspot-build:: $(MKDIR) -p $(HOTSPOT_OUTPUTDIR) $(MKDIR) -p $(HOTSPOT_EXPORT_PATH) + @$(call MakeStart, hotspot, $(HOTSPOT_TARGET)) $(CD) $(HOTSPOT_TOPDIR)/make && \ $(MAKE) $(HOTSPOT_BUILD_ARGUMENTS) $(HOTSPOT_TARGET) + @$(call MakeFinish, hotspot, $(HOTSPOT_TARGET)) ##################### # .PHONY diff --git a/make/install-rules.gmk b/make/install-rules.gmk index dc85f05b760..05ba70bc187 100644 --- a/make/install-rules.gmk +++ b/make/install-rules.gmk @@ -57,38 +57,48 @@ install: install-build install-build: ifeq ($(BUILD_INSTALL), true) + @$(call MakeStart, install, $(INSTALL_BUILD_TARGETS)) ($(CD) $(INSTALL_TOPDIR)/make && \ $(MAKE) $(INSTALL_BUILD_TARGETS) $(INSTALL_BUILD_ARGUMENTS)) + @$(call MakeFinish, install, $(INSTALL_BUILD_TARGETS)) endif update-patcher: ifeq ($(BUILD_INSTALL), true) if [ -r $(INSTALL_TOPDIR)/make/update/Makefile ]; then \ + $(call MakeStart, install update, all); \ ( $(CD) $(INSTALL_TOPDIR)/make/update && \ $(MAKE) all $(INSTALL_BUILD_ARGUMENTS) ); \ + $(call MakeFinish, install, all); \ fi endif update-patchgen: ifeq ($(BUILD_INSTALL), true) if [ -r $(INSTALL_TOPDIR)/make/update/Makefile ]; then \ + $(call MakeStart, install update, patchgen); \ ( $(CD) $(INSTALL_TOPDIR)/make/update && \ $(MAKE) patchgen $(INSTALL_BUILD_ARGUMENTS) ); \ + $(call MakeFinish, install, patchgen); \ fi endif installer: ifeq ($(BUILD_INSTALL), true) if [ -r $(INSTALL_TOPDIR)/make/installer/Makefile ]; then \ + $(call MakeStart, install installer, all); \ ( $(CD) $(INSTALL_TOPDIR)/make/installer && \ $(MAKE) all $(INSTALL_BUILD_ARGUMENTS) ); \ + $(call MakeFinish, install, all); \ fi endif install-clobber: ifeq ($(BUILD_INSTALL), true) + @$(call MakeStart, install, clobber) ($(CD) $(INSTALL_TOPDIR)/make && \ $(MAKE) clobber $(INSTALL_BUILD_ARGUMENTS)) + @$(call MakeFinish, install, clobber) endif install-sanity:: diff --git a/make/jaxp-rules.gmk b/make/jaxp-rules.gmk index 5d12acc91df..a4f0cc8b412 100644 --- a/make/jaxp-rules.gmk +++ b/make/jaxp-rules.gmk @@ -40,13 +40,17 @@ endif jaxp: jaxp-build jaxp-build: $(MKDIR) -p $(JAXP_OUTPUTDIR) + @$(call MakeStart, jaxp, all) ($(CD) $(JAXP_TOPDIR)/make && \ $(MAKE) $(JAXP_BUILD_ARGUMENTS) all) + @$(call MakeFinish, jaxp, all) jaxp-clobber:: $(MKDIR) -p $(JAXP_OUTPUTDIR) + @$(call MakeStart, jaxp, clobber) ($(CD) $(JAXP_TOPDIR)/make && \ $(MAKE) $(JAXP_BUILD_ARGUMENTS) clobber) + @$(call MakeFinish, jaxp, clobber) .PHONY: jaxp jaxp-build jaxp-clobber diff --git a/make/jaxws-rules.gmk b/make/jaxws-rules.gmk index 361857af8aa..f82d3f96a70 100644 --- a/make/jaxws-rules.gmk +++ b/make/jaxws-rules.gmk @@ -40,13 +40,17 @@ endif jaxws: jaxws-build jaxws-build: $(MKDIR) -p $(JAXWS_OUTPUTDIR) + @$(call MakeStart, jaxws, all) ($(CD) $(JAXWS_TOPDIR)/make && \ $(MAKE) $(JAXWS_BUILD_ARGUMENTS) all) + @$(call MakeFinish, jaxws, all) jaxws-clobber:: $(MKDIR) -p $(JAXWS_OUTPUTDIR) + @$(call MakeStart, jaxws, clobber) ($(CD) $(JAXWS_TOPDIR)/make && \ $(MAKE) $(JAXWS_BUILD_ARGUMENTS) clobber) + @$(call MakeFinish, jaxws, clobber) .PHONY: jaxws jaxws-build jaxws-clobber diff --git a/make/jdk-rules.gmk b/make/jdk-rules.gmk index a84c776a823..b9416bd0070 100644 --- a/make/jdk-rules.gmk +++ b/make/jdk-rules.gmk @@ -98,12 +98,16 @@ $(JDK_JAVA_EXE):: jdk-build jdk: jdk-build jdk-build: + @$(call MakeStart, jdk, $(JDK_BUILD_TARGETS)) ( $(CD) $(JDK_TOPDIR)/make && \ $(MAKE) $(JDK_BUILD_TARGETS) $(JDK_BUILD_ARGUMENTS) ; ) + @$(call MakeFinish, jdk, $(JDK_BUILD_TARGETS)) jdk-clobber:: + @$(call MakeStart, jdk, $(JDK_CLOBBER_TARGETS)) ( $(CD) $(JDK_TOPDIR)/make && \ $(MAKE) $(JDK_CLOBBER_TARGETS) $(JDK_BUILD_ARGUMENTS) ; ) + @$(call MakeFinish, jdk, $(JDK_CLOBBER_TARGETS)) jdk-sanity:: ( $(CD) $(JDK_TOPDIR)/make && \ @@ -111,13 +115,17 @@ jdk-sanity:: compare-images: compare-image compare-image: + @$(call MakeStart, jdk, compare-image) ( $(CD) $(JDK_TOPDIR)/make && \ $(MAKE) ALT_OUTPUTDIR=$(ABS_OUTPUTDIR) compare-image ) + @$(call MakeFinish, jdk, compare-image) compare-images-clobber: compare-image-clobber compare-image-clobber: + @$(call MakeStart, jdk, compare-image-clobber) ( $(CD) $(JDK_TOPDIR)/make && \ $(MAKE) ALT_OUTPUTDIR=$(ABS_OUTPUTDIR) compare-image-clobber ) + @$(call MakeFinish, jdk, compare-image-clobber) .PHONY: jdk jdk-build jdk-clobber jdk-sanity diff --git a/make/langtools-rules.gmk b/make/langtools-rules.gmk index 06bffa1f75d..aef4069d0b7 100644 --- a/make/langtools-rules.gmk +++ b/make/langtools-rules.gmk @@ -35,13 +35,17 @@ LANGTOOLS_BUILD_ARGUMENTS = \ langtools: langtools-build langtools-build: $(MKDIR) -p $(LANGTOOLS_OUTPUTDIR) + @$(call MakeStart, langtools, all) ($(CD) $(LANGTOOLS_TOPDIR)/make && \ - $(MAKE) $(LANGTOOLS_BUILD_ARGUMENTS) all) + $(MAKE) $(LANGTOOLS_BUILD_ARGUMENTS) all) + @$(call MakeFinish, langtools, all) langtools-clobber:: $(MKDIR) -p $(LANGTOOLS_OUTPUTDIR) + @$(call MakeStart, langtools, clobber) ($(CD) $(LANGTOOLS_TOPDIR)/make && \ - $(MAKE) $(LANGTOOLS_BUILD_ARGUMENTS) clobber) + $(MAKE) $(LANGTOOLS_BUILD_ARGUMENTS) clobber) + @$(call MakeFinish, langtools, clobber) .PHONY: langtools langtools-build langtools-clobber diff --git a/make/sponsors-rules.gmk b/make/sponsors-rules.gmk index 15ba2bc3d35..412b86f8660 100644 --- a/make/sponsors-rules.gmk +++ b/make/sponsors-rules.gmk @@ -59,8 +59,10 @@ endif sponsors-build: ifeq ($(ARCH_DATA_MODEL), 32) ifeq ($(BUILD_SPONSORS), true) + @$(call MakeStart, sponsors, $(SPONSORS_BUILD_TARGETS)) ($(CD) $(SPONSORS_TOPDIR)/make && \ - $(MAKE) $(SPONSORS_BUILD_TARGETS) $(SPONSORS_BUILD_ARGUMENTS)) + $(MAKE) $(SPONSORS_BUILD_TARGETS) $(SPONSORS_BUILD_ARGUMENTS)) + @$(call MakeFinish, sponsors, $(SPONSORS_BUILD_TARGETS)) endif endif