make/FakeSpecForLegacyTests.gmk
author ihse
Thu, 30 Nov 2017 00:31:24 +0100
branchihse-testmakefiles-branch
changeset 55921 60356323be38
parent 55881 dbf68259f80e
permissions -rw-r--r--
Try to not exit with error.
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
55881
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
     1
#
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
     2
# Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved.
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
     3
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
     4
#
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
     5
# This code is free software; you can redistribute it and/or modify it
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
     6
# under the terms of the GNU General Public License version 2 only, as
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
     7
# published by the Free Software Foundation.  Oracle designates this
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
     8
# particular file as subject to the "Classpath" exception as provided
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
     9
# by Oracle in the LICENSE file that accompanied this code.
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
    10
#
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
    11
# This code is distributed in the hope that it will be useful, but WITHOUT
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
    12
# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
    13
# FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
    14
# version 2 for more details (a copy is included in the LICENSE file that
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
    15
# accompanied this code).
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
    16
#
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
    17
# You should have received a copy of the GNU General Public License version
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
    18
# 2 along with this work; if not, write to the Free Software Foundation,
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
    19
# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
    20
#
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
    21
# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
    22
# or visit www.oracle.com if you need additional information or have any
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
    23
# questions.
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
    24
#
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
    25
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
    26
# Fake minimalistic spec file for RunTestsLegacy.gmk.
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
    27
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
    28
# FIXME: HACK.
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
    29
TEST_ROOT := $(TOPDIR)/jdk/test
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
    30
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
    31
ifdef ALT_OUTPUTDIR
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
    32
  LEGACY_OUTPUTDIR := $(ALT_OUTPUTDIR)
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
    33
else
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
    34
  LEGACY_OUTPUTDIR := $(TEST_ROOT)/..
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
    35
endif
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
    36
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
    37
# We need a proper PRODUCT_HOME
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
    38
ifeq ($(PRODUCT_HOME), )
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
    39
  PRODUCT_HOME := $(LEGACY_OUTPUTDIR)/images/jdk
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
    40
  ifeq ($(wildcard $(PRODUCT_HOME)/bin/java), )
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
    41
    PRODUCT_HOME := $(LEGACY_OUTPUTDIR)
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
    42
    ifeq ($(wildcard $(PRODUCT_HOME)/bin/java), )
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
    43
      ifeq ($(wildcard $(PRODUCT_HOME)/bin/java), )
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
    44
        $(info Error: PRODUCT_HOME must be specified)
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
    45
        $(error Cannot continue)
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
    46
      endif
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
    47
    endif
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
    48
  endif
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
    49
  $(info Warning: No PRODUCT_HOME given, will use $(PRODUCT_HOME))
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
    50
else
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
    51
  ifeq ($(wildcard $(PRODUCT_HOME)/bin/java), )
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
    52
    $(info Error: Cannot find bin/java at PRODUCT_HOME=$(PRODUCT_HOME))
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
    53
    $(error Cannot continue)
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
    54
  endif
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
    55
endif
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
    56
$(info Using PRODUCT_HOME=$(PRODUCT_HOME))
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
    57
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
    58
# We need a proper JT_HOME
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
    59
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
    60
JDK_IMAGE_DIR := $(PRODUCT_HOME)
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
    61
# PRODUCT_HOME
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
    62
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
    63
# ???
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
    64
BOOT_JDK := /var/tmp/jib-ihse/install/java/re/jdk/8/promoted/latest/bundles/linux-x64/jdk-8-linux-x64.tar.gz/jdk1.8.0
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
    65
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
    66
# MUST BE SET
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
    67
JT_HOME := /var/tmp/jib-ihse/install/java/re/jtreg/4.2/promoted/all/b04/bundles/jtreg_bin-4.2.zip/jtreg
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
    68
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
    69
$(info using JT_HOME $(JT_HOME))
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
    70
$(info using BOOT_JDK $(BOOT_JDK))
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
    71
$(info using PRODUCT_HOME $(PRODUCT_HOME))
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
    72
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
    73
CONF_NAME := linux-x64
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
    74
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
    75
OUTPUT_ROOT := $(TOPDIR)/build/$(CONF_NAME)
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
    76
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
    77
OPENJDK_TARGET_OS := linux
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
    78
OPENJDK_TARGET_OS_TYPE := unix
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
    79
OPENJDK_TARGET_OS_ENV := linux
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
    80
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
    81
OPENJDK_TARGET_CPU := x86_64
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
    82
OPENJDK_TARGET_CPU_ARCH := x86
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
    83
OPENJDK_TARGET_CPU_BITS := 64
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
    84
OPENJDK_TARGET_CPU_ENDIAN := little
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
    85
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
    86
NUM_CORES := 4
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
    87
JOBS ?= 3
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
    88
TEST_JOBS ?= 0
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
    89
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
    90
USE_JTREG_EXECUTABLE := true
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
    91
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
    92
# These needs som special handling on Windows to get right
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
    93
PATH_SEP := :
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
    94
FIXPATH :=
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
    95
CYGPATH :=
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
    96
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
    97
# Make sure we're using bash as shell with -e and pipefail.
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
    98
BASH := bash
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
    99
BASH_ARGS := -o pipefail -e
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
   100
SHELL := $(BASH) $(BASH_ARGS)
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
   101
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
   102
# Set up default names for common tools
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
   103
AWK := awk
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
   104
BASENAME := basename
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
   105
CAT := cat
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
   106
CHMOD := chmod
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
   107
CP := cp
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
   108
CUT := cut
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
   109
DATE := date
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
   110
DIFF := diff
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
   111
DIRNAME := dirname
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
   112
ECHO := echo
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
   113
EXPR := expr
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
   114
FILE := file
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
   115
FIND := find
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
   116
GREP := grep
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
   117
EGREP := grep -E
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
   118
FGREP := grep -F
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
   119
HEAD := head
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
   120
LN := ln
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
   121
LS := ls
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
   122
MKDIR := mkdir
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
   123
MV := mv
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
   124
NAWK := nawk
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
   125
PRINTF := printf
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
   126
PWD := pwd
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
   127
RMDIR := rmdir
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
   128
RM := rm -f
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
   129
SED := sed
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
   130
SH := sh
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
   131
SORT := sort
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
   132
TAIL := tail
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
   133
TEE := tee
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
   134
TOUCH := touch
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
   135
TR := tr
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
   136
UNIQ := uniq
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
   137
WC := wc
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
   138
XARGS := xargs
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
   139
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
   140
# Create composite variables from what have been defined above
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
   141
SRC_ROOT := $(TOPDIR)
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
   142
BUILD_OUTPUT := $(OUTPUT_ROOT)
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
   143
IMAGES_OUTPUTDIR := $(OUTPUT_ROOT)/images
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
   144
TEST_IMAGE_SUBDIR := test
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
   145
TEST_IMAGE_DIR := $(IMAGES_OUTPUTDIR)/$(TEST_IMAGE_SUBDIR)
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
   146
SYMBOLS_IMAGE_SUBDIR := symbols
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
   147
SYMBOLS_IMAGE_DIR := $(IMAGES_OUTPUTDIR)/$(SYMBOLS_IMAGE_SUBDIR)
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
   148
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
   149
# Assume target platform is same as build platform
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
   150
OPENJDK_TARGET_OS := $(OPENJDK_BUILD_OS)
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
   151
OPENJDK_TARGET_OS_TYPE := $(OPENJDK_BUILD_OS_TYPE)
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
   152
OPENJDK_TARGET_OS_ENV := $(OPENJDK_BUILD_OS_ENV)
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
   153
OPENJDK_TARGET_CPU := $(OPENJDK_BUILD_CPU)
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
   154
OPENJDK_TARGET_CPU_ARCH := $(OPENJDK_BUILD_CPU_ARCH)
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
   155
OPENJDK_TARGET_CPU_BITS := $(OPENJDK_BUILD_CPU_BITS)
dbf68259f80e Populate with latest code from jdk9 sandbox.
ihse
parents:
diff changeset
   156
OPENJDK_TARGET_CPU_ENDIAN := $(OPENJDK_BUILD_CPU_ENDIAN)