Makefile revision 395
ece9652d971886b99a269656ea4782319637e75avboxsync# Copyright 2007 Sun Microsystems, Inc. All Rights Reserved.
ece9652d971886b99a269656ea4782319637e75avboxsync# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
ece9652d971886b99a269656ea4782319637e75avboxsync# This code is free software; you can redistribute it and/or modify it
ece9652d971886b99a269656ea4782319637e75avboxsync# under the terms of the GNU General Public License version 2 only, as
c7814cf6e1240a519cbec0441e033d0e2470ed00vboxsync# published by the Free Software Foundation. Sun designates this
ece9652d971886b99a269656ea4782319637e75avboxsync# particular file as subject to the "Classpath" exception as provided
ece9652d971886b99a269656ea4782319637e75avboxsync# by Sun in the LICENSE file that accompanied this code.
ece9652d971886b99a269656ea4782319637e75avboxsync# This code is distributed in the hope that it will be useful, but WITHOUT
ece9652d971886b99a269656ea4782319637e75avboxsync# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
ece9652d971886b99a269656ea4782319637e75avboxsync# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
ece9652d971886b99a269656ea4782319637e75avboxsync# version 2 for more details (a copy is included in the LICENSE file that
ece9652d971886b99a269656ea4782319637e75avboxsync# accompanied this code).
ece9652d971886b99a269656ea4782319637e75avboxsync# You should have received a copy of the GNU General Public License version
ece9652d971886b99a269656ea4782319637e75avboxsync# 2 along with this work; if not, write to the Free Software Foundation,
ece9652d971886b99a269656ea4782319637e75avboxsync# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
ece9652d971886b99a269656ea4782319637e75avboxsync# Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
ece9652d971886b99a269656ea4782319637e75avboxsync# CA 95054 USA or visit www.sun.com if you need additional information or
ece9652d971886b99a269656ea4782319637e75avboxsync# have any questions.
ece9652d971886b99a269656ea4782319637e75avboxsync# Makefile for langtools: wrapper around Ant build.xml file
e49c9560a28711a6b95871372673b6f8cc7384b6vboxsync# On Solaris, the 'make' utility from Sun will not work with these makefiles.
36ec4b6f42e209d010ade084a96f46ce763345eavboxsync# This little rule is only understood by Sun's make, and is harmless
796561faea8c2b07290fef332968d6048bbe1b1dvboxsync# when seen by the GNU make tool. If using Sun's make, this causes the
e35d51bc86d234abdf08fe247ea901501faa022fvboxsync# make command to fail.
796561faea8c2b07290fef332968d6048bbe1b1dvboxsyncSUN_MAKE_TEST:sh = @echo "ERROR: PLEASE USE GNU VERSION OF MAKE"; exit 33
796561faea8c2b07290fef332968d6048bbe1b1dvboxsync# Minimal platform defs
796561faea8c2b07290fef332968d6048bbe1b1dvboxsync# Need FullPath because we can't rely on gnumake abspath, until we use v3.81
e49c9560a28711a6b95871372673b6f8cc7384b6vboxsync# Makefile args
ece9652d971886b99a269656ea4782319637e75avboxsync ANT_OPTIONS += -Dfull.version='$(FULL_VERSION)' # will contain spaces
ece9652d971886b99a269656ea4782319637e75avboxsync# Note: jdk/make/common/Defs.gmk uses LANGUAGE_VERSION (-source NN)
08edd51145a38b2daffd73601db32bcd9a903514vboxsync# and the somewhat misnamed CLASS_VERSION (-target NN)
ece9652d971886b99a269656ea4782319637e75avboxsync ANT_OPTIONS += -Djavac.target=$(TARGET_CLASS_VERSION)
e49c9560a28711a6b95871372673b6f8cc7384b6vboxsync ANT_OPTIONS += -Djavac.source=$(SOURCE_LANGUAGE_VERSION)
f910333674d7dd65ca746ec010ef354fd239cea4vboxsync#ABS_OUTPUTDIR = $(abspath $(OUTPUTDIR))
0be1c98f1388ddc063a7e830f53e2018f658b348vboxsyncANT_OPTS = ANT_OPTS=-Djava.io.tmpdir='$(ANT_TMPDIR)'
f910333674d7dd65ca746ec010ef354fd239cea4vboxsync $(error $(ANT) not found -- please update ANT_HOME)
f910333674d7dd65ca746ec010ef354fd239cea4vboxsync ifneq ($(shell test -x "`which $(ANT)`" && echo OK), OK)
f910333674d7dd65ca746ec010ef354fd239cea4vboxsync $(error 'ant' not found -- please set ANT_HOME or put 'ant' on your PATH)
6cb1a01aaf746e26c5190a7b0fca706393bdf3aevboxsync# Default target and expected 'do everything' target
6cb1a01aaf746e26c5190a7b0fca706393bdf3aevboxsync# Standard make clobber target
6cb1a01aaf746e26c5190a7b0fca706393bdf3aevboxsync# All ant targets of interest
6cb1a01aaf746e26c5190a7b0fca706393bdf3aevboxsyncANT_TARGETS = build clean sanity post-sanity diagnostics # for now
6cb1a01aaf746e26c5190a7b0fca706393bdf3aevboxsync# Create a make target for each
6cb1a01aaf746e26c5190a7b0fca706393bdf3aevboxsync $(ANT_JAVA_HOME) $(ANT_OPTS) $(ANT) -diagnostics > $(OUTPUTDIR)/build/ant-diagnostics.log
6cb1a01aaf746e26c5190a7b0fca706393bdf3aevboxsync $(ANT_JAVA_HOME) $(ANT_OPTS) $(ANT) $(ANT_OPTIONS) $@
6cb1a01aaf746e26c5190a7b0fca706393bdf3aevboxsync#-------------------------------------------------------------------
992ef02987d71b2b9f73a50265997c7f8e384886vboxsync# Targets for Sun's internal JPRT build system
992ef02987d71b2b9f73a50265997c7f8e384886vboxsyncJPRT_ARCHIVE_BUNDLE=$(ABS_OUTPUTDIR)/$(JPRT_BUILD_FLAVOR)-bundle.zip
6cb1a01aaf746e26c5190a7b0fca706393bdf3aevboxsyncjprt_build_product jprt_build_debug jprt_build_fastdebug: all
6cb1a01aaf746e26c5190a7b0fca706393bdf3aevboxsync#-------------------------------------------------------------------
6cb1a01aaf746e26c5190a7b0fca706393bdf3aevboxsync# Declare these phony (not filenames)