8146403: Windows build can be faster

Reviewed-by: ihse
This commit is contained in:
Erik Joelsson 2016-01-16 13:01:43 +01:00
parent 07b44796c2
commit 8c55662304
17 changed files with 178 additions and 132 deletions

View File

@ -4839,7 +4839,7 @@ VS_SDK_PLATFORM_NAME_2013=
#CUSTOM_AUTOCONF_INCLUDE #CUSTOM_AUTOCONF_INCLUDE
# Do not change or remove the following line, it is needed for consistency checks: # Do not change or remove the following line, it is needed for consistency checks:
DATE_WHEN_GENERATED=1452780299 DATE_WHEN_GENERATED=1452935762
############################################################################### ###############################################################################
# #

View File

@ -41,7 +41,7 @@ MODULES_SYMBOLS_FILES := $(foreach module, $(EXPORTED_SYMBOLS_MODULES), \
$(SUPPORT_OUTPUTDIR)/modules_libs/$(module)/$(module).symbols) $(SUPPORT_OUTPUTDIR)/modules_libs/$(module)/$(module).symbols)
$(GLOBAL_SYMBOLS_FILE): $(MODULES_SYMBOLS_FILES) $(GLOBAL_SYMBOLS_FILE): $(MODULES_SYMBOLS_FILES)
$(ECHO) $(LOG_INFO) "Generating global exported.symbols file" $(call LogInfo, Generating global exported.symbols file)
$(MKDIR) -p $(@D) $(MKDIR) -p $(@D)
$(CAT) $^ > $@ $(CAT) $^ > $@

View File

@ -0,0 +1,64 @@
#
# Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved.
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
#
# This code is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License version 2 only, as
# published by the Free Software Foundation. Oracle designates this
# particular file as subject to the "Classpath" exception as provided
# by Oracle in the LICENSE file that accompanied this code.
#
# This code is distributed in the hope that it will be useful, but WITHOUT
# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
# version 2 for more details (a copy is included in the LICENSE file that
# accompanied this code).
#
# You should have received a copy of the GNU General Public License version
# 2 along with this work; if not, write to the Free Software Foundation,
# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
#
# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
# or visit www.oracle.com if you need additional information or have any
# questions.
#
# This file is included from Main.gmk only.
include $(SRC_ROOT)/make/common/JavaCompilation.gmk
include $(SRC_ROOT)/make/common/SetupJavaCompilers.gmk
################################################################################
$(eval $(call SetupJavaCompilation, BUILD_GENMODULESLIST, \
SETUP := BOOT_JAVAC, \
SRC := $(JDK_TOPDIR)/make/src/classes, \
INCLUDES := build/tools/module, \
EXCLUDE_FILES := ImageBuilder.java ModuleArchive.java, \
BIN := $(MAKESUPPORT_OUTPUTDIR)/bt_classes_moduleslist, \
DISABLE_SJAVAC := true, \
))
TOOL_GENMODULESLIST = $(JAVA_SMALL) \
-cp "$(MAKESUPPORT_OUTPUTDIR)/bt_classes_moduleslist" \
build.tools.module.GenModulesList
MODULES_LIST_FILE := $(MAKESUPPORT_OUTPUTDIR)/modules.list
# The module deps makefile is used from make/common/Modules.gmk
MODULE_DEPS_MAKEFILE := $(MAKESUPPORT_OUTPUTDIR)/module-deps.gmk
$(MODULES_LIST_FILE): $(SRC_ROOT)/modules.xml $(BUILD_GENMODULESLIST)
$(TOOL_GENMODULESLIST) -o $@ $(filter %.xml, $^)
$(MODULE_DEPS_MAKEFILE): $(MODULES_LIST_FILE)
$(CAT) $^ | $(SED) -e 's/^\([^:]*\):/DEPS_\1 :=/g' > $@
TARGETS += $(MODULE_DEPS_MAKEFILE)
################################################################################
# Hook to include the corresponding custom file, if present.
$(eval $(call IncludeCustomExtension, , GenerateModuleDeps.gmk))
# Trigger generation of this file and restart make if it changed.
-include $(MODULE_DEPS_MAKEFILE)

View File

@ -35,14 +35,18 @@ include MakeBase.gmk
default: all default: all
# Get all files except .hg in the hotspot directory. # Get all files in src, make or agent subdirs in hotspot directory and
HOTSPOT_FILES := $(shell $(FIND) -L $(HOTSPOT_TOPDIR) -name ".hg" -prune -o -print) # filter out .hg. This skips the test directory.
HOTSPOT_FILES := $(shell $(FIND) -L \
$(HOTSPOT_TOPDIR)/src $(HOTSPOT_TOPDIR)/make $(HOTSPOT_TOPDIR)/agent \
-name ".hg" -prune -o -print)
# The old build creates hotspot output dir before calling hotspot and # The old build creates hotspot output dir before calling hotspot and
# not doing it breaks builds on msys. # not doing it breaks builds on msys.
$(HOTSPOT_OUTPUTDIR)/_hotspot.timestamp: $(HOTSPOT_FILES) $(HOTSPOT_OUTPUTDIR)/_hotspot.timestamp: $(HOTSPOT_FILES)
@$(MKDIR) -p $(HOTSPOT_OUTPUTDIR) @$(MKDIR) -p $(HOTSPOT_OUTPUTDIR)
@($(CD) $(HOTSPOT_TOPDIR)/make && $(MAKE) $(HOTSPOT_MAKE_ARGS) LOG_LEVEL=$(LOG_LEVEL) SPEC=$(HOTSPOT_SPEC) BASE_SPEC=$(BASE_SPEC)) @($(CD) $(HOTSPOT_TOPDIR)/make && $(MAKE) $(HOTSPOT_MAKE_ARGS) \
LOG_LEVEL=$(LOG_LEVEL) SPEC=$(HOTSPOT_SPEC) BASE_SPEC=$(BASE_SPEC))
$(TOUCH) $@ $(TOUCH) $@
hotspot: $(HOTSPOT_OUTPUTDIR)/_hotspot.timestamp hotspot: $(HOTSPOT_OUTPUTDIR)/_hotspot.timestamp

View File

@ -248,38 +248,38 @@ ifneq ($(OPENJDK_TARGET_OS), windows)
endif endif
$(JRE_IMAGE_DIR)/man/man1/%: $(MAN_SRC_DIR)/$(MAN1_SUBDIR)/% $(JRE_IMAGE_DIR)/man/man1/%: $(MAN_SRC_DIR)/$(MAN1_SUBDIR)/%
$(ECHO) $(LOG_INFO) Copying $(patsubst $(OUTPUT_ROOT)/%,%,$@) $(call LogInfo, Copying $(patsubst $(OUTPUT_ROOT)/%,%,$@))
$(install-file) $(install-file)
$(JDK_IMAGE_DIR)/man/man1/%: $(MAN_SRC_DIR)/$(MAN1_SUBDIR)/% $(JDK_IMAGE_DIR)/man/man1/%: $(MAN_SRC_DIR)/$(MAN1_SUBDIR)/%
$(ECHO) $(LOG_INFO) Copying $(patsubst $(OUTPUT_ROOT)/%,%,$@) $(call LogInfo, Copying $(patsubst $(OUTPUT_ROOT)/%,%,$@))
$(install-file) $(install-file)
$(JRE_IMAGE_DIR)/man/ja_JP.UTF-8/man1/%: $(MAN_SRC_DIR)/$(MAN1_SUBDIR)/ja/% $(JRE_IMAGE_DIR)/man/ja_JP.UTF-8/man1/%: $(MAN_SRC_DIR)/$(MAN1_SUBDIR)/ja/%
$(ECHO) $(LOG_INFO) Copying $(patsubst $(OUTPUT_ROOT)/%,%,$@) $(call LogInfo, Copying $(patsubst $(OUTPUT_ROOT)/%,%,$@))
$(install-file) $(install-file)
$(JDK_IMAGE_DIR)/man/ja_JP.UTF-8/man1/%: $(MAN_SRC_DIR)/$(MAN1_SUBDIR)/ja/% $(JDK_IMAGE_DIR)/man/ja_JP.UTF-8/man1/%: $(MAN_SRC_DIR)/$(MAN1_SUBDIR)/ja/%
$(ECHO) $(LOG_INFO) Copying $(patsubst $(OUTPUT_ROOT)/%,%,$@) $(call LogInfo, Copying $(patsubst $(OUTPUT_ROOT)/%,%,$@))
$(install-file) $(install-file)
ifeq ($(OPENJDK_TARGET_OS), solaris) ifeq ($(OPENJDK_TARGET_OS), solaris)
$(JRE_IMAGE_DIR)/man/ja/man1/%: $(MAN_SRC_DIR)/$(MAN1_SUBDIR)/ja/% $(JRE_IMAGE_DIR)/man/ja/man1/%: $(MAN_SRC_DIR)/$(MAN1_SUBDIR)/ja/%
$(ECHO) $(LOG_INFO) Converting $(patsubst $(OUTPUT_ROOT)/%,%,$@) $(call LogInfo, Converting $(patsubst $(OUTPUT_ROOT)/%,%,$@))
$(install-file) $(install-file)
$(JDK_IMAGE_DIR)/man/ja/man1/%: $(MAN_SRC_DIR)/$(MAN1_SUBDIR)/ja/% $(JDK_IMAGE_DIR)/man/ja/man1/%: $(MAN_SRC_DIR)/$(MAN1_SUBDIR)/ja/%
$(ECHO) $(LOG_INFO) Converting $(patsubst $(OUTPUT_ROOT)/%,%,$@) $(call LogInfo, Converting $(patsubst $(OUTPUT_ROOT)/%,%,$@))
$(install-file) $(install-file)
endif endif
ifneq ($(findstring $(OPENJDK_TARGET_OS), linux macosx), ) ifneq ($(findstring $(OPENJDK_TARGET_OS), linux macosx), )
$(JRE_IMAGE_DIR)/man/ja: $(JRE_IMAGE_DIR)/man/ja:
$(ECHO) $(LOG_INFO) Creating $(patsubst $(OUTPUT_ROOT)/%,%,$@) $(call LogInfo, Creating $(patsubst $(OUTPUT_ROOT)/%,%,$@))
$(CD) $(@D) && $(RM) ja && $(LN) -s ja_JP.UTF-8 ja $(CD) $(@D) && $(RM) ja && $(LN) -s ja_JP.UTF-8 ja
$(JDK_IMAGE_DIR)/man/ja: $(JDK_IMAGE_DIR)/man/ja:
$(ECHO) $(LOG_INFO) Creating $(patsubst $(OUTPUT_ROOT)/%,%,$@) $(call LogInfo, Creating $(patsubst $(OUTPUT_ROOT)/%,%,$@))
$(CD) $(@D) && $(RM) ja && $(LN) -s ja_JP.UTF-8 ja $(CD) $(@D) && $(RM) ja && $(LN) -s ja_JP.UTF-8 ja
endif endif
@ -333,7 +333,7 @@ JDK_DOC_TARGETS := $(addprefix $(JDK_IMAGE_DIR)/, $(JDK_DOC_FILES))
# Processing license files from source area to image area # Processing license files from source area to image area
# These are modified to have the platform specific EOL chars. # These are modified to have the platform specific EOL chars.
define process-doc-file define process-doc-file
$(ECHO) $(LOG_INFO) Processing $(patsubst $(OUTPUT_ROOT)/%,%,$@) $(call LogInfo, Processing $(patsubst $(OUTPUT_ROOT)/%,%,$@))
$(MKDIR) -p $(@D) $(MKDIR) -p $(@D)
$(RM) $@ $(RM) $@
LC_ALL=C $(SED) 's/$$//g' $< > $@ LC_ALL=C $(SED) 's/$$//g' $< > $@
@ -378,7 +378,7 @@ endef
# Param 1 - The file containing the MODULES list # Param 1 - The file containing the MODULES list
define prepare-info-file define prepare-info-file
$(ECHO) $(LOG_INFO) Generating $(patsubst $(OUTPUT_ROOT)/%,%,$@) $(call LogInfo, Generating $(patsubst $(OUTPUT_ROOT)/%,%,$@))
$(MKDIR) -p $(@D) $(MKDIR) -p $(@D)
$(RM) $@ $(RM) $@
endef endef
@ -426,38 +426,30 @@ JRE_COMPACT3_TARGETS += $(JRE_COMPACT3_INFO_FILE)
# src.zip # src.zip
$(JDK_IMAGE_DIR)/src.zip: $(SUPPORT_OUTPUTDIR)/src.zip $(JDK_IMAGE_DIR)/src.zip: $(SUPPORT_OUTPUTDIR)/src.zip
$(ECHO) $(LOG_INFO) Copying $(patsubst $(OUTPUT_ROOT)/%,%,$@) $(call LogInfo, Copying $(patsubst $(OUTPUT_ROOT)/%,%,$@))
$(install-file) $(install-file)
JDK_TARGETS += $(JDK_IMAGE_DIR)/src.zip JDK_TARGETS += $(JDK_IMAGE_DIR)/src.zip
################################################################################ ################################################################################
# /demo dir # /demo dir
# The db demo contains an empty dir that needs to be copied. The other
# directories will always trigger the rule for recompile since
# _the.list_of_packages files are touched.
ifneq ($(findstring images, $(MAKECMDGOALS)), ) ifneq ($(findstring images, $(MAKECMDGOALS)), )
$(JDK_IMAGE_DIR)/demo/%: $(SUPPORT_OUTPUTDIR)/demos/image/% $(eval $(call SetupCopyFiles, JDK_COPY_DEMOS, \
if [ ! -d "$@" ]; then \ SRC := $(SUPPORT_OUTPUTDIR)/demos/image, \
$(ECHO) $(LOG_INFO) Copying '$(patsubst $(OUTPUT_ROOT)/%,%,$@)'; \ DEST := $(JDK_IMAGE_DIR)/demo, \
$(MKDIR) -p $(@D); \ FILES := $(if $(wildcard $(SUPPORT_OUTPUTDIR)/demos/image), \
if [ -d "$<" ]; then $(MKDIR) -p $@; else $(CP) '$<' '$@'; fi \ $(call DoubleDollar, $(call DoubleDollar, \
fi
# Find all files including directories
JDK_DEMO_TARGETS := $(if $(wildcard $(SUPPORT_OUTPUTDIR)/demos/image), \
$(patsubst $(SUPPORT_OUTPUTDIR)/demos/image/%, $(JDK_IMAGE_DIR)/demo/%, \
$(shell $(FIND) $(SUPPORT_OUTPUTDIR)/demos/image \ $(shell $(FIND) $(SUPPORT_OUTPUTDIR)/demos/image \
! \( -name "_the*" -o -name "javac_state" \) ))) -type f -a ! \( -name "_the*" -o -name "javac_state" \) )))), \
))
JDK_TARGETS += $(JDK_DEMO_TARGETS) JDK_TARGETS += $(JDK_COPY_DEMOS)
endif endif
################################################################################ ################################################################################
# /sample dir # /sample dir
$(eval $(call SetupCopyFiles,COPY_SAMPLES, \ $(eval $(call SetupCopyFiles, COPY_SAMPLES, \
SRC := $(SUPPORT_OUTPUTDIR)/sample/image, \ SRC := $(SUPPORT_OUTPUTDIR)/sample/image, \
DEST := $(JDK_IMAGE_DIR)/sample, \ DEST := $(JDK_IMAGE_DIR)/sample, \
FILES := $(if $(wildcard $(SUPPORT_OUTPUTDIR)/sample/image), \ FILES := $(if $(wildcard $(SUPPORT_OUTPUTDIR)/sample/image), \

View File

@ -226,8 +226,8 @@ else # HAS_SPEC=true
$(eval $(call ParseCompareBuild)) $(eval $(call ParseCompareBuild))
ifeq ($(LOG_NOFILE), true) ifeq ($(LOG_NOFILE), true)
# Disable log wrapper if LOG=[level,]nofile was given # Disable build log if LOG=[level,]nofile was given
override BUILD_LOG_WRAPPER := override BUILD_LOG_PIPE :=
endif endif
ifeq ($(OUTPUT_SYNC_SUPPORTED), true) ifeq ($(OUTPUT_SYNC_SUPPORTED), true)
@ -277,10 +277,10 @@ else # HAS_SPEC=true
ifneq ($(SEQUENTIAL_TARGETS)$(PARALLEL_TARGETS), ) ifneq ($(SEQUENTIAL_TARGETS)$(PARALLEL_TARGETS), )
$(call RotateLogFiles) $(call RotateLogFiles)
$(call PrepareFailureLogs) $(call PrepareFailureLogs)
$(BUILD_LOG_WRAPPER) $(PRINTF) "Building $(TARGET_DESCRIPTION)\n" $(PRINTF) "Building $(TARGET_DESCRIPTION)\n" $(BUILD_LOG_PIPE)
ifneq ($(SEQUENTIAL_TARGETS), ) ifneq ($(SEQUENTIAL_TARGETS), )
# Don't touch build output dir since we might be cleaning. That # Don't touch build output dir since we might be cleaning. That
# means no log wrapper. # means no log pipe.
( cd $(TOPDIR) && \ ( cd $(TOPDIR) && \
$(MAKE) $(MAKE_ARGS) -j 1 -f make/Main.gmk $(USER_MAKE_VARS) \ $(MAKE) $(MAKE_ARGS) -j 1 -f make/Main.gmk $(USER_MAKE_VARS) \
$(SEQUENTIAL_TARGETS) ) $(SEQUENTIAL_TARGETS) )
@ -289,11 +289,12 @@ else # HAS_SPEC=true
$(call StartGlobalTimer) $(call StartGlobalTimer)
$(call PrepareSmartJavac) $(call PrepareSmartJavac)
( cd $(TOPDIR) && \ ( cd $(TOPDIR) && \
$(BUILD_LOG_WRAPPER) $(NICE) $(MAKE) $(MAKE_ARGS) $(OUTPUT_SYNC_FLAG) \ $(NICE) $(MAKE) $(MAKE_ARGS) $(OUTPUT_SYNC_FLAG) \
-j $(JOBS) -f make/Main.gmk $(USER_MAKE_VARS) \ -j $(JOBS) -f make/Main.gmk $(USER_MAKE_VARS) \
$(PARALLEL_TARGETS) $(COMPARE_BUILD_MAKE) || \ $(PARALLEL_TARGETS) $(COMPARE_BUILD_MAKE) $(BUILD_LOG_PIPE) || \
( exitcode=$$? && $(BUILD_LOG_WRAPPER) \ ( exitcode=$$? && \
$(PRINTF) "\nERROR: Build failed for $(TARGET_DESCRIPTION) (exit code $$exitcode) \n" && \ $(PRINTF) "\nERROR: Build failed for $(TARGET_DESCRIPTION) (exit code $$exitcode) \n" \
$(BUILD_LOG_PIPE) && \
cd $(TOPDIR) && $(MAKE) $(MAKE_ARGS) -j 1 -f make/Init.gmk \ cd $(TOPDIR) && $(MAKE) $(MAKE_ARGS) -j 1 -f make/Init.gmk \
HAS_SPEC=true on-failure ; \ HAS_SPEC=true on-failure ; \
exit $$exitcode ) ) exit $$exitcode ) )
@ -301,7 +302,7 @@ else # HAS_SPEC=true
$(call StopGlobalTimer) $(call StopGlobalTimer)
$(call ReportBuildTimes) $(call ReportBuildTimes)
endif endif
$(BUILD_LOG_WRAPPER) $(PRINTF) "Finished building $(TARGET_DESCRIPTION)\n" $(PRINTF) "Finished building $(TARGET_DESCRIPTION)\n" $(BUILD_LOG_PIPE)
endif endif
on-failure: on-failure:

View File

@ -155,7 +155,7 @@ ifeq ($(HAS_SPEC),)
else ifeq ($$(LOG_LEVEL), debug) else ifeq ($$(LOG_LEVEL), debug)
MAKE_LOG_FLAGS := MAKE_LOG_FLAGS :=
else ifeq ($$(LOG_LEVEL), trace) else ifeq ($$(LOG_LEVEL), trace)
MAKE_LOG_FLAGS := -d MAKE_LOG_FLAGS :=
else else
$$(info Error: LOG must be one of: warn, info, debug or trace.) $$(info Error: LOG must be one of: warn, info, debug or trace.)
$$(error Cannot continue) $$(error Cannot continue)
@ -235,6 +235,9 @@ ifeq ($(HAS_SPEC),)
$$(foreach var, $$(all_confs), $$(info * $$(var))) $$(foreach var, $$(all_confs), $$(info * $$(var)))
$$(error Cannot continue) $$(error Cannot continue)
else else
# Don't repeat this output on make restarts caused by including
# generated files.
ifeq ($$(MAKE_RESTARTS),)
ifeq ($$(words $$(matching_confs)), 1) ifeq ($$(words $$(matching_confs)), 1)
$$(info Building configuration '$$(matching_confs)' (matching CONF=$$(CONF))) $$(info Building configuration '$$(matching_confs)' (matching CONF=$$(CONF)))
else else
@ -242,6 +245,7 @@ ifeq ($(HAS_SPEC),)
$$(foreach var, $$(matching_confs), $$(info * $$(var))) $$(foreach var, $$(matching_confs), $$(info * $$(var)))
endif endif
endif endif
endif
# Create a SPEC definition. This will contain the path to one or more spec.gmk files. # Create a SPEC definition. This will contain the path to one or more spec.gmk files.
SPECS := $$(addsuffix /spec.gmk, $$(addprefix $$(build_dir)/, $$(matching_confs))) SPECS := $$(addsuffix /spec.gmk, $$(addprefix $$(build_dir)/, $$(matching_confs)))
@ -313,7 +317,7 @@ else # $(HAS_SPEC)=true
BUILD_LOG := $(OUTPUT_ROOT)/build.log BUILD_LOG := $(OUTPUT_ROOT)/build.log
BUILD_TRACE_LOG := $(OUTPUT_ROOT)/build-trace-time.log BUILD_TRACE_LOG := $(OUTPUT_ROOT)/build-trace-time.log
BUILD_LOG_WRAPPER := $(BASH) $(SRC_ROOT)/common/bin/logger.sh $(BUILD_LOG) BUILD_LOG_PIPE := > >($(TEE) -a $(BUILD_LOG)) 2> >($(TEE) -a $(BUILD_LOG) >&2)
# Sanity check the spec file, so it matches this source code # Sanity check the spec file, so it matches this source code
define CheckSpecSanity define CheckSpecSanity
@ -455,7 +459,7 @@ else # $(HAS_SPEC)=true
endef endef
define RotateLogFiles define RotateLogFiles
$(RM) $(BUILD_LOG).old 2> /dev/null $(RM) $(BUILD_LOG).old 2> /dev/null && \
$(MV) $(BUILD_LOG) $(BUILD_LOG).old 2> /dev/null || true $(MV) $(BUILD_LOG) $(BUILD_LOG).old 2> /dev/null || true
$(if $(findstring trace, $(LOG_LEVEL)), \ $(if $(findstring trace, $(LOG_LEVEL)), \
$(RM) $(BUILD_TRACE_LOG).old 2> /dev/null && \ $(RM) $(BUILD_TRACE_LOG).old 2> /dev/null && \
@ -464,7 +468,7 @@ else # $(HAS_SPEC)=true
endef endef
define PrepareFailureLogs define PrepareFailureLogs
$(RM) -r $(MAKESUPPORT_OUTPUTDIR)/failure-logs 2> /dev/null $(RM) -r $(MAKESUPPORT_OUTPUTDIR)/failure-logs 2> /dev/null && \
$(MKDIR) -p $(MAKESUPPORT_OUTPUTDIR)/failure-logs $(MKDIR) -p $(MAKESUPPORT_OUTPUTDIR)/failure-logs
endef endef
@ -483,8 +487,8 @@ else # $(HAS_SPEC)=true
endef endef
define StartGlobalTimer define StartGlobalTimer
$(RM) -r $(BUILDTIMESDIR) 2> /dev/null $(RM) -r $(BUILDTIMESDIR) 2> /dev/null && \
$(MKDIR) -p $(BUILDTIMESDIR) $(MKDIR) -p $(BUILDTIMESDIR) && \
$(call RecordStartTime,TOTAL) $(call RecordStartTime,TOTAL)
endef endef
@ -495,13 +499,14 @@ else # $(HAS_SPEC)=true
# Find all build_time_* files and print their contents in a list sorted # Find all build_time_* files and print their contents in a list sorted
# on the name of the sub repository. # on the name of the sub repository.
define ReportBuildTimes define ReportBuildTimes
$(BUILD_LOG_WRAPPER) $(PRINTF) $(LOG_INFO) -- \ $(PRINTF) $(LOG_INFO) -- \
"----- Build times -------\nStart %s\nEnd %s\n%s\n%s\n-------------------------\n" \ "----- Build times -------\nStart %s\nEnd %s\n%s\n%s\n-------------------------\n" \
"`$(CAT) $(BUILDTIMESDIR)/build_time_start_TOTAL_human_readable`" \ "`$(CAT) $(BUILDTIMESDIR)/build_time_start_TOTAL_human_readable`" \
"`$(CAT) $(BUILDTIMESDIR)/build_time_end_TOTAL_human_readable`" \ "`$(CAT) $(BUILDTIMESDIR)/build_time_end_TOTAL_human_readable`" \
"`$(LS) $(BUILDTIMESDIR)/build_time_diff_* | $(GREP) -v _TOTAL | \ "`$(LS) $(BUILDTIMESDIR)/build_time_diff_* | $(GREP) -v _TOTAL | \
$(XARGS) $(CAT) | $(SORT) -k 2`" \ $(XARGS) $(CAT) | $(SORT) -k 2`" \
"`$(CAT) $(BUILDTIMESDIR)/build_time_diff_TOTAL`" "`$(CAT) $(BUILDTIMESDIR)/build_time_diff_TOTAL`" \
$(BUILD_LOG_PIPE)
endef endef
endif # HAS_SPEC endif # HAS_SPEC

View File

@ -57,23 +57,23 @@ ifeq ($(OPENJDK_TARGET_OS), macosx)
# Copy empty directories (jre/lib/applet). # Copy empty directories (jre/lib/applet).
$(JDK_MACOSX_BUNDLE_DIR)/Home/%: $(JDK_IMAGE_DIR)/% $(JDK_MACOSX_BUNDLE_DIR)/Home/%: $(JDK_IMAGE_DIR)/%
$(ECHO) Copying $(patsubst $(OUTPUT_ROOT)/%,%,$@) $(LOG_INFO) $(call LogInfo, Copying $(patsubst $(OUTPUT_ROOT)/%,%,$@))
$(MKDIR) -p $(@D) $(MKDIR) -p $(@D)
if [ -d "$<" ]; then $(MKDIR) -p $@; else $(CP) -f -R -P '$<' '$@'; fi if [ -d "$<" ]; then $(MKDIR) -p $@; else $(CP) -f -R -P '$<' '$@'; fi
$(JRE_MACOSX_BUNDLE_DIR)/Home/%: $(JRE_IMAGE_DIR)/% $(JRE_MACOSX_BUNDLE_DIR)/Home/%: $(JRE_IMAGE_DIR)/%
$(ECHO) Copying $(patsubst $(OUTPUT_ROOT)/%,%,$@) $(LOG_INFO) $(call LogInfo, Copying $(patsubst $(OUTPUT_ROOT)/%,%,$@))
$(MKDIR) -p $(@D) $(MKDIR) -p $(@D)
if [ -d "$<" ]; then $(MKDIR) -p $@; else $(CP) -f -R -P '$<' '$@'; fi if [ -d "$<" ]; then $(MKDIR) -p $@; else $(CP) -f -R -P '$<' '$@'; fi
$(JDK_MACOSX_BUNDLE_DIR)/MacOS/libjli.dylib: $(JDK_MACOSX_BUNDLE_DIR)/MacOS/libjli.dylib:
$(ECHO) Creating link $(patsubst $(OUTPUT_ROOT)/%,%,$@) $(LOG_INFO) $(call LogInfo, Creating link $(patsubst $(OUTPUT_ROOT)/%,%,$@))
$(MKDIR) -p $(@D) $(MKDIR) -p $(@D)
$(RM) $@ $(RM) $@
$(LN) -s ../Home/lib/jli/libjli.dylib $@ $(LN) -s ../Home/lib/jli/libjli.dylib $@
$(JRE_MACOSX_BUNDLE_DIR)/MacOS/libjli.dylib: $(JRE_MACOSX_BUNDLE_DIR)/MacOS/libjli.dylib:
$(ECHO) Creating link $(patsubst $(OUTPUT_ROOT)/%,%,$@) $(LOG_INFO) $(call LogInfo, Creating link $(patsubst $(OUTPUT_ROOT)/%,%,$@))
$(MKDIR) -p $(@D) $(MKDIR) -p $(@D)
$(RM) $@ $(RM) $@
$(LN) -s ../Home/lib/jli/libjli.dylib $@ $(LN) -s ../Home/lib/jli/libjli.dylib $@

View File

@ -42,6 +42,8 @@ include $(SRC_ROOT)/make/MainSupport.gmk
# Load the vital tools for all the makefiles. # Load the vital tools for all the makefiles.
include $(SRC_ROOT)/make/common/MakeBase.gmk include $(SRC_ROOT)/make/common/MakeBase.gmk
# Explicitly generate module deps makefile data
include $(SRC_ROOT)/make/GenerateModuleDeps.gmk
include $(SRC_ROOT)/make/common/Modules.gmk include $(SRC_ROOT)/make/common/Modules.gmk
# Declare ALL_TARGETS as an immediate variable. This variable is a list of all # Declare ALL_TARGETS as an immediate variable. This variable is a list of all
@ -78,7 +80,7 @@ interim-cldrconverter:
+($(CD) $(JDK_TOPDIR)/make && $(MAKE) $(MAKE_ARGS) -f CopyInterimCLDRConverter.gmk) +($(CD) $(JDK_TOPDIR)/make && $(MAKE) $(MAKE_ARGS) -f CopyInterimCLDRConverter.gmk)
buildtools-jdk: buildtools-jdk:
+($(CD) $(JDK_TOPDIR)/make && $(MAKE) $(MAKE_ARGS) -f Tools.gmk java-tools) +($(CD) $(JDK_TOPDIR)/make && $(MAKE) $(MAKE_ARGS) -f CompileTools.gmk)
ALL_TARGETS += buildtools-langtools interim-langtools \ ALL_TARGETS += buildtools-langtools interim-langtools \
interim-rmic interim-cldrconverter buildtools-jdk interim-rmic interim-cldrconverter buildtools-jdk
@ -218,7 +220,7 @@ ALL_TARGETS += demos-jdk samples-jdk
# used to track the exact sources used to build that image. # used to track the exact sources used to build that image.
source-tips: $(SUPPORT_OUTPUTDIR)/source_tips source-tips: $(SUPPORT_OUTPUTDIR)/source_tips
$(SUPPORT_OUTPUTDIR)/source_tips: FRC $(SUPPORT_OUTPUTDIR)/source_tips: FRC
@$(MKDIR) -p $(@D) $(call MakeDir, $(@D))
@$(RM) $@ @$(RM) $@
@$(call GetSourceTips) @$(call GetSourceTips)
@ -656,7 +658,7 @@ print-modules:
@$(ECHO) $(sort $(ALL_MODULES)) @$(ECHO) $(sort $(ALL_MODULES))
create-main-targets-include: create-main-targets-include:
@$(ECHO) $(LOG_INFO) Generating main target list $(call LogInfo, Generating main target list)
@$(ECHO) ALL_MAIN_TARGETS := $(sort $(ALL_TARGETS)) > \ @$(ECHO) ALL_MAIN_TARGETS := $(sort $(ALL_TARGETS)) > \
$(MAKESUPPORT_OUTPUTDIR)/main-targets.gmk $(MAKESUPPORT_OUTPUTDIR)/main-targets.gmk

View File

@ -141,7 +141,6 @@ define DeclareRecipeForModuleMakefile
else else
$2-$$($1_TARGET_SUFFIX): $2-$$($1_TARGET_SUFFIX):
endif endif
$(ECHO) $(LOG_INFO) "Building $$@"
ifeq ($$($1_USE_WRAPPER), true) ifeq ($$($1_USE_WRAPPER), true)
+($(CD) $(SRC_ROOT)/make && $(MAKE) $(MAKE_ARGS) \ +($(CD) $(SRC_ROOT)/make && $(MAKE) $(MAKE_ARGS) \
-f ModuleWrapper.gmk \ -f ModuleWrapper.gmk \

View File

@ -40,8 +40,8 @@ MODULES_LIBS_STRIPPED := $(SUPPORT_OUTPUTDIR)/modules_libs-stripped
ifneq ($(STRIP), ) ifneq ($(STRIP), )
define StripRecipe define StripRecipe
$(ECHO) Stripping $(LOG_INFO) $(patsubst $(OUTPUT_ROOT)/%,%,$<) $(call LogInfo, Stripping $(patsubst $(OUTPUT_ROOT)/%,%,$<))
$(MKDIR) -p $(@D) $(call MakeDir, $(@D))
$(CP) $< $@.tmp $(CP) $< $@.tmp
$(CHMOD) u+w $@.tmp $(CHMOD) u+w $@.tmp
$(STRIP) $(STRIPFLAGS) $@.tmp $(STRIP) $(STRIPFLAGS) $@.tmp

View File

@ -56,10 +56,9 @@ define add_idl_package
$4_OLDIMPLBASE_MSG:=with -oldImplBase $4_OLDIMPLBASE_MSG:=with -oldImplBase
endif endif
$5 : $4 $5 : $4
$(MKDIR) -p $3/$$($4_TMPDIR) $$(call LogInfo, Compiling IDL $(patsubst $2/%,%,$4))
$$(call MakeDir, $$(@D))
$(RM) -rf $3/$$($4_TMPDIR) $(RM) -rf $3/$$($4_TMPDIR)
$(MKDIR) -p $(dir $5)
$(ECHO) $(LOG_INFO) Compiling IDL $(patsubst $2/%,%,$4)
$8 -td $3/$$($4_TMPDIR) \ $8 -td $3/$$($4_TMPDIR) \
-i $2/org/omg/CORBA \ -i $2/org/omg/CORBA \
-i $2/org/omg/PortableInterceptor \ -i $2/org/omg/PortableInterceptor \

View File

@ -86,8 +86,7 @@ BUILDTIMESDIR=$(OUTPUT_ROOT)/make-support/build-times
# Record starting time for build of a sub repository. # Record starting time for build of a sub repository.
define RecordStartTime define RecordStartTime
$(MKDIR) -p $(BUILDTIMESDIR) $(DATE) '+%Y %m %d %H %M %S' | $(NAWK) '{ print $$1,$$2,$$3,$$4,$$5,$$6,($$4*3600+$$5*60+$$6) }' > $(BUILDTIMESDIR)/build_time_start_$(strip $1) && \
$(DATE) '+%Y %m %d %H %M %S' | $(NAWK) '{ print $$1,$$2,$$3,$$4,$$5,$$6,($$4*3600+$$5*60+$$6) }' > $(BUILDTIMESDIR)/build_time_start_$(strip $1)
$(DATE) '+%Y-%m-%d %H:%M:%S' > $(BUILDTIMESDIR)/build_time_start_$(strip $1)_human_readable $(DATE) '+%Y-%m-%d %H:%M:%S' > $(BUILDTIMESDIR)/build_time_start_$(strip $1)_human_readable
endef endef
@ -233,6 +232,7 @@ else # HAS_FILE_FUNCTION
endef endef
endif # HAS_FILE_FUNCTION endif # HAS_FILE_FUNCTION
################################################################################
# The source tips can come from the Mercurial repository, or in the files # The source tips can come from the Mercurial repository, or in the files
# $(HGTIP_FILENAME) which contains the tip but is also positioned in the same # $(HGTIP_FILENAME) which contains the tip but is also positioned in the same
# directory as the original $(HGDIR) directory. # directory as the original $(HGDIR) directory.
@ -264,12 +264,14 @@ define GetSourceTips
$(PRINTF) "\n" >> $@ $(PRINTF) "\n" >> $@
endef endef
# Create the HGTIP_FILENAME file. Called from jdk/make/closed/bundles.gmk # Create the HGTIP_FILENAME file. Called from closed/make/SourceBundles.gmk
define CreateHgTip define CreateHgTip
$(HG) tip --repository $1 --template '{node|short}\n' > $1/$(HGTIP_FILENAME); \ $(HG) tip --repository $1 --template '{node|short}\n' > $1/$(HGTIP_FILENAME); \
$(ECHO) $1/$(HGTIP_FILENAME) $(ECHO) $1/$(HGTIP_FILENAME)
endef endef
################################################################################
define SetupLogging define SetupLogging
ifeq ($$(LOG_LEVEL), trace) ifeq ($$(LOG_LEVEL), trace)
# Shell redefinition trick inspired by http://www.cmcrossroads.com/ask-mr-make/6535-tracing-rule-execution-in-gnu-make # Shell redefinition trick inspired by http://www.cmcrossroads.com/ask-mr-make/6535-tracing-rule-execution-in-gnu-make
@ -368,9 +370,9 @@ endef
################################################################################ ################################################################################
# Make directory without forking mkdir if not needed # Make directory without forking mkdir if not needed
# 1: List of directories to create
MakeDir = \ MakeDir = \
$(strip $(if $(subst $(wildcard $1 $2 $3 $4 $5 $6 $7 $8 $9),,$(strip $1 $2 $3 $4 $5 $6 $7 $8 $9)),\ $(strip $(if $(wildcard $1), , $(shell $(MKDIR) -p $1)))
$(shell $(MKDIR) -p $1 $2 $3 $4 $5 $6 $7 $8 $9)))
################################################################################ ################################################################################
# Assign a variable only if it is empty # Assign a variable only if it is empty
@ -418,7 +420,8 @@ else
# Running mkdir and cp in the same shell speeds up copy intensive tasks in Cygwin # Running mkdir and cp in the same shell speeds up copy intensive tasks in Cygwin
# significantly. # significantly.
define install-file define install-file
$(MKDIR) -p '$(@D)' && $(CP) -fP '$<' '$@' $(call MakeDir, $(@D))
$(CP) -fP '$<' '$@'
endef endef
endif endif
@ -541,7 +544,7 @@ define AddFileToCopy
# 3 : Variable to add targets to # 3 : Variable to add targets to
# 4 : Macro to call for copy operation # 4 : Macro to call for copy operation
$2: $1 $2: $1
$(ECHO) $(LOG_INFO) Copying $$(patsubst $(OUTPUT_ROOT)/%,%,$$@) $$(call LogInfo, Copying $$(patsubst $(OUTPUT_ROOT)/%,%,$$@))
$$($$(strip $4)) $$($$(strip $4))
$3 += $2 $3 += $2
@ -686,8 +689,10 @@ DependOnVariable = \
# Param 2 - A compact but representative name to describe this command # Param 2 - A compact but representative name to describe this command
# Param 3 - Command to run # Param 3 - Command to run
LogFailures = \ LogFailures = \
( ($(BASH) $(SRC_ROOT)/common/bin/logger.sh $1 $3 && $(RM) $1) || \ ( $3 > >($(TEE) $1) 2> >($(TEE) $1 >&2) || \
(exitcode=$(DOLLAR)$(DOLLAR)? && $(MV) $1 $(MAKESUPPORT_OUTPUTDIR)/failure-logs/$(strip $2).log && exit $(DOLLAR)$(DOLLAR)exitcode) ) (exitcode=$(DOLLAR)$(DOLLAR)? && \
$(CP) $1 $(MAKESUPPORT_OUTPUTDIR)/failure-logs/$(strip $2).log && \
exit $(DOLLAR)$(DOLLAR)exitcode) )
################################################################################ ################################################################################
# Find lib dir for module # Find lib dir for module

View File

@ -26,9 +26,6 @@
ifndef _MODULES_GMK ifndef _MODULES_GMK
_MODULES_GMK := 1 _MODULES_GMK := 1
include JavaCompilation.gmk
include SetupJavaCompilers.gmk
################################################################################ ################################################################################
# Some platforms don't have the serviceability agent # Some platforms don't have the serviceability agent
ifeq ($(INCLUDE_SA), false) ifeq ($(INCLUDE_SA), false)
@ -71,29 +68,8 @@ define FindAllModules
endef endef
################################################################################ ################################################################################
# The module deps makefile is generated in make/GenerateModuleDeps.gmk
$(eval $(call SetupJavaCompilation,BUILD_GENMODULESLIST, \
SETUP := BOOT_JAVAC, \
SRC := $(JDK_TOPDIR)/make/src/classes, \
INCLUDES := build/tools/module, \
EXCLUDE_FILES := ImageBuilder.java ModuleArchive.java, \
BIN := $(MAKESUPPORT_OUTPUTDIR)/bt_classes_moduleslist, \
DISABLE_SJAVAC := true))
TOOL_GENMODULESLIST = $(JAVA_SMALL) \
-cp "$(MAKESUPPORT_OUTPUTDIR)/bt_classes_moduleslist" \
build.tools.module.GenModulesList
MODULES_LIST_FILE := $(MAKESUPPORT_OUTPUTDIR)/modules.list
MODULE_DEPS_MAKEFILE := $(MAKESUPPORT_OUTPUTDIR)/module-deps.gmk MODULE_DEPS_MAKEFILE := $(MAKESUPPORT_OUTPUTDIR)/module-deps.gmk
$(MODULES_LIST_FILE): $(SRC_ROOT)/modules.xml \
$(BUILD_GENMODULESLIST)
$(TOOL_GENMODULESLIST) -o $@ $(filter %.xml, $^)
$(MODULE_DEPS_MAKEFILE): $(MODULES_LIST_FILE)
$(CAT) $^ | $(SED) -e 's/^\([^:]*\):/DEPS_\1 :=/g' > $@
-include $(MODULE_DEPS_MAKEFILE) -include $(MODULE_DEPS_MAKEFILE)
# Param 1: Module to find deps for # Param 1: Module to find deps for

View File

@ -261,18 +261,17 @@ define add_native_source
# The Visual Studio compiler lacks a feature for generating make dependencies, but by # The Visual Studio compiler lacks a feature for generating make dependencies, but by
# setting -showIncludes, all included files are printed. These are filtered out and # setting -showIncludes, all included files are printed. These are filtered out and
# parsed into make dependences. # parsed into make dependences.
# Keep as much as possible on one execution line for best performance on Windows # Keep as much as possible on one execution line for best performance on Windows.
$(RM) $$($1_$2_DEP).exitvalue ; \ # No need to save exit code from compilation since pipefail is always active on
($(call LogFailures, $$($1_$2_OBJ).log, $$($1_SAFE_NAME)_$$(notdir $2), \ # Windows.
$(call LogFailures, $$($1_$2_OBJ).log, $$($1_SAFE_NAME)_$$(notdir $2), \
$$($1_$2_COMP) $$($1_$2_FLAGS) -showIncludes $$($1_$2_DEBUG_OUT_FLAGS) \ $$($1_$2_COMP) $$($1_$2_FLAGS) -showIncludes $$($1_$2_DEBUG_OUT_FLAGS) \
$(CC_OUT_OPTION)$$($1_$2_OBJ) $2) || echo $$$$? > $$($1_$2_DEP).exitvalue ) \ $(CC_OUT_OPTION)$$($1_$2_OBJ) $2) \
| $(TEE) $$($1_$2_DEP).raw | $(GREP) -v -e "^Note: including file:" \ | $(GREP) -v -e "^Note: including file:" \
-e "^$(notdir $2)$$$$" || test "$$$$?" = "1" ; \ -e "^$(notdir $2)$$$$" || test "$$$$?" = "1" ; \
( test -s $$($1_$2_DEP).exitvalue \ $(ECHO) $$@: \\ > $$($1_$2_DEP) ; \
&& exit `$(CAT) $$($1_$2_DEP).exitvalue` || true ) ; \ $(SED) $(WINDOWS_SHOWINCLUDE_SED_PATTERN) $$($1_$2_OBJ).log \
($(ECHO) $$@: \\ ; \ | $(SORT) -u >> $$($1_$2_DEP) ; \
$(SED) $(WINDOWS_SHOWINCLUDE_SED_PATTERN) $$($1_$2_DEP).raw) \
| $(SORT) -u > $$($1_$2_DEP) ; \
$(SED) $(DEPENDENCY_TARGET_SED_PATTERN) $$($1_$2_DEP) > $$($1_$2_DEP_TARGETS) $(SED) $(DEPENDENCY_TARGET_SED_PATTERN) $$($1_$2_DEP) > $$($1_$2_DEP_TARGETS)
endif endif
endif endif
@ -658,14 +657,14 @@ define SetupNativeCompilationBody
$$($1_RES).vardeps) $$($1_RES).vardeps)
$$($1_RES): $$($1_VERSIONINFO_RESOURCE) $$($1_RES_VARDEPS_FILE) $$($1_RES): $$($1_VERSIONINFO_RESOURCE) $$($1_RES_VARDEPS_FILE)
$(ECHO) $(LOG_INFO) "Compiling resource $$(notdir $$($1_VERSIONINFO_RESOURCE)) (for $$(notdir $$($1_TARGET)))" $$(call LogInfo, Compiling resource $$(notdir $$($1_VERSIONINFO_RESOURCE)) (for $$(notdir $$($1_TARGET))))
$$($1_RC) $$($1_RC_FLAGS) $$($1_SYSROOT_CFLAGS) $(CC_OUT_OPTION)$$@ \ $$($1_RC) $$($1_RC_FLAGS) $$($1_SYSROOT_CFLAGS) $(CC_OUT_OPTION)$$@ \
$$($1_VERSIONINFO_RESOURCE) $$($1_VERSIONINFO_RESOURCE)
# Windows RC compiler does not support -showIncludes, so we mis-use CL for this. # Windows RC compiler does not support -showIncludes, so we mis-use CL for this.
$$($1_CC) $$($1_RC_FLAGS) $$($1_SYSROOT_CFLAGS) -showIncludes -nologo -TC \ $$($1_CC) $$($1_RC_FLAGS) $$($1_SYSROOT_CFLAGS) -showIncludes -nologo -TC \
$(CC_OUT_OPTION)$$($1_RES_DEP).obj $$($1_VERSIONINFO_RESOURCE) > $$($1_RES_DEP).raw 2>&1 || exit 0 $(CC_OUT_OPTION)$$($1_RES_DEP).obj $$($1_VERSIONINFO_RESOURCE) > $$($1_RES_DEP).raw 2>&1 || true ; \
($(ECHO) $$($1_RES): \\ \ $(ECHO) $$($1_RES): \\ > $$($1_RES_DEP) ; \
&& $(SED) $(WINDOWS_SHOWINCLUDE_SED_PATTERN) $$($1_RES_DEP).raw) > $$($1_RES_DEP) $(SED) $(WINDOWS_SHOWINCLUDE_SED_PATTERN) $$($1_RES_DEP).raw >> $$($1_RES_DEP) ; \
$(SED) $(DEPENDENCY_TARGET_SED_PATTERN) $$($1_RES_DEP) > $$($1_RES_DEP_TARGETS) $(SED) $(DEPENDENCY_TARGET_SED_PATTERN) $$($1_RES_DEP) > $$($1_RES_DEP_TARGETS)
endif endif
endif endif
@ -801,7 +800,7 @@ define SetupNativeCompilationBody
endif endif
# Keep as much as possible on one execution line for best performance # Keep as much as possible on one execution line for best performance
# on Windows # on Windows
$(ECHO) $(LOG_INFO) "Linking $$($1_BASENAME)" ; \ $$(call LogInfo, Linking $$($1_BASENAME))
$(call LogFailures, $$($1_OBJECT_DIR)/$$($1_SAFE_NAME)_link.log, $$($1_SAFE_NAME)_link, \ $(call LogFailures, $$($1_OBJECT_DIR)/$$($1_SAFE_NAME)_link.log, $$($1_SAFE_NAME)_link, \
$$($1_LD) $$($1_LDFLAGS) $$($1_EXTRA_LDFLAGS) $$($1_SYSROOT_LDFLAGS) \ $$($1_LD) $$($1_LDFLAGS) $$($1_EXTRA_LDFLAGS) $$($1_SYSROOT_LDFLAGS) \
$(LD_OUT_OPTION)$$@ \ $(LD_OUT_OPTION)$$@ \
@ -820,7 +819,7 @@ define SetupNativeCompilationBody
# Generating a static library, ie object file archive. # Generating a static library, ie object file archive.
$$($1_TARGET): $$($1_ALL_OBJS) $$($1_RES) $$($1_VARDEPS_FILE) $$($1_TARGET): $$($1_ALL_OBJS) $$($1_RES) $$($1_VARDEPS_FILE)
$(ECHO) $(LOG_INFO) "Archiving $$($1_STATIC_LIBRARY)" $$(call LogInfo, Archiving $$($1_STATIC_LIBRARY))
$(call LogFailures, $$($1_OBJECT_DIR)/$$($1_SAFE_NAME)_link.log, $$($1_SAFE_NAME)_link, \ $(call LogFailures, $$($1_OBJECT_DIR)/$$($1_SAFE_NAME)_link.log, $$($1_SAFE_NAME)_link, \
$$($1_AR) $$($1_ARFLAGS) $(AR_OUT_OPTION)$$($1_TARGET) $$($1_ALL_OBJS) \ $$($1_AR) $$($1_ARFLAGS) $(AR_OUT_OPTION)$$($1_TARGET) $$($1_ALL_OBJS) \
$$($1_RES)) $$($1_RES))
@ -842,7 +841,7 @@ define SetupNativeCompilationBody
$$($1_TARGET): $$($1_ALL_OBJS) $$($1_RES) $$($1_MANIFEST) \ $$($1_TARGET): $$($1_ALL_OBJS) $$($1_RES) $$($1_MANIFEST) \
$$($1_VARDEPS_FILE) $$($1_VARDEPS_FILE)
$(ECHO) $(LOG_INFO) "Linking executable $$($1_BASENAME)" ; \ $$(call LogInfo, Linking executable $$($1_BASENAME))
$(call LogFailures, $$($1_OBJECT_DIR)/$$($1_SAFE_NAME)_link.log, $$($1_SAFE_NAME)_link, \ $(call LogFailures, $$($1_OBJECT_DIR)/$$($1_SAFE_NAME)_link.log, $$($1_SAFE_NAME)_link, \
$$($1_LD) $$($1_LDFLAGS) $$($1_EXTRA_LDFLAGS) $$($1_SYSROOT_LDFLAGS) \ $$($1_LD) $$($1_LDFLAGS) $$($1_EXTRA_LDFLAGS) $$($1_SYSROOT_LDFLAGS) \
$(EXE_OUT_OPTION)$$($1_TARGET) \ $(EXE_OUT_OPTION)$$($1_TARGET) \

View File

@ -68,15 +68,15 @@ define SetupRMICompilationBody
$$($1_TARGETS): $$($1_DEP_FILE) $$($1_CLASS_FILES) $$($1_TARGETS): $$($1_DEP_FILE) $$($1_CLASS_FILES)
$$($1_DEP_FILE): $$($1_CLASS_FILES) $$($1_DEP_FILE): $$($1_CLASS_FILES)
$(MKDIR) -p $$($1_STUB_CLASSES_DIR) $$(call LogInfo, Running rmic $$($1_ARGS) for $$($1_DOLLAR_SAFE_CLASSES))
$(ECHO) $(LOG_INFO) Running rmic $$($1_ARGS) for $$($1_DOLLAR_SAFE_CLASSES) && \ $$(call MakeDir, $$($1_STUB_CLASSES_DIR))
$(RMIC) $$($1_ARGS) -classpath "$$($1_CLASSES_DIR)" \ $(RMIC) $$($1_ARGS) -classpath "$$($1_CLASSES_DIR)" \
-d $$($1_STUB_CLASSES_DIR) $$($1_DOLLAR_SAFE_CLASSES); \ -d $$($1_STUB_CLASSES_DIR) $$($1_DOLLAR_SAFE_CLASSES); \
if [ "x$$($1_ARGS2)" != "x" ]; then \ if [ "x$$($1_ARGS2)" != "x" ]; then \
$(ECHO) $(LOG_INFO) Running rmic $$($1_ARGS2) for $$($1_DOLLAR_SAFE_CLASSES) && \ $(ECHO) $(LOG_INFO) Running rmic $$($1_ARGS2) for $$($1_DOLLAR_SAFE_CLASSES) && \
$(RMIC) $$($1_ARGS2) -classpath "$$($1_CLASSES_DIR)" \ $(RMIC) $$($1_ARGS2) -classpath "$$($1_CLASSES_DIR)" \
-d $$($1_STUB_CLASSES_DIR) $$($1_DOLLAR_SAFE_CLASSES); \ -d $$($1_STUB_CLASSES_DIR) $$($1_DOLLAR_SAFE_CLASSES); \
fi; fi; \
$(TOUCH) $$@ $(TOUCH) $$@

View File

@ -35,12 +35,12 @@ endif
# param 4 = the target file name (possibly with a partial path) # param 4 = the target file name (possibly with a partial path)
define SetupSingleTextFileForProcessing define SetupSingleTextFileForProcessing
$(strip $3)/$(strip $4): $2 $$($1_VARDEPS_FILE) $(strip $3)/$(strip $4): $2 $$($1_VARDEPS_FILE)
$(ECHO) $(LOG_INFO) "Processing $(strip $4)" $$(call LogInfo, Processing $(strip $4))
$(MKDIR) -p '$$(@D)' $$(call MakeDir, $$(@D))
$(RM) '$$@' '$$@.includes.tmp' '$$@.replacements.tmp' $(RM) '$$@' '$$@.includes.tmp' '$$@.replacements.tmp' ; \
$$($1_INCLUDES_COMMAND_LINE) < '$$<' > '$$@.includes.tmp' $$($1_INCLUDES_COMMAND_LINE) < '$$<' > '$$@.includes.tmp' ; \
$$($1_REPLACEMENTS_COMMAND_LINE) < '$$@.includes.tmp' > '$$@.replacements.tmp' $$($1_REPLACEMENTS_COMMAND_LINE) < '$$@.includes.tmp' > '$$@.replacements.tmp' ; \
$(RM) '$$@.includes.tmp' $(RM) '$$@.includes.tmp' ; \
$(MV) '$$@.replacements.tmp' '$$@' $(MV) '$$@.replacements.tmp' '$$@'
$1 += $(strip $3)/$(strip $4) $1 += $(strip $3)/$(strip $4)