hotspot/make/HotspotCommon.gmk
author prr
Wed, 09 Nov 2016 11:28:13 -0800
changeset 42208 7c1017f0ade5
parent 41277 65200988b2ee
permissions -rw-r--r--
8155874: Fix java.desktop deprecation warnings about Class.newInstance Reviewed-by: serb, alexsch
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
37437
f824aabc7af8 8152666: The new Hotspot Build System
erikj
parents:
diff changeset
     1
#
f824aabc7af8 8152666: The new Hotspot Build System
erikj
parents:
diff changeset
     2
# Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved.
f824aabc7af8 8152666: The new Hotspot Build System
erikj
parents:
diff changeset
     3
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
f824aabc7af8 8152666: The new Hotspot Build System
erikj
parents:
diff changeset
     4
#
f824aabc7af8 8152666: The new Hotspot Build System
erikj
parents:
diff changeset
     5
# This code is free software; you can redistribute it and/or modify it
f824aabc7af8 8152666: The new Hotspot Build System
erikj
parents:
diff changeset
     6
# under the terms of the GNU General Public License version 2 only, as
f824aabc7af8 8152666: The new Hotspot Build System
erikj
parents:
diff changeset
     7
# published by the Free Software Foundation.  Oracle designates this
f824aabc7af8 8152666: The new Hotspot Build System
erikj
parents:
diff changeset
     8
# particular file as subject to the "Classpath" exception as provided
f824aabc7af8 8152666: The new Hotspot Build System
erikj
parents:
diff changeset
     9
# by Oracle in the LICENSE file that accompanied this code.
f824aabc7af8 8152666: The new Hotspot Build System
erikj
parents:
diff changeset
    10
#
f824aabc7af8 8152666: The new Hotspot Build System
erikj
parents:
diff changeset
    11
# This code is distributed in the hope that it will be useful, but WITHOUT
f824aabc7af8 8152666: The new Hotspot Build System
erikj
parents:
diff changeset
    12
# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
f824aabc7af8 8152666: The new Hotspot Build System
erikj
parents:
diff changeset
    13
# FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
f824aabc7af8 8152666: The new Hotspot Build System
erikj
parents:
diff changeset
    14
# version 2 for more details (a copy is included in the LICENSE file that
f824aabc7af8 8152666: The new Hotspot Build System
erikj
parents:
diff changeset
    15
# accompanied this code).
f824aabc7af8 8152666: The new Hotspot Build System
erikj
parents:
diff changeset
    16
#
f824aabc7af8 8152666: The new Hotspot Build System
erikj
parents:
diff changeset
    17
# You should have received a copy of the GNU General Public License version
f824aabc7af8 8152666: The new Hotspot Build System
erikj
parents:
diff changeset
    18
# 2 along with this work; if not, write to the Free Software Foundation,
f824aabc7af8 8152666: The new Hotspot Build System
erikj
parents:
diff changeset
    19
# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
f824aabc7af8 8152666: The new Hotspot Build System
erikj
parents:
diff changeset
    20
#
f824aabc7af8 8152666: The new Hotspot Build System
erikj
parents:
diff changeset
    21
# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
f824aabc7af8 8152666: The new Hotspot Build System
erikj
parents:
diff changeset
    22
# or visit www.oracle.com if you need additional information or have any
f824aabc7af8 8152666: The new Hotspot Build System
erikj
parents:
diff changeset
    23
# questions.
f824aabc7af8 8152666: The new Hotspot Build System
erikj
parents:
diff changeset
    24
#
f824aabc7af8 8152666: The new Hotspot Build System
erikj
parents:
diff changeset
    25
f824aabc7af8 8152666: The new Hotspot Build System
erikj
parents:
diff changeset
    26
ifeq ($(JVM_VARIANT), )
f824aabc7af8 8152666: The new Hotspot Build System
erikj
parents:
diff changeset
    27
  $(error This makefile must be called with JVM_VARIANT set)
f824aabc7af8 8152666: The new Hotspot Build System
erikj
parents:
diff changeset
    28
endif
f824aabc7af8 8152666: The new Hotspot Build System
erikj
parents:
diff changeset
    29
f824aabc7af8 8152666: The new Hotspot Build System
erikj
parents:
diff changeset
    30
JVM_VARIANT_OUTPUTDIR := $(HOTSPOT_OUTPUTDIR)/variant-$(JVM_VARIANT)
f824aabc7af8 8152666: The new Hotspot Build System
erikj
parents:
diff changeset
    31
JVM_OUTPUTDIR := $(JVM_VARIANT_OUTPUTDIR)/libjvm
f824aabc7af8 8152666: The new Hotspot Build System
erikj
parents:
diff changeset
    32
JVM_SUPPORT_DIR := $(JVM_VARIANT_OUTPUTDIR)/support
f824aabc7af8 8152666: The new Hotspot Build System
erikj
parents:
diff changeset
    33
f824aabc7af8 8152666: The new Hotspot Build System
erikj
parents:
diff changeset
    34
DTRACE_SUPPORT_DIR := $(JVM_SUPPORT_DIR)/dtrace
f824aabc7af8 8152666: The new Hotspot Build System
erikj
parents:
diff changeset
    35
41277
65200988b2ee 8150736: Excessive disk space used by build system
erikj
parents: 38097
diff changeset
    36
LIB_OUTPUTDIR := $(call FindLibDirForModule, java.base)
65200988b2ee 8150736: Excessive disk space used by build system
erikj
parents: 38097
diff changeset
    37
ifneq ($(filter client minimal, $(JVM_VARIANT)), )
65200988b2ee 8150736: Excessive disk space used by build system
erikj
parents: 38097
diff changeset
    38
  JVM_VARIANT_SUBDIR := $(JVM_VARIANT)
65200988b2ee 8150736: Excessive disk space used by build system
erikj
parents: 38097
diff changeset
    39
else
65200988b2ee 8150736: Excessive disk space used by build system
erikj
parents: 38097
diff changeset
    40
  # Use 'server' as default target directory name for all other variants.
65200988b2ee 8150736: Excessive disk space used by build system
erikj
parents: 38097
diff changeset
    41
  JVM_VARIANT_SUBDIR := server
65200988b2ee 8150736: Excessive disk space used by build system
erikj
parents: 38097
diff changeset
    42
endif
65200988b2ee 8150736: Excessive disk space used by build system
erikj
parents: 38097
diff changeset
    43
JVM_LIB_OUTPUTDIR := $(LIB_OUTPUTDIR)/$(JVM_VARIANT_SUBDIR)
65200988b2ee 8150736: Excessive disk space used by build system
erikj
parents: 38097
diff changeset
    44
37437
f824aabc7af8 8152666: The new Hotspot Build System
erikj
parents:
diff changeset
    45
################################################################################
f824aabc7af8 8152666: The new Hotspot Build System
erikj
parents:
diff changeset
    46
f824aabc7af8 8152666: The new Hotspot Build System
erikj
parents:
diff changeset
    47
# Test if a feature is available in the present build of JVM_VARIANT. Will return
f824aabc7af8 8152666: The new Hotspot Build System
erikj
parents:
diff changeset
    48
# 'true' or 'false'.
f824aabc7af8 8152666: The new Hotspot Build System
erikj
parents:
diff changeset
    49
# $1 - the feature to test for
f824aabc7af8 8152666: The new Hotspot Build System
erikj
parents:
diff changeset
    50
check-jvm-feature = \
f824aabc7af8 8152666: The new Hotspot Build System
erikj
parents:
diff changeset
    51
  $(strip \
f824aabc7af8 8152666: The new Hotspot Build System
erikj
parents:
diff changeset
    52
    $(if $(filter-out $(VALID_JVM_FEATURES), $1), \
f824aabc7af8 8152666: The new Hotspot Build System
erikj
parents:
diff changeset
    53
      $(error Internal error: Invalid feature tested: $1)) \
f824aabc7af8 8152666: The new Hotspot Build System
erikj
parents:
diff changeset
    54
    $(if $(filter $1, $(JVM_FEATURES_$(JVM_VARIANT))), true, false))