make/ExplodedImageOptimize.gmk
author herrick
Thu, 28 Mar 2019 13:49:38 -0400
branchJDK-8200758-branch
changeset 57292 7a683c461b80
parent 53995 ecc2bcc3beb0
child 55292 f4b2d5b83ebf
permissions -rw-r--r--
Merge
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
41171
407480ec6872 8166948: Exploded image too slow to be usable
erikj
parents:
diff changeset
     1
#
53241
7327a62f3c04 8216489: Issues with ModulePackages attribute generation on incremental build
erikj
parents: 51808
diff changeset
     2
# Copyright (c) 2016, 2019, Oracle and/or its affiliates. All rights reserved.
41171
407480ec6872 8166948: Exploded image too slow to be usable
erikj
parents:
diff changeset
     3
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
407480ec6872 8166948: Exploded image too slow to be usable
erikj
parents:
diff changeset
     4
#
407480ec6872 8166948: Exploded image too slow to be usable
erikj
parents:
diff changeset
     5
# This code is free software; you can redistribute it and/or modify it
407480ec6872 8166948: Exploded image too slow to be usable
erikj
parents:
diff changeset
     6
# under the terms of the GNU General Public License version 2 only, as
407480ec6872 8166948: Exploded image too slow to be usable
erikj
parents:
diff changeset
     7
# published by the Free Software Foundation.  Oracle designates this
407480ec6872 8166948: Exploded image too slow to be usable
erikj
parents:
diff changeset
     8
# particular file as subject to the "Classpath" exception as provided
407480ec6872 8166948: Exploded image too slow to be usable
erikj
parents:
diff changeset
     9
# by Oracle in the LICENSE file that accompanied this code.
407480ec6872 8166948: Exploded image too slow to be usable
erikj
parents:
diff changeset
    10
#
407480ec6872 8166948: Exploded image too slow to be usable
erikj
parents:
diff changeset
    11
# This code is distributed in the hope that it will be useful, but WITHOUT
407480ec6872 8166948: Exploded image too slow to be usable
erikj
parents:
diff changeset
    12
# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
407480ec6872 8166948: Exploded image too slow to be usable
erikj
parents:
diff changeset
    13
# FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
407480ec6872 8166948: Exploded image too slow to be usable
erikj
parents:
diff changeset
    14
# version 2 for more details (a copy is included in the LICENSE file that
407480ec6872 8166948: Exploded image too slow to be usable
erikj
parents:
diff changeset
    15
# accompanied this code).
407480ec6872 8166948: Exploded image too slow to be usable
erikj
parents:
diff changeset
    16
#
407480ec6872 8166948: Exploded image too slow to be usable
erikj
parents:
diff changeset
    17
# You should have received a copy of the GNU General Public License version
407480ec6872 8166948: Exploded image too slow to be usable
erikj
parents:
diff changeset
    18
# 2 along with this work; if not, write to the Free Software Foundation,
407480ec6872 8166948: Exploded image too slow to be usable
erikj
parents:
diff changeset
    19
# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
407480ec6872 8166948: Exploded image too slow to be usable
erikj
parents:
diff changeset
    20
#
407480ec6872 8166948: Exploded image too slow to be usable
erikj
parents:
diff changeset
    21
# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
407480ec6872 8166948: Exploded image too slow to be usable
erikj
parents:
diff changeset
    22
# or visit www.oracle.com if you need additional information or have any
407480ec6872 8166948: Exploded image too slow to be usable
erikj
parents:
diff changeset
    23
# questions.
407480ec6872 8166948: Exploded image too slow to be usable
erikj
parents:
diff changeset
    24
#
407480ec6872 8166948: Exploded image too slow to be usable
erikj
parents:
diff changeset
    25
407480ec6872 8166948: Exploded image too slow to be usable
erikj
parents:
diff changeset
    26
# Runs a tool on the exploded image to improve performance
407480ec6872 8166948: Exploded image too slow to be usable
erikj
parents:
diff changeset
    27
407480ec6872 8166948: Exploded image too slow to be usable
erikj
parents:
diff changeset
    28
default: all
407480ec6872 8166948: Exploded image too slow to be usable
erikj
parents:
diff changeset
    29
407480ec6872 8166948: Exploded image too slow to be usable
erikj
parents:
diff changeset
    30
include $(SPEC)
407480ec6872 8166948: Exploded image too slow to be usable
erikj
parents:
diff changeset
    31
include MakeBase.gmk
53995
ecc2bcc3beb0 8219971: Introduce SetupExecute in build system
ihse
parents: 53241
diff changeset
    32
include Execute.gmk
47217
72e3ae9a25eb 8187444: Forest Consolidation: Make build work
erikj
parents: 41659
diff changeset
    33
include $(TOPDIR)/make/ModuleTools.gmk
41171
407480ec6872 8166948: Exploded image too slow to be usable
erikj
parents:
diff changeset
    34
407480ec6872 8166948: Exploded image too slow to be usable
erikj
parents:
diff changeset
    35
################################################################################
407480ec6872 8166948: Exploded image too slow to be usable
erikj
parents:
diff changeset
    36
53241
7327a62f3c04 8216489: Issues with ModulePackages attribute generation on incremental build
erikj
parents: 51808
diff changeset
    37
ALL_MODULEINFO_CLASSES := $(wildcard $(JDK_OUTPUTDIR)/modules/*/module-info.class)
41171
407480ec6872 8166948: Exploded image too slow to be usable
erikj
parents:
diff changeset
    38
53995
ecc2bcc3beb0 8219971: Introduce SetupExecute in build system
ihse
parents: 53241
diff changeset
    39
$(eval $(call SetupExecute, optimize_image, \
ecc2bcc3beb0 8219971: Introduce SetupExecute in build system
ihse
parents: 53241
diff changeset
    40
    INFO := Optimizing the exploded image, \
ecc2bcc3beb0 8219971: Introduce SetupExecute in build system
ihse
parents: 53241
diff changeset
    41
    DEPS := $(ALL_MODULEINFO_CLASSES) $(BUILD_JIGSAW_CLASSES), \
ecc2bcc3beb0 8219971: Introduce SetupExecute in build system
ihse
parents: 53241
diff changeset
    42
    OUTPUT_DIR := $(JDK_OUTPUTDIR), \
ecc2bcc3beb0 8219971: Introduce SetupExecute in build system
ihse
parents: 53241
diff changeset
    43
    COMMAND := $(TOOL_ADD_PACKAGES_ATTRIBUTE) $(JDK_OUTPUTDIR), \
ecc2bcc3beb0 8219971: Introduce SetupExecute in build system
ihse
parents: 53241
diff changeset
    44
))
41171
407480ec6872 8166948: Exploded image too slow to be usable
erikj
parents:
diff changeset
    45
53995
ecc2bcc3beb0 8219971: Introduce SetupExecute in build system
ihse
parents: 53241
diff changeset
    46
TARGETS := $(optimize_image_TARGET)
41171
407480ec6872 8166948: Exploded image too slow to be usable
erikj
parents:
diff changeset
    47
407480ec6872 8166948: Exploded image too slow to be usable
erikj
parents:
diff changeset
    48
################################################################################
407480ec6872 8166948: Exploded image too slow to be usable
erikj
parents:
diff changeset
    49
407480ec6872 8166948: Exploded image too slow to be usable
erikj
parents:
diff changeset
    50
all: $(TARGETS)
407480ec6872 8166948: Exploded image too slow to be usable
erikj
parents:
diff changeset
    51
407480ec6872 8166948: Exploded image too slow to be usable
erikj
parents:
diff changeset
    52
.PHONY: all default