jdk/make/gendata/GendataBreakIterator.gmk
author alanb
Thu, 17 Mar 2016 19:04:16 +0000
changeset 36511 9d0388c6b336
parent 36014 3d50784f2dc2
child 36750 cb05d63f5bb2
permissions -rw-r--r--
8142968: Module System implementation Summary: Initial integration of JEP 200, JEP 260, JEP 261, and JEP 282 Reviewed-by: alanb, mchung, naoto, rriggs, psandoz, plevart, mullan, ascarpino, vinnie, prr, sherman, dfuchs, mhaupt Contributed-by: alan.bateman@oracle.com, alex.buckley@oracle.com, jonathan.gibbons@oracle.com, karen.kinnear@oracle.com, mandy.chung@oracle.com, mark.reinhold@oracle.com, chris.hegarty@oracle.com, alexandr.scherbatiy@oracle.com, amy.lu@oracle.com, calvin.cheung@oracle.com, daniel.fuchs@oracle.com, erik.joelsson@oracle.com, harold.seigel@oracle.com, jaroslav.bachorik@oracle.com, jean-francois.denise@oracle.com, jan.lahoda@oracle.com, james.laskey@oracle.com, lois.foltan@oracle.com, miroslav.kos@oracle.com, huaming.li@oracle.com, sean.mullan@oracle.com, naoto.sato@oracle.com, masayoshi.okutsu@oracle.com, peter.levart@gmail.com, philip.race@oracle.com, claes.redestad@oracle.com, sergey.bylokhov@oracle.com, alexandre.iline@oracle.com, volker.simonis@gmail.com, staffan.larsen@oracle.com, stuart.marks@oracle.com, semyon.sadetsky@oracle.com, serguei.spitsyn@oracle.com, sundararajan.athijegannathan@oracle.com, valerie.peng@oracle.com, vincent.x.ryan@oracle.com, weijun.wang@oracle.com, yuri.nesterenko@oracle.com, yekaterina.kantserova@oracle.com, alexander.kulyakhtin@oracle.com, felix.yang@oracle.com, andrei.eremeev@oracle.com, frank.yuan@oracle.com, sergei.pikalev@oracle.com, sibabrata.sahoo@oracle.com, tiantian.du@oracle.com, sha.jiang@oracle.com
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
36014
3d50784f2dc2 8148346: Reduce number of packages in jdk.localedata module
naoto
parents: 35241
diff changeset
     1
27565
729f9700483a 8049367: Modular Run-Time Images
chegar
parents: 25859
diff changeset
     2
# Copyright (c) 2011, 2014, Oracle and/or its affiliates. All rights reserved.
12317
9670c1610c53 7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff changeset
     3
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
9670c1610c53 7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff changeset
     4
#
9670c1610c53 7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff changeset
     5
# This code is free software; you can redistribute it and/or modify it
9670c1610c53 7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff changeset
     6
# under the terms of the GNU General Public License version 2 only, as
9670c1610c53 7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff changeset
     7
# published by the Free Software Foundation.  Oracle designates this
9670c1610c53 7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff changeset
     8
# particular file as subject to the "Classpath" exception as provided
9670c1610c53 7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff changeset
     9
# by Oracle in the LICENSE file that accompanied this code.
9670c1610c53 7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff changeset
    10
#
9670c1610c53 7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff changeset
    11
# This code is distributed in the hope that it will be useful, but WITHOUT
9670c1610c53 7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff changeset
    12
# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
9670c1610c53 7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff changeset
    13
# FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
9670c1610c53 7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff changeset
    14
# version 2 for more details (a copy is included in the LICENSE file that
9670c1610c53 7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff changeset
    15
# accompanied this code).
9670c1610c53 7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff changeset
    16
#
9670c1610c53 7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff changeset
    17
# You should have received a copy of the GNU General Public License version
9670c1610c53 7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff changeset
    18
# 2 along with this work; if not, write to the Free Software Foundation,
9670c1610c53 7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff changeset
    19
# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
9670c1610c53 7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff changeset
    20
#
9670c1610c53 7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff changeset
    21
# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
9670c1610c53 7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff changeset
    22
# or visit www.oracle.com if you need additional information or have any
9670c1610c53 7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff changeset
    23
# questions.
9670c1610c53 7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff changeset
    24
#
9670c1610c53 7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff changeset
    25
9670c1610c53 7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff changeset
    26
#
9670c1610c53 7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff changeset
    27
# Make file for generating BreakIterator data files.
9670c1610c53 7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff changeset
    28
#
9670c1610c53 7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff changeset
    29
9670c1610c53 7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff changeset
    30
# input
9670c1610c53 7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff changeset
    31
#
20547
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 14343
diff changeset
    32
# Notes: sun.text.resources.BreakIteratorRules no longer goes to runtime.
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 14343
diff changeset
    33
# They are used at JDK build phase in order to create $(BIFILES) which
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 14343
diff changeset
    34
# are used on runtime instead.
12317
9670c1610c53 7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff changeset
    35
#
27565
729f9700483a 8049367: Modular Run-Time Images
chegar
parents: 25859
diff changeset
    36
TEXT_PKG := sun/text/resources
36014
3d50784f2dc2 8148346: Reduce number of packages in jdk.localedata module
naoto
parents: 35241
diff changeset
    37
TEXT_PKG_LD := $(TEXT_PKG)/ext
27565
729f9700483a 8049367: Modular Run-Time Images
chegar
parents: 25859
diff changeset
    38
TEXT_SOURCES := $(TEXT_PKG)/BreakIteratorRules.java \
20547
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 14343
diff changeset
    39
    $(TEXT_PKG)/BreakIteratorInfo.java \
36014
3d50784f2dc2 8148346: Reduce number of packages in jdk.localedata module
naoto
parents: 35241
diff changeset
    40
    $(TEXT_PKG_LD)/BreakIteratorRules_th.java \
3d50784f2dc2 8148346: Reduce number of packages in jdk.localedata module
naoto
parents: 35241
diff changeset
    41
    $(TEXT_PKG_LD)/BreakIteratorInfo_th.java
12317
9670c1610c53 7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff changeset
    42
9670c1610c53 7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff changeset
    43
# Generate BreakIteratorData
27565
729f9700483a 8049367: Modular Run-Time Images
chegar
parents: 25859
diff changeset
    44
BREAK_ITERATOR_CLASSES := $(BUILDTOOLS_OUTPUTDIR)/break_iterator_classes
12317
9670c1610c53 7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff changeset
    45
27945
dd8be94d105f 8066761: Investigate -sourcepath usage when compiling java
erikj
parents: 27565
diff changeset
    46
# These two files should be moved out to a build tool!
36511
9d0388c6b336 8142968: Module System implementation
alanb
parents: 36014
diff changeset
    47
$(eval $(call SetupJavaCompilation,BUILD_BREAKITERATOR_BASE, \
9d0388c6b336 8142968: Module System implementation
alanb
parents: 36014
diff changeset
    48
    SETUP := GENERATE_OLDBYTECODE, \
9d0388c6b336 8142968: Module System implementation
alanb
parents: 36014
diff changeset
    49
    SRC := $(JDK_TOPDIR)/src/java.base/share/classes, \
9d0388c6b336 8142968: Module System implementation
alanb
parents: 36014
diff changeset
    50
    INCLUDE_FILES := \
9d0388c6b336 8142968: Module System implementation
alanb
parents: 36014
diff changeset
    51
        $(TEXT_PKG)/BreakIteratorRules.java \
9d0388c6b336 8142968: Module System implementation
alanb
parents: 36014
diff changeset
    52
        $(TEXT_PKG)/BreakIteratorInfo.java, \
9d0388c6b336 8142968: Module System implementation
alanb
parents: 36014
diff changeset
    53
    BIN := $(BREAK_ITERATOR_CLASSES)/java.base))
9d0388c6b336 8142968: Module System implementation
alanb
parents: 36014
diff changeset
    54
9d0388c6b336 8142968: Module System implementation
alanb
parents: 36014
diff changeset
    55
$(eval $(call SetupJavaCompilation,BUILD_BREAKITERATOR_LD, \
20547
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 14343
diff changeset
    56
    SETUP := GENERATE_OLDBYTECODE, \
36511
9d0388c6b336 8142968: Module System implementation
alanb
parents: 36014
diff changeset
    57
    SRC := $(JDK_TOPDIR)/src/jdk.localedata/share/classes, \
9d0388c6b336 8142968: Module System implementation
alanb
parents: 36014
diff changeset
    58
    INCLUDES := $(TEXT_PKG_LD), \
9d0388c6b336 8142968: Module System implementation
alanb
parents: 36014
diff changeset
    59
    INCLUDE_FILES := \
9d0388c6b336 8142968: Module System implementation
alanb
parents: 36014
diff changeset
    60
        $(TEXT_PKG_LD)/BreakIteratorRules_th.java \
9d0388c6b336 8142968: Module System implementation
alanb
parents: 36014
diff changeset
    61
        $(TEXT_PKG_LD)/BreakIteratorInfo_th.java, \
9d0388c6b336 8142968: Module System implementation
alanb
parents: 36014
diff changeset
    62
    BIN := $(BREAK_ITERATOR_CLASSES)/jdk.localedata))
9d0388c6b336 8142968: Module System implementation
alanb
parents: 36014
diff changeset
    63
9d0388c6b336 8142968: Module System implementation
alanb
parents: 36014
diff changeset
    64
ifeq ($(BOOT_JDK_MODULAR), true)
9d0388c6b336 8142968: Module System implementation
alanb
parents: 36014
diff changeset
    65
  BREAK_ITERATOR_BOOTCLASSPATH := -Xpatch:$(BREAK_ITERATOR_CLASSES) \
9d0388c6b336 8142968: Module System implementation
alanb
parents: 36014
diff changeset
    66
      -XaddExports:$(subst $(SPACE),$(COMMA),$(strip \
9d0388c6b336 8142968: Module System implementation
alanb
parents: 36014
diff changeset
    67
          java.base/sun.text=ALL-UNNAMED \
9d0388c6b336 8142968: Module System implementation
alanb
parents: 36014
diff changeset
    68
          java.base/sun.text.resources=ALL-UNNAMED \
9d0388c6b336 8142968: Module System implementation
alanb
parents: 36014
diff changeset
    69
          jdk.localedata/sun.text.resources.ext=ALL-UNNAMED \
9d0388c6b336 8142968: Module System implementation
alanb
parents: 36014
diff changeset
    70
      ))
9d0388c6b336 8142968: Module System implementation
alanb
parents: 36014
diff changeset
    71
else
9d0388c6b336 8142968: Module System implementation
alanb
parents: 36014
diff changeset
    72
  BREAK_ITERATOR_BOOTCLASSPATH := -Xbootclasspath/p:$(call PathList, \
9d0388c6b336 8142968: Module System implementation
alanb
parents: 36014
diff changeset
    73
      $(BREAK_ITERATOR_CLASSES)/java.base \
9d0388c6b336 8142968: Module System implementation
alanb
parents: 36014
diff changeset
    74
      $(BREAK_ITERATOR_CLASSES)/jdk.localedata)
9d0388c6b336 8142968: Module System implementation
alanb
parents: 36014
diff changeset
    75
endif
12317
9670c1610c53 7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff changeset
    76
9670c1610c53 7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff changeset
    77
# Generate data resource files.
9670c1610c53 7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff changeset
    78
# input
27565
729f9700483a 8049367: Modular Run-Time Images
chegar
parents: 25859
diff changeset
    79
UNICODEDATA := $(JDK_TOPDIR)/make/data/unicodedata/UnicodeData.txt
12317
9670c1610c53 7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff changeset
    80
9670c1610c53 7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff changeset
    81
# output
27565
729f9700483a 8049367: Modular Run-Time Images
chegar
parents: 25859
diff changeset
    82
BASE_DATA_PKG_DIR := $(JDK_OUTPUTDIR)/modules/java.base/sun/text/resources
34330
4d5aa33be0a0 8143141: Bring in minor build changes from the jigsaw/jake forest
erikj
parents: 27945
diff changeset
    83
LD_DATA_PKG_DIR := $(JDK_OUTPUTDIR)/modules/jdk.localedata/sun/text/resources
27565
729f9700483a 8049367: Modular Run-Time Images
chegar
parents: 25859
diff changeset
    84
BIFILES := $(BASE_DATA_PKG_DIR)/CharacterBreakIteratorData \
25859
3317bb8137f4 8054834: Modular Source Code
chegar
parents: 21805
diff changeset
    85
    $(BASE_DATA_PKG_DIR)/WordBreakIteratorData \
3317bb8137f4 8054834: Modular Source Code
chegar
parents: 21805
diff changeset
    86
    $(BASE_DATA_PKG_DIR)/LineBreakIteratorData \
3317bb8137f4 8054834: Modular Source Code
chegar
parents: 21805
diff changeset
    87
    $(BASE_DATA_PKG_DIR)/SentenceBreakIteratorData
36014
3d50784f2dc2 8148346: Reduce number of packages in jdk.localedata module
naoto
parents: 35241
diff changeset
    88
BIFILES_TH := $(LD_DATA_PKG_DIR)/WordBreakIteratorData_th \
3d50784f2dc2 8148346: Reduce number of packages in jdk.localedata module
naoto
parents: 35241
diff changeset
    89
    $(LD_DATA_PKG_DIR)/LineBreakIteratorData_th
12317
9670c1610c53 7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff changeset
    90
25859
3317bb8137f4 8054834: Modular Source Code
chegar
parents: 21805
diff changeset
    91
$(BIFILES): $(BASE_DATA_PKG_DIR)/_the.bifiles
36511
9d0388c6b336 8142968: Module System implementation
alanb
parents: 36014
diff changeset
    92
$(BASE_DATA_PKG_DIR)/_the.bifiles: JAVA_FLAGS += $(BREAK_ITERATOR_BOOTCLASSPATH)
9d0388c6b336 8142968: Module System implementation
alanb
parents: 36014
diff changeset
    93
$(BASE_DATA_PKG_DIR)/_the.bifiles: $(BUILD_TOOLS) $(UNICODEDATA) \
9d0388c6b336 8142968: Module System implementation
alanb
parents: 36014
diff changeset
    94
    $(BUILD_BREAKITERATOR_BASE) $(BUILD_BREAKITERATOR_LD)
35241
075bbb8f2423 8146403: Windows build can be faster
erikj
parents: 34932
diff changeset
    95
	$(call LogInfo, Generating BreakIteratorData)
075bbb8f2423 8146403: Windows build can be faster
erikj
parents: 34932
diff changeset
    96
	$(call MakeDir, $(@D))
13702
efd6a05935b2 7197849: Update new build-infra makefiles
ohair
parents: 13583
diff changeset
    97
	$(RM) $(BIFILES)
12317
9670c1610c53 7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff changeset
    98
	$(TOOL_GENERATEBREAKITERATORDATA) \
25859
3317bb8137f4 8054834: Modular Source Code
chegar
parents: 21805
diff changeset
    99
	    -o $(@D) \
20547
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 14343
diff changeset
   100
	    -spec $(UNICODEDATA)
12892
3ef14bab6254 7170079: Adjustments to build-infra makefiles
erikj
parents: 12317
diff changeset
   101
	$(TOUCH) $@
12317
9670c1610c53 7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff changeset
   102
34330
4d5aa33be0a0 8143141: Bring in minor build changes from the jigsaw/jake forest
erikj
parents: 27945
diff changeset
   103
$(BIFILES_TH): $(LD_DATA_PKG_DIR)/_the.bifiles_th
36511
9d0388c6b336 8142968: Module System implementation
alanb
parents: 36014
diff changeset
   104
$(LD_DATA_PKG_DIR)/_the.bifiles_th: JAVA_FLAGS += $(BREAK_ITERATOR_BOOTCLASSPATH)
9d0388c6b336 8142968: Module System implementation
alanb
parents: 36014
diff changeset
   105
$(LD_DATA_PKG_DIR)/_the.bifiles_th: $(BUILD_TOOLS) $(UNICODEDATA) \
9d0388c6b336 8142968: Module System implementation
alanb
parents: 36014
diff changeset
   106
    $(BUILD_BREAKITERATOR_BASE) $(BUILD_BREAKITERATOR_LD)
35241
075bbb8f2423 8146403: Windows build can be faster
erikj
parents: 34932
diff changeset
   107
	$(call LogInfo, Generating BreakIteratorData_th)
13702
efd6a05935b2 7197849: Update new build-infra makefiles
ohair
parents: 13583
diff changeset
   108
	$(RM) $(BIFILES_TH)
12317
9670c1610c53 7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff changeset
   109
	$(TOOL_GENERATEBREAKITERATORDATA) \
25859
3317bb8137f4 8054834: Modular Source Code
chegar
parents: 21805
diff changeset
   110
	    -o $(@D) \
20547
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 14343
diff changeset
   111
	    -spec $(UNICODEDATA) \
453837141fac 8001931: The new build system whitespace cleanup
ihse
parents: 14343
diff changeset
   112
	    -language th
12892
3ef14bab6254 7170079: Adjustments to build-infra makefiles
erikj
parents: 12317
diff changeset
   113
	$(TOUCH) $@
12317
9670c1610c53 7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff changeset
   114
27565
729f9700483a 8049367: Modular Run-Time Images
chegar
parents: 25859
diff changeset
   115
TARGETS += $(BIFILES) $(BIFILES_TH)