test/Makefile

Print this page
rev 902 : 8020779: Improve detection and handling of jtreg/jtdiff executable path
8026988: Makefile is confused if JT_HOME is a different location than jtreg executable
Reviewed-by: duke

*** 37,47 **** # Macro to run a test target in a subdir define SUBDIR_TEST # subdirectory target if [ -d $1 ] ; then \ if [ -r $1/test/Makefile ] ; then \ echo "$(MAKE) -k -C $1/test $2" ; \ ! $(MAKE) -k -C $1/test $2 ; \ else \ echo "ERROR: File does not exist: $1/test/Makefile"; \ exit 1; \ fi; \ else \ --- 37,47 ---- # Macro to run a test target in a subdir define SUBDIR_TEST # subdirectory target if [ -d $1 ] ; then \ if [ -r $1/test/Makefile ] ; then \ echo "$(MAKE) -k -C $1/test $2" ; \ ! $(MAKE) -k -C $1/test $2 JTREG=$(JTREG) JTDIFF=$(JTDIFF) PRODUCT_HOME=$(PRODUCT_HOME); \ else \ echo "ERROR: File does not exist: $1/test/Makefile"; \ exit 1; \ fi; \ else \
*** 55,70 **** # All testing all: jdk_all langtools_all # Test targets langtools_% : ! @$(NO_STOPPING)$(call SUBDIR_TEST, $(LANGTOOLS_DIR), JT_JAVA=$(PRODUCT_HOME) JTREG_HOME=$(JT_HOME) TEST="$(subst langtools_,,$@)" $(subst langtools_,,$@)) jdk_% : @$(NO_STOPPING)$(call SUBDIR_TEST, $(JDK_DIR), TEST="$@" $@) ################################################################ # Phony targets (e.g. these are not filenames) ! .PHONY: all clean ################################################################ --- 55,70 ---- # All testing all: jdk_all langtools_all # Test targets langtools_% : ! @$(NO_STOPPING)$(call SUBDIR_TEST, $(LANGTOOLS_DIR), TEST="$(subst langtools_,,$@)" $(subst langtools_,,$@)) jdk_% : @$(NO_STOPPING)$(call SUBDIR_TEST, $(JDK_DIR), TEST="$@" $@) ################################################################ # Phony targets (e.g. these are not filenames) ! .PHONY: all default clean ################################################################