jaxp/makefiles/BuildJaxp.gmk
author ohair
Fri, 26 Oct 2012 14:25:17 -0700
changeset 14250 d3604db57c7b
child 15154 408fa7cb0a4c
permissions -rw-r--r--
8000992: Update new build-infra makefiles Summary: Build-infra project integration. Multiple authors on this work: erikj and ihse primarily, also changes from ohair, tbell, and dholmes. Special credit to ohstrom for his smartjavac work. Reviewed-by: erikj, ihse, dholmes, tbell
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
14250
d3604db57c7b 8000992: Update new build-infra makefiles
ohair
parents:
diff changeset
     1
#
d3604db57c7b 8000992: Update new build-infra makefiles
ohair
parents:
diff changeset
     2
# Copyright (c) 2007, 2012, Oracle and/or its affiliates. All rights reserved.
d3604db57c7b 8000992: Update new build-infra makefiles
ohair
parents:
diff changeset
     3
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
d3604db57c7b 8000992: Update new build-infra makefiles
ohair
parents:
diff changeset
     4
#
d3604db57c7b 8000992: Update new build-infra makefiles
ohair
parents:
diff changeset
     5
# This code is free software; you can redistribute it and/or modify it
d3604db57c7b 8000992: Update new build-infra makefiles
ohair
parents:
diff changeset
     6
# under the terms of the GNU General Public License version 2 only, as
d3604db57c7b 8000992: Update new build-infra makefiles
ohair
parents:
diff changeset
     7
# published by the Free Software Foundation.  Oracle designates this
d3604db57c7b 8000992: Update new build-infra makefiles
ohair
parents:
diff changeset
     8
# particular file as subject to the "Classpath" exception as provided
d3604db57c7b 8000992: Update new build-infra makefiles
ohair
parents:
diff changeset
     9
# by Oracle in the LICENSE file that accompanied this code.
d3604db57c7b 8000992: Update new build-infra makefiles
ohair
parents:
diff changeset
    10
#
d3604db57c7b 8000992: Update new build-infra makefiles
ohair
parents:
diff changeset
    11
# This code is distributed in the hope that it will be useful, but WITHOUT
d3604db57c7b 8000992: Update new build-infra makefiles
ohair
parents:
diff changeset
    12
# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
d3604db57c7b 8000992: Update new build-infra makefiles
ohair
parents:
diff changeset
    13
# FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
d3604db57c7b 8000992: Update new build-infra makefiles
ohair
parents:
diff changeset
    14
# version 2 for more details (a copy is included in the LICENSE file that
d3604db57c7b 8000992: Update new build-infra makefiles
ohair
parents:
diff changeset
    15
# accompanied this code).
d3604db57c7b 8000992: Update new build-infra makefiles
ohair
parents:
diff changeset
    16
#
d3604db57c7b 8000992: Update new build-infra makefiles
ohair
parents:
diff changeset
    17
# You should have received a copy of the GNU General Public License version
d3604db57c7b 8000992: Update new build-infra makefiles
ohair
parents:
diff changeset
    18
# 2 along with this work; if not, write to the Free Software Foundation,
d3604db57c7b 8000992: Update new build-infra makefiles
ohair
parents:
diff changeset
    19
# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
d3604db57c7b 8000992: Update new build-infra makefiles
ohair
parents:
diff changeset
    20
#
d3604db57c7b 8000992: Update new build-infra makefiles
ohair
parents:
diff changeset
    21
# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
d3604db57c7b 8000992: Update new build-infra makefiles
ohair
parents:
diff changeset
    22
# or visit www.oracle.com if you need additional information or have any
d3604db57c7b 8000992: Update new build-infra makefiles
ohair
parents:
diff changeset
    23
# questions.
d3604db57c7b 8000992: Update new build-infra makefiles
ohair
parents:
diff changeset
    24
#
d3604db57c7b 8000992: Update new build-infra makefiles
ohair
parents:
diff changeset
    25
d3604db57c7b 8000992: Update new build-infra makefiles
ohair
parents:
diff changeset
    26
# This must be the first rule
d3604db57c7b 8000992: Update new build-infra makefiles
ohair
parents:
diff changeset
    27
default: all
d3604db57c7b 8000992: Update new build-infra makefiles
ohair
parents:
diff changeset
    28
d3604db57c7b 8000992: Update new build-infra makefiles
ohair
parents:
diff changeset
    29
-include $(SPEC)
d3604db57c7b 8000992: Update new build-infra makefiles
ohair
parents:
diff changeset
    30
include MakeBase.gmk
d3604db57c7b 8000992: Update new build-infra makefiles
ohair
parents:
diff changeset
    31
include JavaCompilation.gmk
d3604db57c7b 8000992: Update new build-infra makefiles
ohair
parents:
diff changeset
    32
d3604db57c7b 8000992: Update new build-infra makefiles
ohair
parents:
diff changeset
    33
JAVAC_JARS ?= "-Xbootclasspath/p:$(LANGTOOLS_OUTPUTDIR)/dist/bootstrap/lib/javac.jar" \
d3604db57c7b 8000992: Update new build-infra makefiles
ohair
parents:
diff changeset
    34
		-jar $(LANGTOOLS_OUTPUTDIR)/dist/bootstrap/lib/javac.jar
d3604db57c7b 8000992: Update new build-infra makefiles
ohair
parents:
diff changeset
    35
DISABLE_JAXP_WARNINGS:=-Xlint:all,-deprecation,-unchecked,-rawtypes,-cast,-serial,-dep-ann,-static,-fallthrough
d3604db57c7b 8000992: Update new build-infra makefiles
ohair
parents:
diff changeset
    36
d3604db57c7b 8000992: Update new build-infra makefiles
ohair
parents:
diff changeset
    37
# The generate new bytecode uses the new compiler for to generate bytecode
d3604db57c7b 8000992: Update new build-infra makefiles
ohair
parents:
diff changeset
    38
# for the new jdk that is being built. The code compiled by this setup
d3604db57c7b 8000992: Update new build-infra makefiles
ohair
parents:
diff changeset
    39
# cannot necessarily be run with the boot jdk.
d3604db57c7b 8000992: Update new build-infra makefiles
ohair
parents:
diff changeset
    40
$(eval $(call SetupJavaCompiler,GENERATE_NEWBYTECODE_DEBUG,\
d3604db57c7b 8000992: Update new build-infra makefiles
ohair
parents:
diff changeset
    41
     JVM:=$(JAVA),\
d3604db57c7b 8000992: Update new build-infra makefiles
ohair
parents:
diff changeset
    42
     JAVAC:=$(JAVAC_JARS),\
d3604db57c7b 8000992: Update new build-infra makefiles
ohair
parents:
diff changeset
    43
     FLAGS:=-XDignore.symbol.file=true $(DISABLE_JAXP_WARNINGS) -g,\
d3604db57c7b 8000992: Update new build-infra makefiles
ohair
parents:
diff changeset
    44
     SERVER_DIR:=$(SJAVAC_SERVER_DIR),\
d3604db57c7b 8000992: Update new build-infra makefiles
ohair
parents:
diff changeset
    45
     SERVER_JVM:=$(SJAVAC_SERVER_JAVA)))
d3604db57c7b 8000992: Update new build-infra makefiles
ohair
parents:
diff changeset
    46
d3604db57c7b 8000992: Update new build-infra makefiles
ohair
parents:
diff changeset
    47
$(eval $(call SetupJavaCompilation,BUILD_JAXP,\
d3604db57c7b 8000992: Update new build-infra makefiles
ohair
parents:
diff changeset
    48
		SETUP:=GENERATE_NEWBYTECODE_DEBUG,\
d3604db57c7b 8000992: Update new build-infra makefiles
ohair
parents:
diff changeset
    49
		SRC:=$(JAXP_TOPDIR)/src,\
d3604db57c7b 8000992: Update new build-infra makefiles
ohair
parents:
diff changeset
    50
		CLEAN:=.properties,\
d3604db57c7b 8000992: Update new build-infra makefiles
ohair
parents:
diff changeset
    51
		BIN:=$(JAXP_OUTPUTDIR)/classes,\
d3604db57c7b 8000992: Update new build-infra makefiles
ohair
parents:
diff changeset
    52
		SRCZIP:=$(JAXP_OUTPUTDIR)/dist/lib/src.zip))
d3604db57c7b 8000992: Update new build-infra makefiles
ohair
parents:
diff changeset
    53
d3604db57c7b 8000992: Update new build-infra makefiles
ohair
parents:
diff changeset
    54
$(eval $(call SetupArchive,ARCHIVE_JAXP,$(BUILD_JAXP),\
d3604db57c7b 8000992: Update new build-infra makefiles
ohair
parents:
diff changeset
    55
		SRCS:=$(JAXP_OUTPUTDIR)/classes,\
d3604db57c7b 8000992: Update new build-infra makefiles
ohair
parents:
diff changeset
    56
		SUFFIXES:=.class .properties,\
d3604db57c7b 8000992: Update new build-infra makefiles
ohair
parents:
diff changeset
    57
		JAR:=$(JAXP_OUTPUTDIR)/dist/lib/classes.jar))
d3604db57c7b 8000992: Update new build-infra makefiles
ohair
parents:
diff changeset
    58
d3604db57c7b 8000992: Update new build-infra makefiles
ohair
parents:
diff changeset
    59
all: $(JAXP_OUTPUTDIR)/dist/lib/classes.jar $(JAXP_OUTPUTDIR)/dist/lib/src.zip
d3604db57c7b 8000992: Update new build-infra makefiles
ohair
parents:
diff changeset
    60
d3604db57c7b 8000992: Update new build-infra makefiles
ohair
parents:
diff changeset
    61
.PHONY: default all