Makefile revision 542
4632N/A#
4632N/A# Copyright (c) 2010, 2012, Oracle and/or its affiliates. All rights reserved.
4632N/A# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
4632N/A#
4632N/A# This code is free software; you can redistribute it and/or modify it
4632N/A# under the terms of the GNU General Public License version 2 only, as
4632N/A# published by the Free Software Foundation. Oracle designates this
4632N/A# particular file as subject to the "Classpath" exception as provided
4632N/A# by Oracle in the LICENSE file that accompanied this code.
4632N/A#
4632N/A# This code is distributed in the hope that it will be useful, but WITHOUT
4632N/A# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
4632N/A# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
4632N/A# version 2 for more details (a copy is included in the LICENSE file that
4632N/A# accompanied this code).
4632N/A#
4632N/A# You should have received a copy of the GNU General Public License version
4632N/A# 2 along with this work; if not, write to the Free Software Foundation,
4632N/A# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
4632N/A#
4632N/A# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
4632N/A# or visit www.oracle.com if you need additional information or have any
4632N/A# questions.
4632N/A#
4632N/A
4632N/A#
4632N/A# Makefile to run tests from multiple sibling directories
4632N/A#
4632N/A
4632N/A# Root of the forest that was built
4632N/ATOPDIR=..
4632N/A
4632N/A# This makefile depends on the availability of sibling directories.
4632N/ALANGTOOLS_DIR=$(TOPDIR)/langtools
4632N/AJDK_DIR=$(TOPDIR)/jdk
4632N/A
4632N/A# Macro to run a test target in a subdir
4632N/Adefine SUBDIR_TEST # subdirectory target
4632N/Aif [ -d $1 ] ; then \
4632N/A if [ -r $1/test/Makefile ] ; then \
4632N/A echo "$(MAKE) -C $1/test $2" ; \
4632N/A $(MAKE) -C $1/test $2 ; \
4632N/A else \
4632N/A echo "ERROR: File does not exist: $1/test/Makefile"; \
4632N/A exit 1; \
4632N/A fi; \
4632N/Aelse \
echo "WARNING: No testing done, directory does not exist: $1"; \
fi
endef
# Test target list for langtools repository
LANGTOOLS_TEST_LIST = langtools_jtreg
# Test target list for jdk repository
JDK_TEST_LIST = \
jdk_beans1 jdk_beans2 jdk_beans3 \
jdk_io \
jdk_lang \
jdk_management \
jdk_jmx \
jdk_math \
jdk_other \
jdk_net \
jdk_nio \
jdk_security1 jdk_security2 jdk_security3 \
jdk_sound \
jdk_text \
jdk_tools \
jdk_jdi \
jdk_jfr \
jdk_util
# These tests need a DISPLAY and can create window interaction complications
JDK_TEST_LIST2 = \
jdk_awt \
jdk_rmi \
jdk_swing
# These are the current jck test targets in the jdk repository
JDK_JCK7_LIST = jck7devtools jck7compiler jck7runtime
# Default test target (everything)
all: $(JDK_TEST_LIST) $(LANGTOOLS_TEST_LIST)
# Test targets
$(LANGTOOLS_TEST_LIST):
@$(NO_STOPPING)$(call SUBDIR_TEST, $(LANGTOOLS_DIR), $(subst langtools_,,$@))
$(JDK_TEST_LIST) $(JDK_TEST_LIST2) $(JDK_JCK7_LIST):
@$(NO_STOPPING)$(call SUBDIR_TEST, $(JDK_DIR), $@)
clean:
################################################################
# Phony targets (e.g. these are not filenames)
.PHONY: all clean \
$(JDK_TEST_LIST) $(JDK_TEST_LIST2) $(JDK_JCK7_LIST) \
$(LANGTOOLS_TEST_LIST)
################################################################