2796N/A# Copyright (c) 1999, 2011, Oracle and/or its affiliates. All rights reserved. 2796N/A# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 2796N/A# This code is free software; you can redistribute it and/or modify it 2796N/A# under the terms of the GNU General Public License version 2 only, as 2796N/A# published by the Free Software Foundation. 2796N/A# This code is distributed in the hope that it will be useful, but WITHOUT 2796N/A# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 2796N/A# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 2796N/A# version 2 for more details (a copy is included in the LICENSE file that 2796N/A# You should have received a copy of the GNU General Public License version 2796N/A# 2 along with this work; if not, write to the Free Software Foundation, 2796N/A# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 2796N/A# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 2796N/A# This makefile creates a build tree and lights off a build. 2796N/A# You can go back into the build tree and perform rebuilds or 2796N/A# incremental builds as desired. Be sure to reestablish 2796N/A# environment variable settings for LD_LIBRARY_PATH and JAVA_HOME. 2796N/A# The make process now relies on java and javac. These can be 2796N/A# specified either implicitly on the PATH, by setting the 2796N/A# (JDK-inherited) ALT_BOOTDIR environment variable to full path to a 2796N/A# default BOOTDIR path value. Note that one of ALT_BOOTDIR 2796N/A# or BOOTDIR has to be set. We do *not* search javac, javah, rmic etc. 2796N/A# One can set ALT_BOOTDIR or BOOTDIR to point to a jdk that runs on 2796N/A# an architecture that differs from the target architecture, as long 2796N/A# as the bootstrap jdk runs under the same flavor of OS as the target 2796N/A# (i.e., if the target is linux, point to a jdk that runs on a linux 2796N/A# box). In order to use such a bootstrap jdk, set the make variable 2796N/A# REMOTE to the desired remote command mechanism, e.g., 2796N/A# make REMOTE="rsh -l me myotherlinuxbox" 2796N/A# Along with VM, Serviceability Agent (SA) is built for SA/JDI binding. 2796N/A# JDI binding on SA produces two binaries: 2796N/A# 2. libsa[_g].so - Native library for SA - This is built after 2796N/A# libjsig[_g].so (signal interposition library) 2796N/A# If $(GAMMADIR)/agent dir is not present, SA components are not built. 2796N/A $(OSNAME) $(ARCH) "*** ERROR: this platform does not support 64-bit compilers!") 2796N/A# we need to set up LP64 correctly to satisfy sanity checks in adlc 2796N/A# pass USE_SUNCC further, through MFLAGS 2796N/A# The following renders pathnames in generated Makefiles valid on 2796N/A# machines other than the machine containing the build tree. 2796N/A# For example, let's say my build tree lives on /files12 on 2796N/A# We only do this on SunOS variants, for a couple of reasons: 2796N/A# * It is extremely rare that source trees exist on other systems 2796N/A# * It has been claimed that the Linux automounter is flakey, so 2796N/A# changing GAMMADIR in a way that exercises the automounter could 2796N/A# prove to be a source of unreliability in the build process. 2796N/A# Obviously, this Makefile is only relevant on SunOS boxes to begin 2796N/A# with, but the SunOS conditionalization will make it easier to 2796N/A# combine Makefiles in the future (assuming we ever do that). 2796N/A # prepend current directory to relative pathnames. 2796N/A # If NEW_GAMMADIR doesn't already start with "/net/": 2796N/A # remove /net/$(HOST) if name already began with /home/ 2796N/A # remove /net/$(HOST) if name already began with /java/ 2796N/A # remove /net/$(HOST) if name already began with /lab/ 2796N/A # Don't use the new value for GAMMADIR unless a file with the new 2796N/A# BUILDARCH is set to "zero" for Zero builds. VARIANTARCH 2796N/A# is used to give the build directories meaningful names. 2796N/A# There is a (semi-) regular correspondence between make targets and actions: 2796N/A# Target Tree Type Build Dir 2796N/A# What you get with each target: 2796N/A# debug* - "thin" libjvm_g - debug info linked into the gamma_g launcher 2796N/A# fastdebug* - optimized compile, but with asserts enabled 2796N/A# optimized* - optimized compile, no asserts 2796N/A# product* - the shippable thing: optimized compile, no asserts, -DPRODUCT 2796N/A# This target list needs to be coordinated with the usage message 2796N/A#------------------------------------------------------------------------------- 2796N/A# Could make everything by default, but that would take a while. 2796N/A @
echo "Try '$(MAKE) <target> ...' where <target> is one or more of" 2796N/A# We do not want people accidentally building on old systems (e.g. Linux 2.2.x, 2796N/A# Disable this check by setting DISABLE_HOTSPOT_OS_VERSION_CHECK=ok. 2796N/A#SUPPORTED_OS_VERSION = 2.4% 2.5% 2.6% 2.7% 2796N/A# If not found then fail fast. 2796N/A echo "*** An XSLT processor (J2SE 1.4.x or newer) is required" \
2796N/A "to bootstrap this build" 1>&
2; \
2796N/A $(SED) 's/@ZERO_ARCHDEF@/$(ZERO_ARCHDEF)/g;s/@ZERO_LIBARCH@/$(ZERO_LIBARCH)/g;' < $< > $@
2796N/A# Define INSTALL=y at command line to automatically copy JVM into JAVA_HOME 2796N/A# Just build the tree, and nothing else: 2796N/A# Doc target. This is the same for all build options. 2796N/A# Hence create a docs directory beside ...$(ARCH)_[...] 2796N/A# Synonyms for win32-like targets. 2796N/A#-------------------------------------------------------------------------------