From af629d027cd8f7c2b659837757352d1e54b5ed8d Mon Sep 17 00:00:00 2001 From: Stuart Marks Date: Wed, 30 Nov 2011 13:11:16 -0800 Subject: [PATCH] 7116322: enhance javac make rule with a little bit of instrumentation Reviewed-by: dholmes, ohair --- jdk/make/common/Rules.gmk | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) diff --git a/jdk/make/common/Rules.gmk b/jdk/make/common/Rules.gmk index 5072b33c2c9..041e1d20226 100644 --- a/jdk/make/common/Rules.gmk +++ b/jdk/make/common/Rules.gmk @@ -233,13 +233,15 @@ classes : $(CLASSES_INIT) .delete.classlist .compile.classlist @$(MKDIR) -p $(CLASSDESTDIR) @$(RM) $<.filtered @$(CAT) $< | $(NAWK) 'length>0' | $(SORT) -u > $<.filtered - @if [ `$(CAT) $<.filtered | $(WC) -l` -ge 1 ] ; then \ - $(ECHO) "# Java sources to be compiled: (listed in file $<)"; \ - $(CAT) $<.filtered; \ - $(ECHO) "# Running javac:"; \ - $(ECHO) $(JAVAC_CMD) -sourcepath "$(SOURCEPATH)" -d $(CLASSDESTDIR) @$<.filtered; \ - $(JAVAC_CMD) -sourcepath "$(SOURCEPATH)" -d $(CLASSDESTDIR) @$<.filtered; \ - fi + @numfiles=`$(WC) -l < $<.filtered` ; \ + if [ $$numfiles -ge 1 ] ; then \ + $(ECHO) "# Java sources to be compiled: (listed in file $<)"; \ + $(CAT) $<.filtered; \ + $(ECHO) "# Running javac: $$numfiles files; in $(CURDIR)"; \ + $(ECHO) $(JAVAC_CMD) -sourcepath "$(SOURCEPATH)" -d $(CLASSDESTDIR) @$<.filtered; \ + $(JAVAC_CMD) -sourcepath "$(SOURCEPATH)" -d $(CLASSDESTDIR) @$<.filtered; \ + $(ECHO) "# javac finished"; \ + fi @$(java-vm-cleanup) clobber clean::