6877763: update langtools/test/Makefile for JPRT

Tue, 01 Sep 2009 11:35:00 -0700

author
jjg
date
Tue, 01 Sep 2009 11:35:00 -0700
changeset 397
40a1327a5283
parent 396
dda7e13f09fb
child 398
8d999cb7ec09

6877763: update langtools/test/Makefile for JPRT
Reviewed-by: ohair

test/Makefile file | annotate | diff | comparison | revisions
     1.1 --- a/test/Makefile	Tue Sep 01 14:53:39 2009 +0100
     1.2 +++ b/test/Makefile	Tue Sep 01 11:35:00 2009 -0700
     1.3 @@ -44,7 +44,6 @@
     1.4  # Default bundle of all test results (passed or not)
     1.5  JPRT_ARCHIVE_BUNDLE=$(TEST_ROOT)/JPRT_ARCHIVE_BUNDLE.zip
     1.6  
     1.7 -# Default home for JTREG
     1.8  ifeq ($(PLATFORM), windows)
     1.9    SLASH_JAVA = J:
    1.10  else
    1.11 @@ -52,8 +51,12 @@
    1.12  endif
    1.13  
    1.14  # Default JTREG to run
    1.15 -JT_HOME = $(SLASH_JAVA)/svc/jct-tools3.2.2_02
    1.16 -JTREG = $(JT_HOME)/$(JT_PLATFORM)/bin/jtreg
    1.17 +ifdef JPRT_JTREG_HOME
    1.18 +  JTREG_HOME = $(JPRT_JTREG_HOME)
    1.19 +else
    1.20 +  JTREG_HOME = $(SLASH_JAVA)/re/jtreg/4.0/promoted/latest/binaries/jtreg
    1.21 +endif
    1.22 +JTREG = $(JTREG_HOME)/$(JT_PLATFORM)/bin/jtreg
    1.23  
    1.24  # Default JDK for JTREG
    1.25  ifdef JPRT_JAVA_HOME
    1.26 @@ -63,7 +66,12 @@
    1.27  endif
    1.28  
    1.29  # Default JDK to test
    1.30 -TESTJAVA = $(SLASH_JAVA)/re/jdk/1.7.0/promoted/latest/binaries/$(PLATFORM)-$(ARCH)
    1.31 +ifdef JPRT_IMPORT_PRODUCT_HOME
    1.32 +  TESTJAVA = $(JPRT_IMPORT_PRODUCT_HOME)
    1.33 +else
    1.34 +  TESTJAVA = $(SLASH_JAVA)/re/jdk/1.7.0/promoted/latest/binaries/$(PLATFORM)-$(ARCH)
    1.35 +endif
    1.36 +
    1.37  TESTBOOTCLASSPATH = $(PRODUCT_HOME)/dist/lib/classes.jar
    1.38  
    1.39  # The test directories to run
    1.40 @@ -73,41 +81,40 @@
    1.41  # Root of all test results
    1.42  TEST_OUTPUT_DIR = $(TEST_ROOT)/o_$(PLATFORM)-$(ARCH)
    1.43  
    1.44 -# Export this setting and pass it in.
    1.45 -JAVA_TOOL_OPTIONS = -Djava.awt.headless=true
    1.46 -export JAVA_TOOL_OPTIONS
    1.47 -
    1.48  # Default make rule
    1.49 -all javac javadoc javah javap apt: clean check jtreg-tests $(JPRT_ARCHIVE_BUNDLE)
    1.50 +all apt javac javadoc javah javap: clean check jtreg-tests $(JPRT_ARCHIVE_BUNDLE)
    1.51  	@echo "Testing completed successfully"
    1.52  
    1.53  # for use with JPRT -testrule
    1.54  all:		TESTDIRS = .
    1.55 -javac fastjavac: TESTDIRS = tools/javac
    1.56 +apt:		TESTDIRS = tools/apt
    1.57 +javac: 		TESTDIRS = tools/javac
    1.58  javadoc:	TESTDIRS = tools/javadoc com/sun/javadoc
    1.59  javah:		TESTDIRS = tools/javah
    1.60  javap:		TESTDIRS = tools/javap
    1.61 -apt:		TESTDIRS = tools/apt
    1.62 -
    1.63 -fastjavac:	SAMEVM = -samevm
    1.64  
    1.65  # Check to make sure these directories exist
    1.66  check: $(JT_HOME) $(PRODUCT_HOME) $(JTREG)
    1.67  
    1.68  # Run the tests
    1.69  jtreg-tests: FRC
    1.70 -	ls /opt/jprt /opt/jprt/jdk*
    1.71  	@echo "Using export JAVA_TOOL_OPTIONS=$(JAVA_TOOL_OPTIONS)"
    1.72  	@rm -f -r $(TEST_OUTPUT_DIR)/JTwork $(TEST_OUTPUT_DIR)/JTreport
    1.73  	@mkdir -p $(TEST_OUTPUT_DIR)
    1.74 -	JT_JAVA=$(JT_JAVA) $(JTREG) -k:\!ignore -a -v:fail,error $(SAMEVM) \
    1.75 +	JT_JAVA=$(JT_JAVA) $(JTREG) \
    1.76 +	  -a -samevm -k:\!ignore -v:fail,error,nopass \
    1.77            -r:$(TEST_OUTPUT_DIR)/JTreport \
    1.78            -w:$(TEST_OUTPUT_DIR)/JTwork \
    1.79            -jdk:$(TESTJAVA) \
    1.80  	  -Xbootclasspath/p:$(TESTBOOTCLASSPATH) \
    1.81 -          $(JAVA_TOOL_OPTIONS:%=-vmoption:%) \
    1.82            $(JAVA_ARGS:%=-vmoption:%) \
    1.83 -          $(TESTDIRS)
    1.84 +          $(TESTDIRS) \
    1.85 +	|| ( status=$$? ; \
    1.86 +		echo ; echo "Summary of test failures" ; \
    1.87 +		cat $(TEST_OUTPUT_DIR)/JTreport/text/summary.txt | \
    1.88 +			grep -v 'Not run' | grep -v 'Passed' ; \
    1.89 +		echo ; \
    1.90 +		exit $$status )
    1.91  
    1.92  # Bundle up the results
    1.93  $(JPRT_ARCHIVE_BUNDLE): FRC

mercurial