make/linux/makefiles/buildtree.make

Print this page


   1 #
   2 # Copyright (c) 2005, 2012, Oracle and/or its affiliates. All rights reserved.
   3 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
   4 #
   5 # This code is free software; you can redistribute it and/or modify it
   6 # under the terms of the GNU General Public License version 2 only, as
   7 # published by the Free Software Foundation.
   8 #
   9 # This code is distributed in the hope that it will be useful, but WITHOUT
  10 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
  11 # FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
  12 # version 2 for more details (a copy is included in the LICENSE file that
  13 # accompanied this code).
  14 #
  15 # You should have received a copy of the GNU General Public License version
  16 # 2 along with this work; if not, write to the Free Software Foundation,
  17 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
  18 #
  19 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
  20 # or visit www.oracle.com if you need additional information or have any
  21 # questions.
  22 #  


 100 
 101 ifeq            ($(VARIANT),tiered)
 102 TOPLEVEL_EXCLUDE_DIRS   = $(ALWAYS_EXCLUDE_DIRS) -o -name adlc -o -name agent
 103 else
 104 ifeq            ($(VARIANT),compiler2)
 105 TOPLEVEL_EXCLUDE_DIRS   = $(ALWAYS_EXCLUDE_DIRS) -o -name adlc -o -name c1 -o -name agent
 106 else
 107 # compiler1 and core use the same exclude list
 108 TOPLEVEL_EXCLUDE_DIRS   = $(ALWAYS_EXCLUDE_DIRS) -o -name adlc -o -name opto -o -name libadt -o -name agent
 109 endif
 110 endif
 111 
 112 # Get things from the platform file.
 113 COMPILER        = $(shell sed -n 's/^compiler[  ]*=[    ]*//p' $(PLATFORM_FILE))
 114 
 115 SIMPLE_DIRS     = \
 116         $(PLATFORM_DIR)/generated/dependencies \
 117         $(PLATFORM_DIR)/generated/adfiles \
 118         $(PLATFORM_DIR)/generated/jvmtifiles
 119 
 120 TARGETS      = debug fastdebug jvmg optimized product profiled
 121 SUBMAKE_DIRS = $(addprefix $(PLATFORM_DIR)/,$(TARGETS))
 122 
 123 # For dependencies and recursive makes.
 124 BUILDTREE_MAKE  = $(GAMMADIR)/make/$(OS_FAMILY)/makefiles/buildtree.make
 125 
 126 BUILDTREE_TARGETS = Makefile flags.make flags_vm.make vm.make adlc.make jvmti.make sa.make \
 127         env.sh env.csh jdkpath.sh
 128 
 129 BUILDTREE_VARS  = GAMMADIR=$(GAMMADIR) OS_FAMILY=$(OS_FAMILY) \
 130         SRCARCH=$(SRCARCH) BUILDARCH=$(BUILDARCH) LIBARCH=$(LIBARCH) VARIANT=$(VARIANT)
 131 
 132 # Define variables to be set in flags.make.
 133 # Default values are set in make/defs.make.
 134 ifeq ($(HOTSPOT_BUILD_VERSION),)
 135   HS_BUILD_VER=$(HOTSPOT_RELEASE_VERSION)
 136 else
 137   HS_BUILD_VER=$(HOTSPOT_RELEASE_VERSION)-$(HOTSPOT_BUILD_VERSION)
 138 endif
 139 # Set BUILD_USER from system-dependent hints:  $LOGNAME, $(whoami)
 140 ifndef HOTSPOT_BUILD_USER


 253             echo && echo "ZIP_DEBUGINFO_FILES = $(ZIP_DEBUGINFO_FILES)"; \
 254         [ -n "$(ZIPEXE)" ] && \
 255             echo && echo "ZIPEXE = $(ZIPEXE)"; \
 256         [ -n "$(HOTSPOT_EXTRA_SYSDEFS)" ] && \
 257             echo && \
 258             echo "HOTSPOT_EXTRA_SYSDEFS\$$(HOTSPOT_EXTRA_SYSDEFS) = $(HOTSPOT_EXTRA_SYSDEFS)" && \
 259             echo "SYSDEFS += \$$(HOTSPOT_EXTRA_SYSDEFS)"; \
 260         echo; \
 261         [ -n "$(SPEC)" ] && \
 262             echo "include $(SPEC)"; \
 263         echo "include \$$(GAMMADIR)/make/$(OS_FAMILY)/makefiles/$(VARIANT).make"; \
 264         echo "include \$$(GAMMADIR)/make/excludeSrc.make"; \
 265         echo "include \$$(GAMMADIR)/make/$(OS_FAMILY)/makefiles/$(COMPILER).make"; \
 266         ) > $@
 267 
 268 flags_vm.make: $(BUILDTREE_MAKE) ../shared_dirs.lst
 269         @echo Creating $@ ...
 270         $(QUIETLY) ( \
 271         $(BUILDTREE_COMMENT); \
 272         echo; \
 273         [ "$(TARGET)" = profiled ] && \
 274         echo "include \$$(GAMMADIR)/make/$(OS_FAMILY)/makefiles/optimized.make"; \
 275         echo "include \$$(GAMMADIR)/make/$(OS_FAMILY)/makefiles/$(TARGET).make"; \
 276         ) > $@
 277 
 278 ../shared_dirs.lst:  $(BUILDTREE_MAKE) $(GAMMADIR)/src/share/vm
 279         @echo Creating directory list $@
 280         $(QUIETLY) if [ -d $(HS_ALT_SRC)/share/vm ]; then \
 281           find $(HS_ALT_SRC)/share/vm/* -prune \
 282           -type d \! \( $(TOPLEVEL_EXCLUDE_DIRS) \) -exec find {} \
 283           \( $(ALWAYS_EXCLUDE_DIRS) \) -prune -o -type d -print \; > $@; \
 284         fi;
 285         $(QUIETLY) find $(HS_COMMON_SRC)/share/vm/* -prune \
 286         -type d \! \( $(TOPLEVEL_EXCLUDE_DIRS) \) -exec find {} \
 287         \( $(ALWAYS_EXCLUDE_DIRS) \) -prune -o -type d -print \; >> $@
 288 
 289 Makefile: $(BUILDTREE_MAKE)
 290         @echo Creating $@ ...
 291         $(QUIETLY) ( \
 292         $(BUILDTREE_COMMENT); \
 293         echo; \
 294         echo include flags.make; \


   1 #
   2 # Copyright (c) 2005, 2013, Oracle and/or its affiliates. All rights reserved.
   3 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
   4 #
   5 # This code is free software; you can redistribute it and/or modify it
   6 # under the terms of the GNU General Public License version 2 only, as
   7 # published by the Free Software Foundation.
   8 #
   9 # This code is distributed in the hope that it will be useful, but WITHOUT
  10 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
  11 # FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
  12 # version 2 for more details (a copy is included in the LICENSE file that
  13 # accompanied this code).
  14 #
  15 # You should have received a copy of the GNU General Public License version
  16 # 2 along with this work; if not, write to the Free Software Foundation,
  17 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
  18 #
  19 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
  20 # or visit www.oracle.com if you need additional information or have any
  21 # questions.
  22 #


 100 
 101 ifeq            ($(VARIANT),tiered)
 102 TOPLEVEL_EXCLUDE_DIRS   = $(ALWAYS_EXCLUDE_DIRS) -o -name adlc -o -name agent
 103 else
 104 ifeq            ($(VARIANT),compiler2)
 105 TOPLEVEL_EXCLUDE_DIRS   = $(ALWAYS_EXCLUDE_DIRS) -o -name adlc -o -name c1 -o -name agent
 106 else
 107 # compiler1 and core use the same exclude list
 108 TOPLEVEL_EXCLUDE_DIRS   = $(ALWAYS_EXCLUDE_DIRS) -o -name adlc -o -name opto -o -name libadt -o -name agent
 109 endif
 110 endif
 111 
 112 # Get things from the platform file.
 113 COMPILER        = $(shell sed -n 's/^compiler[  ]*=[    ]*//p' $(PLATFORM_FILE))
 114 
 115 SIMPLE_DIRS     = \
 116         $(PLATFORM_DIR)/generated/dependencies \
 117         $(PLATFORM_DIR)/generated/adfiles \
 118         $(PLATFORM_DIR)/generated/jvmtifiles
 119 
 120 TARGETS      = debug fastdebug optimized product
 121 SUBMAKE_DIRS = $(addprefix $(PLATFORM_DIR)/,$(TARGETS))
 122 
 123 # For dependencies and recursive makes.
 124 BUILDTREE_MAKE  = $(GAMMADIR)/make/$(OS_FAMILY)/makefiles/buildtree.make
 125 
 126 BUILDTREE_TARGETS = Makefile flags.make flags_vm.make vm.make adlc.make jvmti.make sa.make \
 127         env.sh env.csh jdkpath.sh
 128 
 129 BUILDTREE_VARS  = GAMMADIR=$(GAMMADIR) OS_FAMILY=$(OS_FAMILY) \
 130         SRCARCH=$(SRCARCH) BUILDARCH=$(BUILDARCH) LIBARCH=$(LIBARCH) VARIANT=$(VARIANT)
 131 
 132 # Define variables to be set in flags.make.
 133 # Default values are set in make/defs.make.
 134 ifeq ($(HOTSPOT_BUILD_VERSION),)
 135   HS_BUILD_VER=$(HOTSPOT_RELEASE_VERSION)
 136 else
 137   HS_BUILD_VER=$(HOTSPOT_RELEASE_VERSION)-$(HOTSPOT_BUILD_VERSION)
 138 endif
 139 # Set BUILD_USER from system-dependent hints:  $LOGNAME, $(whoami)
 140 ifndef HOTSPOT_BUILD_USER


 253             echo && echo "ZIP_DEBUGINFO_FILES = $(ZIP_DEBUGINFO_FILES)"; \
 254         [ -n "$(ZIPEXE)" ] && \
 255             echo && echo "ZIPEXE = $(ZIPEXE)"; \
 256         [ -n "$(HOTSPOT_EXTRA_SYSDEFS)" ] && \
 257             echo && \
 258             echo "HOTSPOT_EXTRA_SYSDEFS\$$(HOTSPOT_EXTRA_SYSDEFS) = $(HOTSPOT_EXTRA_SYSDEFS)" && \
 259             echo "SYSDEFS += \$$(HOTSPOT_EXTRA_SYSDEFS)"; \
 260         echo; \
 261         [ -n "$(SPEC)" ] && \
 262             echo "include $(SPEC)"; \
 263         echo "include \$$(GAMMADIR)/make/$(OS_FAMILY)/makefiles/$(VARIANT).make"; \
 264         echo "include \$$(GAMMADIR)/make/excludeSrc.make"; \
 265         echo "include \$$(GAMMADIR)/make/$(OS_FAMILY)/makefiles/$(COMPILER).make"; \
 266         ) > $@
 267 
 268 flags_vm.make: $(BUILDTREE_MAKE) ../shared_dirs.lst
 269         @echo Creating $@ ...
 270         $(QUIETLY) ( \
 271         $(BUILDTREE_COMMENT); \
 272         echo; \


 273         echo "include \$$(GAMMADIR)/make/$(OS_FAMILY)/makefiles/$(TARGET).make"; \
 274         ) > $@
 275 
 276 ../shared_dirs.lst:  $(BUILDTREE_MAKE) $(GAMMADIR)/src/share/vm
 277         @echo Creating directory list $@
 278         $(QUIETLY) if [ -d $(HS_ALT_SRC)/share/vm ]; then \
 279           find $(HS_ALT_SRC)/share/vm/* -prune \
 280           -type d \! \( $(TOPLEVEL_EXCLUDE_DIRS) \) -exec find {} \
 281           \( $(ALWAYS_EXCLUDE_DIRS) \) -prune -o -type d -print \; > $@; \
 282         fi;
 283         $(QUIETLY) find $(HS_COMMON_SRC)/share/vm/* -prune \
 284         -type d \! \( $(TOPLEVEL_EXCLUDE_DIRS) \) -exec find {} \
 285         \( $(ALWAYS_EXCLUDE_DIRS) \) -prune -o -type d -print \; >> $@
 286 
 287 Makefile: $(BUILDTREE_MAKE)
 288         @echo Creating $@ ...
 289         $(QUIETLY) ( \
 290         $(BUILDTREE_COMMENT); \
 291         echo; \
 292         echo include flags.make; \