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