make/linux/makefiles/defs.make

Fri, 25 Mar 2011 09:35:39 +0100

author
roland
date
Fri, 25 Mar 2011 09:35:39 +0100
changeset 2683
7e88bdae86ec
parent 2384
0a8e0d4345b3
child 3044
4aa5974a06dd
permissions
-rw-r--r--

7029017: Additional architecture support for c2 compiler
Summary: Enables cross building of a c2 VM. Support masking of shift counts when the processor architecture mandates it.
Reviewed-by: kvn, never

duke@435 1 #
trims@2384 2 # Copyright (c) 2006, 2010, Oracle and/or its affiliates. All rights reserved.
duke@435 3 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
duke@435 4 #
duke@435 5 # This code is free software; you can redistribute it and/or modify it
duke@435 6 # under the terms of the GNU General Public License version 2 only, as
duke@435 7 # published by the Free Software Foundation.
duke@435 8 #
duke@435 9 # This code is distributed in the hope that it will be useful, but WITHOUT
duke@435 10 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
duke@435 11 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
duke@435 12 # version 2 for more details (a copy is included in the LICENSE file that
duke@435 13 # accompanied this code).
duke@435 14 #
duke@435 15 # You should have received a copy of the GNU General Public License version
duke@435 16 # 2 along with this work; if not, write to the Free Software Foundation,
duke@435 17 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
duke@435 18 #
trims@1907 19 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
trims@1907 20 # or visit www.oracle.com if you need additional information or have any
trims@1907 21 # questions.
duke@435 22 #
duke@435 23 #
duke@435 24
duke@435 25 # The common definitions for hotspot linux builds.
duke@435 26 # Include the top level defs.make under make directory instead of this one.
duke@435 27 # This file is included into make/defs.make.
duke@435 28
duke@435 29 SLASH_JAVA ?= /java
duke@435 30
duke@435 31 # Need PLATFORM (os-arch combo names) for jdk and hotspot, plus libarch name
duke@435 32 ARCH:=$(shell uname -m)
duke@435 33 PATH_SEP = :
duke@435 34 ifeq ($(LP64), 1)
duke@435 35 ARCH_DATA_MODEL ?= 64
duke@435 36 else
duke@435 37 ARCH_DATA_MODEL ?= 32
duke@435 38 endif
duke@435 39
never@1445 40 # zero
never@1445 41 ifeq ($(ZERO_BUILD), true)
never@1445 42 ifeq ($(ARCH_DATA_MODEL), 64)
never@1445 43 MAKE_ARGS += LP64=1
never@1445 44 endif
never@1445 45 PLATFORM = linux-zero
never@1445 46 VM_PLATFORM = linux_$(subst i386,i486,$(ZERO_LIBARCH))
never@1445 47 HS_ARCH = zero
never@1445 48 ARCH = zero
never@1445 49 endif
never@1445 50
duke@435 51 # ia64
duke@435 52 ifeq ($(ARCH), ia64)
duke@435 53 ARCH_DATA_MODEL = 64
duke@435 54 MAKE_ARGS += LP64=1
duke@435 55 PLATFORM = linux-ia64
duke@435 56 VM_PLATFORM = linux_ia64
duke@435 57 HS_ARCH = ia64
duke@435 58 endif
duke@435 59
duke@435 60 # sparc
duke@435 61 ifeq ($(ARCH), sparc64)
duke@435 62 ifeq ($(ARCH_DATA_MODEL), 64)
duke@435 63 ARCH_DATA_MODEL = 64
duke@435 64 MAKE_ARGS += LP64=1
duke@435 65 PLATFORM = linux-sparcv9
duke@435 66 VM_PLATFORM = linux_sparcv9
duke@435 67 else
duke@435 68 ARCH_DATA_MODEL = 32
duke@435 69 PLATFORM = linux-sparc
duke@435 70 VM_PLATFORM = linux_sparc
duke@435 71 endif
duke@435 72 HS_ARCH = sparc
duke@435 73 endif
duke@435 74
duke@435 75 # x86_64
duke@435 76 ifeq ($(ARCH), x86_64)
duke@435 77 ifeq ($(ARCH_DATA_MODEL), 64)
duke@435 78 ARCH_DATA_MODEL = 64
duke@435 79 MAKE_ARGS += LP64=1
duke@435 80 PLATFORM = linux-amd64
duke@435 81 VM_PLATFORM = linux_amd64
duke@435 82 HS_ARCH = x86
duke@435 83 else
duke@435 84 ARCH_DATA_MODEL = 32
duke@435 85 PLATFORM = linux-i586
duke@435 86 VM_PLATFORM = linux_i486
duke@435 87 HS_ARCH = x86
duke@435 88 # We have to reset ARCH to i686 since SRCARCH relies on it
duke@435 89 ARCH = i686
duke@435 90 endif
duke@435 91 endif
duke@435 92
duke@435 93 # i686
duke@435 94 ifeq ($(ARCH), i686)
duke@435 95 ARCH_DATA_MODEL = 32
duke@435 96 PLATFORM = linux-i586
duke@435 97 VM_PLATFORM = linux_i486
duke@435 98 HS_ARCH = x86
duke@435 99 endif
duke@435 100
bobv@2036 101 # ARM
bobv@2036 102 ifeq ($(ARCH), arm)
bobv@2036 103 ARCH_DATA_MODEL = 32
bobv@2036 104 PLATFORM = linux-arm
bobv@2036 105 VM_PLATFORM = linux_arm
bobv@2036 106 HS_ARCH = arm
bobv@2036 107 endif
bobv@2036 108
bobv@2036 109 # PPC
bobv@2036 110 ifeq ($(ARCH), ppc)
bobv@2036 111 ARCH_DATA_MODEL = 32
bobv@2036 112 PLATFORM = linux-ppc
bobv@2036 113 VM_PLATFORM = linux_ppc
bobv@2036 114 HS_ARCH = ppc
bobv@2036 115 endif
bobv@2036 116
duke@435 117 JDK_INCLUDE_SUBDIR=linux
duke@435 118
duke@435 119 # FIXUP: The subdirectory for a debug build is NOT the same on all platforms
duke@435 120 VM_DEBUG=jvmg
duke@435 121
duke@435 122 EXPORT_LIST += $(EXPORT_DOCS_DIR)/platform/jvmti/jvmti.html
kvn@1450 123
kvn@1450 124 # client and server subdirectories have symbolic links to ../libjsig.so
kvn@1450 125 EXPORT_LIST += $(EXPORT_JRE_LIB_ARCH_DIR)/libjsig.so
bobv@2036 126 EXPORT_SERVER_DIR = $(EXPORT_JRE_LIB_ARCH_DIR)/server
kvn@1450 127
bobv@2036 128 ifndef BUILD_CLIENT_ONLY
duke@435 129 EXPORT_LIST += $(EXPORT_SERVER_DIR)/Xusage.txt
duke@435 130 EXPORT_LIST += $(EXPORT_SERVER_DIR)/libjvm.so
bobv@2036 131 endif
bobv@2036 132
never@1445 133 ifneq ($(ZERO_BUILD), true)
never@1445 134 ifeq ($(ARCH_DATA_MODEL), 32)
never@1445 135 EXPORT_CLIENT_DIR = $(EXPORT_JRE_LIB_ARCH_DIR)/client
never@1445 136 EXPORT_LIST += $(EXPORT_CLIENT_DIR)/Xusage.txt
never@1445 137 EXPORT_LIST += $(EXPORT_CLIENT_DIR)/libjvm.so
never@1445 138 endif
duke@435 139 endif
bobv@2036 140
bobv@2036 141 # Serviceability Binaries
bobv@2036 142 # No SA Support for PPC, IA64, ARM or zero
bobv@2036 143 ADD_SA_BINARIES/x86 = $(EXPORT_JRE_LIB_ARCH_DIR)/libsaproc.so \
bobv@2036 144 $(EXPORT_LIB_DIR)/sa-jdi.jar
bobv@2036 145 ADD_SA_BINARIES/sparc = $(EXPORT_JRE_LIB_ARCH_DIR)/libsaproc.so \
bobv@2036 146 $(EXPORT_LIB_DIR)/sa-jdi.jar
bobv@2036 147 ADD_SA_BINARIES/ppc =
bobv@2036 148 ADD_SA_BINARIES/ia64 =
bobv@2036 149 ADD_SA_BINARIES/arm =
bobv@2036 150 ADD_SA_BINARIES/zero =
bobv@2036 151
bobv@2036 152 EXPORT_LIST += $(ADD_SA_BINARIES/$(HS_ARCH))
bobv@2036 153
bobv@2036 154

mercurial