make/linux/Makefile

Mon, 27 Jun 2016 16:59:38 +0800

author
aoqi<aoqi@loongson.cn>
date
Mon, 27 Jun 2016 16:59:38 +0800
changeset 27
d2b3aba483a7
parent 0
f90c822e73f8
child 392
4bfb40d1e17a
permissions
-rw-r--r--

supported 4.* os version.

aoqi@0 1 #
aoqi@0 2 # Copyright (c) 1999, 2013, Oracle and/or its affiliates. All rights reserved.
aoqi@0 3 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
aoqi@0 4 #
aoqi@0 5 # This code is free software; you can redistribute it and/or modify it
aoqi@0 6 # under the terms of the GNU General Public License version 2 only, as
aoqi@0 7 # published by the Free Software Foundation.
aoqi@0 8 #
aoqi@0 9 # This code is distributed in the hope that it will be useful, but WITHOUT
aoqi@0 10 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
aoqi@0 11 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
aoqi@0 12 # version 2 for more details (a copy is included in the LICENSE file that
aoqi@0 13 # accompanied this code).
aoqi@0 14 #
aoqi@0 15 # You should have received a copy of the GNU General Public License version
aoqi@0 16 # 2 along with this work; if not, write to the Free Software Foundation,
aoqi@0 17 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
aoqi@0 18 #
aoqi@0 19 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
aoqi@0 20 # or visit www.oracle.com if you need additional information or have any
aoqi@0 21 # questions.
aoqi@0 22 #
aoqi@0 23 #
aoqi@0 24
aoqi@0 25 # This makefile creates a build tree and lights off a build.
aoqi@0 26 # You can go back into the build tree and perform rebuilds or
aoqi@0 27 # incremental builds as desired. Be sure to reestablish
aoqi@0 28 # environment variable settings for LD_LIBRARY_PATH and JAVA_HOME.
aoqi@0 29
aoqi@0 30 # The make process now relies on java and javac. These can be
aoqi@0 31 # specified either implicitly on the PATH, by setting the
aoqi@0 32 # (JDK-inherited) ALT_BOOTDIR environment variable to full path to a
aoqi@0 33 # JDK in which bin/java and bin/javac are present and working (e.g.,
aoqi@0 34 # /usr/local/java/jdk1.3/solaris), or via the (JDK-inherited)
aoqi@0 35 # default BOOTDIR path value. Note that one of ALT_BOOTDIR
aoqi@0 36 # or BOOTDIR has to be set. We do *not* search javac, javah, rmic etc.
aoqi@0 37 # from the PATH.
aoqi@0 38 #
aoqi@0 39 # One can set ALT_BOOTDIR or BOOTDIR to point to a jdk that runs on
aoqi@0 40 # an architecture that differs from the target architecture, as long
aoqi@0 41 # as the bootstrap jdk runs under the same flavor of OS as the target
aoqi@0 42 # (i.e., if the target is linux, point to a jdk that runs on a linux
aoqi@0 43 # box). In order to use such a bootstrap jdk, set the make variable
aoqi@0 44 # REMOTE to the desired remote command mechanism, e.g.,
aoqi@0 45 #
aoqi@0 46 # make REMOTE="rsh -l me myotherlinuxbox"
aoqi@0 47
aoqi@0 48 # Along with VM, Serviceability Agent (SA) is built for SA/JDI binding.
aoqi@0 49 # JDI binding on SA produces two binaries:
aoqi@0 50 # 1. sa-jdi.jar - This is built before building libjvm.so
aoqi@0 51 # Please refer to ./makefiles/sa.make
aoqi@0 52 # 2. libsa.so - Native library for SA - This is built after
aoqi@0 53 # libjsig.so (signal interposition library)
aoqi@0 54 # Please refer to ./makefiles/vm.make
aoqi@0 55 # If $(GAMMADIR)/agent dir is not present, SA components are not built.
aoqi@0 56
aoqi@0 57 ifeq ($(GAMMADIR),)
aoqi@0 58 include ../../make/defs.make
aoqi@0 59 else
aoqi@0 60 include $(GAMMADIR)/make/defs.make
aoqi@0 61 endif
aoqi@0 62 include $(GAMMADIR)/make/$(OSNAME)/makefiles/rules.make
aoqi@0 63
aoqi@0 64 ifndef CC_INTERP
aoqi@0 65 ifndef FORCE_TIERED
aoqi@0 66 FORCE_TIERED=1
aoqi@0 67 endif
aoqi@0 68 endif
aoqi@0 69 # C1 is not ported on ppc64, so we cannot build a tiered VM:
aoqi@0 70 ifeq ($(ARCH),ppc64)
aoqi@0 71 FORCE_TIERED=0
aoqi@0 72 endif
aoqi@0 73
aoqi@0 74 ifdef LP64
aoqi@0 75 ifeq ("$(filter $(LP64_ARCH),$(BUILDARCH))","")
aoqi@0 76 _JUNK_ := $(shell echo >&2 \
aoqi@0 77 $(OSNAME) $(ARCH) "*** ERROR: this platform does not support 64-bit compilers!")
aoqi@0 78 @exit 1
aoqi@0 79 endif
aoqi@0 80 endif
aoqi@0 81
aoqi@0 82 # we need to set up LP64 correctly to satisfy sanity checks in adlc
aoqi@0 83 ifneq ("$(filter $(LP64_ARCH),$(BUILDARCH))","")
aoqi@0 84 MFLAGS += " LP64=1 "
aoqi@0 85 endif
aoqi@0 86
aoqi@0 87 # pass USE_SUNCC further, through MFLAGS
aoqi@0 88 ifdef USE_SUNCC
aoqi@0 89 MFLAGS += " USE_SUNCC=1 "
aoqi@0 90 endif
aoqi@0 91
aoqi@0 92 # The following renders pathnames in generated Makefiles valid on
aoqi@0 93 # machines other than the machine containing the build tree.
aoqi@0 94 #
aoqi@0 95 # For example, let's say my build tree lives on /files12 on
aoqi@0 96 # exact.east.sun.com. This logic will cause GAMMADIR to begin with
aoqi@0 97 # /net/exact/files12/...
aoqi@0 98 #
aoqi@0 99 # We only do this on SunOS variants, for a couple of reasons:
aoqi@0 100 # * It is extremely rare that source trees exist on other systems
aoqi@0 101 # * It has been claimed that the Linux automounter is flakey, so
aoqi@0 102 # changing GAMMADIR in a way that exercises the automounter could
aoqi@0 103 # prove to be a source of unreliability in the build process.
aoqi@0 104 # Obviously, this Makefile is only relevant on SunOS boxes to begin
aoqi@0 105 # with, but the SunOS conditionalization will make it easier to
aoqi@0 106 # combine Makefiles in the future (assuming we ever do that).
aoqi@0 107
aoqi@0 108 ifeq ($(OSNAME),solaris)
aoqi@0 109
aoqi@0 110 # prepend current directory to relative pathnames.
aoqi@0 111 NEW_GAMMADIR := \
aoqi@0 112 $(shell echo $(GAMMADIR) | \
aoqi@0 113 sed -e "s=^\([^/].*\)=$(shell pwd)/\1=" \
aoqi@0 114 )
aoqi@0 115 unexport NEW_GAMMADIR
aoqi@0 116
aoqi@0 117 # If NEW_GAMMADIR doesn't already start with "/net/":
aoqi@0 118 ifeq ($(strip $(filter /net/%,$(NEW_GAMMADIR))),)
aoqi@0 119 # prepend /net/$(HOST)
aoqi@0 120 # remove /net/$(HOST) if name already began with /home/
aoqi@0 121 # remove /net/$(HOST) if name already began with /java/
aoqi@0 122 # remove /net/$(HOST) if name already began with /lab/
aoqi@0 123 NEW_GAMMADIR := \
aoqi@0 124 $(shell echo $(NEW_GAMMADIR) | \
aoqi@0 125 sed -e "s=^\(.*\)=/net/$(HOST)\1=" \
aoqi@0 126 -e "s=^/net/$(HOST)/home/=/home/=" \
aoqi@0 127 -e "s=^/net/$(HOST)/java/=/java/=" \
aoqi@0 128 -e "s=^/net/$(HOST)/lab/=/lab/=" \
aoqi@0 129 )
aoqi@0 130 # Don't use the new value for GAMMADIR unless a file with the new
aoqi@0 131 # name actually exists.
aoqi@0 132 ifneq ($(wildcard $(NEW_GAMMADIR)),)
aoqi@0 133 GAMMADIR := $(NEW_GAMMADIR)
aoqi@0 134 endif
aoqi@0 135 endif
aoqi@0 136
aoqi@0 137 endif
aoqi@0 138
aoqi@0 139 # BUILDARCH is set to "zero" for Zero builds. VARIANTARCH
aoqi@0 140 # is used to give the build directories meaningful names.
aoqi@0 141 VARIANTARCH = $(subst i386,i486,$(ZERO_LIBARCH))
aoqi@0 142
aoqi@0 143 # There is a (semi-) regular correspondence between make targets and actions:
aoqi@0 144 #
aoqi@0 145 # Target Tree Type Build Dir
aoqi@0 146 #
aoqi@0 147 # debug compiler2 <os>_<arch>_compiler2/debug
aoqi@0 148 # fastdebug compiler2 <os>_<arch>_compiler2/fastdebug
aoqi@0 149 # optimized compiler2 <os>_<arch>_compiler2/optimized
aoqi@0 150 # product compiler2 <os>_<arch>_compiler2/product
aoqi@0 151 #
aoqi@0 152 # debug1 compiler1 <os>_<arch>_compiler1/debug
aoqi@0 153 # fastdebug1 compiler1 <os>_<arch>_compiler1/fastdebug
aoqi@0 154 # optimized1 compiler1 <os>_<arch>_compiler1/optimized
aoqi@0 155 # product1 compiler1 <os>_<arch>_compiler1/product
aoqi@0 156 #
aoqi@0 157 # debugcore core <os>_<arch>_core/debug
aoqi@0 158 # fastdebugcore core <os>_<arch>_core/fastdebug
aoqi@0 159 # optimizedcore core <os>_<arch>_core/optimized
aoqi@0 160 # productcore core <os>_<arch>_core/product
aoqi@0 161 #
aoqi@0 162 # debugzero zero <os>_<arch>_zero/debug
aoqi@0 163 # fastdebugzero zero <os>_<arch>_zero/fastdebug
aoqi@0 164 # optimizedzero zero <os>_<arch>_zero/optimized
aoqi@0 165 # productzero zero <os>_<arch>_zero/product
aoqi@0 166 #
aoqi@0 167 # debugshark shark <os>_<arch>_shark/debug
aoqi@0 168 # fastdebugshark shark <os>_<arch>_shark/fastdebug
aoqi@0 169 # optimizedshark shark <os>_<arch>_shark/optimized
aoqi@0 170 # productshark shark <os>_<arch>_shark/product
aoqi@0 171 #
aoqi@0 172 # fastdebugminimal1 minimal1 <os>_<arch>_minimal1/fastdebug
aoqi@0 173 # productminimal1 minimal1 <os>_<arch>_minimal1/product
aoqi@0 174 #
aoqi@0 175 # What you get with each target:
aoqi@0 176 #
aoqi@0 177 # debug* - debug compile with asserts enabled
aoqi@0 178 # fastdebug* - optimized compile, but with asserts enabled
aoqi@0 179 # optimized* - optimized compile, no asserts
aoqi@0 180 # product* - the shippable thing: optimized compile, no asserts, -DPRODUCT
aoqi@0 181
aoqi@0 182 # This target list needs to be coordinated with the usage message
aoqi@0 183 # in the build.sh script:
aoqi@0 184 TARGETS = debug fastdebug optimized product
aoqi@0 185
aoqi@0 186 ifeq ($(findstring true, $(JVM_VARIANT_ZERO) $(JVM_VARIANT_ZEROSHARK)), true)
aoqi@0 187 SUBDIR_DOCS = $(OSNAME)_$(VARIANTARCH)_docs
aoqi@0 188 else
aoqi@0 189 SUBDIR_DOCS = $(OSNAME)_$(BUILDARCH)_docs
aoqi@0 190 endif
aoqi@0 191 SUBDIRS_C1 = $(addprefix $(OSNAME)_$(BUILDARCH)_compiler1/,$(TARGETS))
aoqi@0 192 SUBDIRS_C2 = $(addprefix $(OSNAME)_$(BUILDARCH)_compiler2/,$(TARGETS))
aoqi@0 193 SUBDIRS_TIERED = $(addprefix $(OSNAME)_$(BUILDARCH)_tiered/,$(TARGETS))
aoqi@0 194 SUBDIRS_CORE = $(addprefix $(OSNAME)_$(BUILDARCH)_core/,$(TARGETS))
aoqi@0 195 SUBDIRS_ZERO = $(addprefix $(OSNAME)_$(VARIANTARCH)_zero/,$(TARGETS))
aoqi@0 196 SUBDIRS_SHARK = $(addprefix $(OSNAME)_$(VARIANTARCH)_shark/,$(TARGETS))
aoqi@0 197 SUBDIRS_MINIMAL1 = $(addprefix $(OSNAME)_$(BUILDARCH)_minimal1/,$(TARGETS))
aoqi@0 198
aoqi@0 199 TARGETS_C2 = $(TARGETS)
aoqi@0 200 TARGETS_C1 = $(addsuffix 1,$(TARGETS))
aoqi@0 201 TARGETS_TIERED = $(addsuffix tiered,$(TARGETS))
aoqi@0 202 TARGETS_CORE = $(addsuffix core,$(TARGETS))
aoqi@0 203 TARGETS_ZERO = $(addsuffix zero,$(TARGETS))
aoqi@0 204 TARGETS_SHARK = $(addsuffix shark,$(TARGETS))
aoqi@0 205 TARGETS_MINIMAL1 = $(addsuffix minimal1,$(TARGETS))
aoqi@0 206
aoqi@0 207 BUILDTREE_MAKE = $(GAMMADIR)/make/$(OSNAME)/makefiles/buildtree.make
aoqi@0 208 BUILDTREE_VARS = GAMMADIR=$(GAMMADIR) OS_FAMILY=$(OSNAME) SRCARCH=$(SRCARCH) BUILDARCH=$(BUILDARCH) LIBARCH=$(LIBARCH)
aoqi@0 209 BUILDTREE_VARS += HOTSPOT_RELEASE_VERSION=$(HOTSPOT_RELEASE_VERSION) HOTSPOT_BUILD_VERSION=$(HOTSPOT_BUILD_VERSION) JRE_RELEASE_VERSION=$(JRE_RELEASE_VERSION)
aoqi@0 210 BUILDTREE_VARS += ENABLE_FULL_DEBUG_SYMBOLS=$(ENABLE_FULL_DEBUG_SYMBOLS) OBJCOPY=$(OBJCOPY) STRIP_POLICY=$(STRIP_POLICY) ZIP_DEBUGINFO_FILES=$(ZIP_DEBUGINFO_FILES) ZIPEXE=$(ZIPEXE)
aoqi@0 211
aoqi@0 212 BUILDTREE = $(MAKE) -f $(BUILDTREE_MAKE) $(BUILDTREE_VARS)
aoqi@0 213
aoqi@0 214 #-------------------------------------------------------------------------------
aoqi@0 215
aoqi@0 216 # Could make everything by default, but that would take a while.
aoqi@0 217 all:
aoqi@0 218 @echo "Try '$(MAKE) <target> ...' where <target> is one or more of"
aoqi@0 219 @echo " $(TARGETS_C2)"
aoqi@0 220 @echo " $(TARGETS_C1)"
aoqi@0 221 @echo " $(TARGETS_CORE)"
aoqi@0 222 @echo " $(TARGETS_ZERO)"
aoqi@0 223 @echo " $(TARGETS_SHARK)"
aoqi@0 224 @echo " $(TARGETS_MINIMAL1)"
aoqi@0 225
aoqi@0 226 checks: check_os_version check_j2se_version
aoqi@0 227
aoqi@0 228 # We do not want people accidentally building on old systems (e.g. Linux 2.2.x,
aoqi@0 229 # Solaris 2.5.1, 2.6).
aoqi@0 230 # Disable this check by setting DISABLE_HOTSPOT_OS_VERSION_CHECK=ok.
aoqi@0 231
aoqi@27 232 SUPPORTED_OS_VERSION = 2.4% 2.5% 2.6% 3% 4%
aoqi@0 233 OS_VERSION := $(shell uname -r)
aoqi@0 234 EMPTY_IF_NOT_SUPPORTED = $(filter $(SUPPORTED_OS_VERSION),$(OS_VERSION))
aoqi@0 235
aoqi@0 236 check_os_version:
aoqi@0 237 ifeq ($(DISABLE_HOTSPOT_OS_VERSION_CHECK)$(EMPTY_IF_NOT_SUPPORTED),)
aoqi@0 238 $(QUIETLY) >&2 echo "*** This OS is not supported:" `uname -a`; exit 1;
aoqi@0 239 endif
aoqi@0 240
aoqi@0 241 # jvmti.make requires XSLT (J2SE 1.4.x or newer):
aoqi@0 242 XSLT_CHECK = $(REMOTE) $(RUN.JAVAP) javax.xml.transform.TransformerFactory
aoqi@0 243 # If not found then fail fast.
aoqi@0 244 check_j2se_version:
aoqi@0 245 $(QUIETLY) $(XSLT_CHECK) > /dev/null 2>&1; \
aoqi@0 246 if [ $$? -ne 0 ]; then \
aoqi@0 247 $(REMOTE) $(RUN.JAVA) -version; \
aoqi@0 248 echo "*** An XSLT processor (J2SE 1.4.x or newer) is required" \
aoqi@0 249 "to bootstrap this build" 1>&2; \
aoqi@0 250 exit 1; \
aoqi@0 251 fi
aoqi@0 252
aoqi@0 253 $(SUBDIRS_TIERED): $(BUILDTREE_MAKE)
aoqi@0 254 $(QUIETLY) $(MAKE) -f $(GAMMADIR)/make/$(OSNAME)/Makefile checks
aoqi@0 255 $(BUILDTREE) VARIANT=tiered
aoqi@0 256
aoqi@0 257 $(SUBDIRS_C2): $(BUILDTREE_MAKE)
aoqi@0 258 ifeq ($(FORCE_TIERED),1)
aoqi@0 259 $(QUIETLY) $(MAKE) -f $(GAMMADIR)/make/$(OSNAME)/Makefile checks
aoqi@0 260 $(BUILDTREE) VARIANT=tiered FORCE_TIERED=1
aoqi@0 261 else
aoqi@0 262 $(QUIETLY) $(MAKE) -f $(GAMMADIR)/make/$(OSNAME)/Makefile checks
aoqi@0 263 $(BUILDTREE) VARIANT=compiler2
aoqi@0 264 endif
aoqi@0 265
aoqi@0 266 $(SUBDIRS_C1): $(BUILDTREE_MAKE)
aoqi@0 267 $(QUIETLY) $(MAKE) -f $(GAMMADIR)/make/$(OSNAME)/Makefile checks
aoqi@0 268 $(BUILDTREE) VARIANT=compiler1
aoqi@0 269
aoqi@0 270 $(SUBDIRS_CORE): $(BUILDTREE_MAKE)
aoqi@0 271 $(QUIETLY) $(MAKE) -f $(GAMMADIR)/make/$(OSNAME)/Makefile checks
aoqi@0 272 $(BUILDTREE) VARIANT=core
aoqi@0 273
aoqi@0 274 $(SUBDIRS_ZERO): $(BUILDTREE_MAKE) platform_zero
aoqi@0 275 $(QUIETLY) $(MAKE) -f $(GAMMADIR)/make/$(OSNAME)/Makefile checks
aoqi@0 276 $(BUILDTREE) VARIANT=zero VARIANTARCH=$(VARIANTARCH)
aoqi@0 277
aoqi@0 278 $(SUBDIRS_SHARK): $(BUILDTREE_MAKE) platform_zero
aoqi@0 279 $(QUIETLY) $(MAKE) -f $(GAMMADIR)/make/$(OSNAME)/Makefile checks
aoqi@0 280 $(BUILDTREE) VARIANT=shark VARIANTARCH=$(VARIANTARCH)
aoqi@0 281
aoqi@0 282 $(SUBDIRS_MINIMAL1): $(BUILDTREE_MAKE)
aoqi@0 283 $(QUIETLY) $(MAKE) -f $(GAMMADIR)/make/$(OSNAME)/Makefile checks
aoqi@0 284 $(BUILDTREE) VARIANT=minimal1
aoqi@0 285
aoqi@0 286
aoqi@0 287 platform_zero: $(GAMMADIR)/make/$(OSNAME)/platform_zero.in
aoqi@0 288 $(SED) 's/@ZERO_ARCHDEF@/$(ZERO_ARCHDEF)/g;s/@ZERO_LIBARCH@/$(ZERO_LIBARCH)/g;' < $< > $@
aoqi@0 289
aoqi@0 290 # Define INSTALL=y at command line to automatically copy JVM into JAVA_HOME
aoqi@0 291
aoqi@0 292 $(TARGETS_C2): $(SUBDIRS_C2)
aoqi@0 293 cd $(OSNAME)_$(BUILDARCH)_compiler2/$@ && $(MAKE) $(MFLAGS)
aoqi@0 294 ifdef INSTALL
aoqi@0 295 cd $(OSNAME)_$(BUILDARCH)_compiler2/$@ && $(MAKE) $(MFLAGS) install
aoqi@0 296 endif
aoqi@0 297
aoqi@0 298 $(TARGETS_TIERED): $(SUBDIRS_TIERED)
aoqi@0 299 cd $(OSNAME)_$(BUILDARCH)_tiered/$(patsubst %tiered,%,$@) && $(MAKE) $(MFLAGS)
aoqi@0 300 ifdef INSTALL
aoqi@0 301 cd $(OSNAME)_$(BUILDARCH)_tiered/$(patsubst %tiered,%,$@) && $(MAKE) $(MFLAGS) install
aoqi@0 302 endif
aoqi@0 303
aoqi@0 304 $(TARGETS_C1): $(SUBDIRS_C1)
aoqi@0 305 cd $(OSNAME)_$(BUILDARCH)_compiler1/$(patsubst %1,%,$@) && $(MAKE) $(MFLAGS)
aoqi@0 306 ifdef INSTALL
aoqi@0 307 cd $(OSNAME)_$(BUILDARCH)_compiler1/$(patsubst %1,%,$@) && $(MAKE) $(MFLAGS) install
aoqi@0 308 endif
aoqi@0 309
aoqi@0 310 $(TARGETS_CORE): $(SUBDIRS_CORE)
aoqi@0 311 cd $(OSNAME)_$(BUILDARCH)_core/$(patsubst %core,%,$@) && $(MAKE) $(MFLAGS)
aoqi@0 312 ifdef INSTALL
aoqi@0 313 cd $(OSNAME)_$(BUILDARCH)_core/$(patsubst %core,%,$@) && $(MAKE) $(MFLAGS) install
aoqi@0 314 endif
aoqi@0 315
aoqi@0 316 $(TARGETS_ZERO): $(SUBDIRS_ZERO)
aoqi@0 317 cd $(OSNAME)_$(VARIANTARCH)_zero/$(patsubst %zero,%,$@) && $(MAKE) $(MFLAGS)
aoqi@0 318 ifdef INSTALL
aoqi@0 319 cd $(OSNAME)_$(VARIANTARCH)_zero/$(patsubst %zero,%,$@) && $(MAKE) $(MFLAGS) install
aoqi@0 320 endif
aoqi@0 321
aoqi@0 322 $(TARGETS_SHARK): $(SUBDIRS_SHARK)
aoqi@0 323 cd $(OSNAME)_$(VARIANTARCH)_shark/$(patsubst %shark,%,$@) && $(MAKE) $(MFLAGS)
aoqi@0 324 ifdef INSTALL
aoqi@0 325 cd $(OSNAME)_$(VARIANTARCH)_shark/$(patsubst %shark,%,$@) && $(MAKE) $(MFLAGS) install
aoqi@0 326 endif
aoqi@0 327
aoqi@0 328 $(TARGETS_MINIMAL1): $(SUBDIRS_MINIMAL1)
aoqi@0 329 cd $(OSNAME)_$(BUILDARCH)_minimal1/$(patsubst %minimal1,%,$@) && $(MAKE) $(MFLAGS)
aoqi@0 330 ifdef INSTALL
aoqi@0 331 cd $(OSNAME)_$(BUILDARCH)_minimal1/$(patsubst %minimal1,%,$@) && $(MAKE) $(MFLAGS) install
aoqi@0 332 endif
aoqi@0 333
aoqi@0 334 # Just build the tree, and nothing else:
aoqi@0 335 tree: $(SUBDIRS_C2)
aoqi@0 336 tree1: $(SUBDIRS_C1)
aoqi@0 337 treecore: $(SUBDIRS_CORE)
aoqi@0 338 treezero: $(SUBDIRS_ZERO)
aoqi@0 339 treeshark: $(SUBDIRS_SHARK)
aoqi@0 340 treeminimal1: $(SUBDIRS_MINIMAL1)
aoqi@0 341
aoqi@0 342 # Doc target. This is the same for all build options.
aoqi@0 343 # Hence create a docs directory beside ...$(ARCH)_[...]
aoqi@0 344 # We specify 'BUILD_FLAVOR=product' so that the proper
aoqi@0 345 # ENABLE_FULL_DEBUG_SYMBOLS value is used.
aoqi@0 346 docs: checks
aoqi@0 347 $(QUIETLY) mkdir -p $(SUBDIR_DOCS)
aoqi@0 348 $(MAKE) -f $(GAMMADIR)/make/$(OSNAME)/makefiles/jvmti.make $(MFLAGS) $(BUILDTREE_VARS) JvmtiOutDir=$(SUBDIR_DOCS) BUILD_FLAVOR=product jvmtidocs
aoqi@0 349
aoqi@0 350 # Synonyms for win32-like targets.
aoqi@0 351 compiler2: debug product
aoqi@0 352
aoqi@0 353 compiler1: debug1 product1
aoqi@0 354
aoqi@0 355 core: debugcore productcore
aoqi@0 356
aoqi@0 357 zero: debugzero productzero
aoqi@0 358
aoqi@0 359 shark: debugshark productshark
aoqi@0 360
aoqi@0 361 warn_jvmg_deprecated:
aoqi@0 362 echo "Warning: The jvmg target has been replaced with debug"
aoqi@0 363 echo "Warning: Please update your usage"
aoqi@0 364
aoqi@0 365 jvmg: warn_jvmg_deprecated debug
aoqi@0 366
aoqi@0 367 jvmg1: warn_jvmg_deprecated debug1
aoqi@0 368
aoqi@0 369 jvmgcore: warn_jvmg_deprecated debugcore
aoqi@0 370
aoqi@0 371 jvmgzero: warn_jvmg_deprecated debugzero
aoqi@0 372
aoqi@0 373 jvmgshark: warn_jvmg_deprecated debugshark
aoqi@0 374
aoqi@0 375 clean_docs:
aoqi@0 376 rm -rf $(SUBDIR_DOCS)
aoqi@0 377
aoqi@0 378 clean_compiler1 clean_compiler2 clean_core clean_zero clean_shark clean_minimal1:
aoqi@0 379 rm -rf $(OSNAME)_$(BUILDARCH)_$(subst clean_,,$@)
aoqi@0 380
aoqi@0 381 clean: clean_compiler2 clean_compiler1 clean_core clean_zero clean_shark clean_minimal1 clean_docs
aoqi@0 382
aoqi@0 383 include $(GAMMADIR)/make/cscope.make
aoqi@0 384
aoqi@0 385 #
aoqi@0 386 # Include alternate Makefile if it exists.
aoqi@0 387 #
aoqi@0 388 -include $(HS_ALT_MAKE)/$(OSNAME)/Makefile.make
aoqi@0 389
aoqi@0 390 #-------------------------------------------------------------------------------
aoqi@0 391
aoqi@0 392 .PHONY: $(TARGETS_C2) $(TARGETS_C1) $(TARGETS_CORE) $(TARGETS_ZERO) $(TARGETS_SHARK) $(TARGETS_MINIMAL1)
aoqi@0 393 .PHONY: tree tree1 treecore treezero treeshark
aoqi@0 394 .PHONY: all compiler1 compiler2 core zero shark
aoqi@0 395 .PHONY: clean clean_compiler1 clean_compiler2 clean_core clean_zero clean_shark docs clean_docs
aoqi@0 396 .PHONY: checks check_os_version check_j2se_version
aoqi@0 397 .PHONY: $(HS_ALT_MAKE)/$(OSNAME)/Makefile.make

mercurial