make/solaris/makefiles/buildtree.make

Print this page
rev 4773 : 8005849: JEP 167: Event-Based JVM Tracing
Reviewed-by: acorn, coleenp, sla
Contributed-by: Karen Kinnear <karen.kinnear@oracle.com>, Bengt Rutisson <bengt.rutisson@oracle.com>, Calvin Cheung <calvin.cheung@oracle.com>, Erik Gahlin <erik.gahlin@oracle.com>, Erik Helin <erik.helin@oracle.com>, Jesper Wilhelmsson <jesper.wilhelmsson@oracle.com>, Keith McGuigan <keith.mcguigan@oracle.com>, Mattias Tobiasson <mattias.tobiasson@oracle.com>, Markus Gronlund <markus.gronlund@oracle.com>, Mikael Auno <mikael.auno@oracle.com>, Nils Eliasson <nils.eliasson@oracle.com>, Nils Loodin <nils.loodin@oracle.com>, Rickard Backman <rickard.backman@oracle.com>, Staffan Larsen <staffan.larsen@oracle.com>, Stefan Karlsson <stefan.karlsson@oracle.com>, Yekaterina Kantserova <yekaterina.kantserova@oracle.com>


  30 # The macros ARCH, GAMMADIR, OS_FAMILY and VARIANT must be defined in the
  31 # environment or on the command-line:
  32 #
  33 # ARCH          - sparc, i486, ... HotSpot cpu and os_cpu source directory
  34 # BUILDARCH     - build directory
  35 # LIBARCH       - the corresponding directory in JDK/JRE
  36 # GAMMADIR      - top of workspace
  37 # OS_FAMILY     - operating system
  38 # VARIANT       - core, compiler1, compiler2, or tiered
  39 # HOTSPOT_RELEASE_VERSION - <major>.<minor>-b<nn> (11.0-b07)
  40 # HOTSPOT_BUILD_VERSION   - internal, internal-$(USER_RELEASE_SUFFIX) or empty
  41 # JRE_RELEASE_VERSION     - <major>.<minor>.<micro> (1.7.0)
  42 #
  43 # Builds the directory trees with makefiles plus some convenience files in
  44 # each directory:
  45 #
  46 # Makefile      - for "make foo"
  47 # flags.make    - with macro settings
  48 # vm.make       - to support making "$(MAKE) -v vm.make" in makefiles
  49 # adlc.make     -

  50 # jvmti.make    - generate JVMTI bindings from the spec (JSR-163)
  51 # sa.make       - generate SA jar file and natives
  52 #
  53 # The makefiles are split this way so that "make foo" will run faster by not
  54 # having to read the dependency files for the vm.
  55 
  56 -include $(SPEC)
  57 include $(GAMMADIR)/make/scm.make
  58 include $(GAMMADIR)/make/defs.make
  59 include $(GAMMADIR)/make/altsrc.make
  60 
  61 
  62 # 'gmake MAKE_VERBOSE=y' or 'gmake QUIETLY=' gives all the gory details.
  63 QUIETLY$(MAKE_VERBOSE)  = @
  64 
  65 ### maye ARCH_XXX instead?
  66 ifdef USE_GCC
  67 PLATFORM_FILE   = $(GAMMADIR)/make/$(OS_FAMILY)/platform_$(BUILDARCH).gcc
  68 GCC_LIB         = /usr/local/lib
  69 else


  90 
  91 ALWAYS_EXCLUDE_DIRS     = $(SCM_DIRS)
  92 
  93 ifeq            ($(VARIANT),tiered)
  94 TOPLEVEL_EXCLUDE_DIRS   = $(ALWAYS_EXCLUDE_DIRS) -o -name adlc -o -name agent
  95 else
  96 ifeq            ($(VARIANT),compiler2)
  97 TOPLEVEL_EXCLUDE_DIRS   = $(ALWAYS_EXCLUDE_DIRS) -o -name adlc -o -name c1 -o -name agent
  98 else
  99 # compiler1 and core use the same exclude list
 100 TOPLEVEL_EXCLUDE_DIRS   = $(ALWAYS_EXCLUDE_DIRS) -o -name adlc -o -name opto -o -name libadt -o -name agent
 101 endif
 102 endif
 103 
 104 # Get things from the platform file.
 105 COMPILER        = $(shell sed -n 's/^compiler[  ]*=[    ]*//p' $(PLATFORM_FILE))
 106 
 107 SIMPLE_DIRS     = \
 108         $(PLATFORM_DIR)/generated/dependencies \
 109         $(PLATFORM_DIR)/generated/adfiles \
 110         $(PLATFORM_DIR)/generated/jvmtifiles

 111 
 112 TARGETS      = debug fastdebug optimized product
 113 SUBMAKE_DIRS = $(addprefix $(PLATFORM_DIR)/,$(TARGETS))
 114 
 115 # For dependencies and recursive makes.
 116 BUILDTREE_MAKE  = $(GAMMADIR)/make/$(OS_FAMILY)/makefiles/buildtree.make
 117 
 118 BUILDTREE_TARGETS = Makefile flags.make flags_vm.make vm.make adlc.make jvmti.make sa.make
 119 
 120 BUILDTREE_VARS  = GAMMADIR=$(GAMMADIR) OS_FAMILY=$(OS_FAMILY) \
 121         ARCH=$(ARCH) BUILDARCH=$(BUILDARCH) LIBARCH=$(LIBARCH) VARIANT=$(VARIANT)
 122 
 123 # Define variables to be set in flags.make.
 124 # Default values are set in make/defs.make.
 125 ifeq ($(HOTSPOT_BUILD_VERSION),)
 126   HS_BUILD_VER=$(HOTSPOT_RELEASE_VERSION)
 127 else
 128   HS_BUILD_VER=$(HOTSPOT_RELEASE_VERSION)-$(HOTSPOT_BUILD_VERSION)
 129 endif
 130 # Set BUILD_USER from system-dependent hints:  $LOGNAME, $(whoami)
 131 ifndef HOTSPOT_BUILD_USER
 132   HOTSPOT_BUILD_USER := $(shell echo $$LOGNAME)
 133 endif
 134 ifndef HOTSPOT_BUILD_USER
 135   HOTSPOT_BUILD_USER := $(shell whoami)
 136 endif
 137 # Define HOTSPOT_VM_DISTRO based on settings in make/openjdk_distro
 138 # or make/hotspot_distro.


 310 adlc.make: $(BUILDTREE_MAKE)
 311         @echo Creating $@ ...
 312         $(QUIETLY) ( \
 313         $(BUILDTREE_COMMENT); \
 314         echo; \
 315         echo include flags.make; \
 316         echo; \
 317         echo "include \$$(GAMMADIR)/make/$(OS_FAMILY)/makefiles/$(@F)"; \
 318         ) > $@
 319 
 320 jvmti.make: $(BUILDTREE_MAKE)
 321         @echo Creating $@ ...
 322         $(QUIETLY) ( \
 323         $(BUILDTREE_COMMENT); \
 324         echo; \
 325         echo include flags.make; \
 326         echo; \
 327         echo "include \$$(GAMMADIR)/make/$(OS_FAMILY)/makefiles/$(@F)"; \
 328         ) > $@
 329 










 330 sa.make: $(BUILDTREE_MAKE)
 331         @echo Creating $@ ...
 332         $(QUIETLY) ( \
 333         $(BUILDTREE_COMMENT); \
 334         echo; \
 335         echo include flags.make; \
 336         echo; \
 337         echo "include \$$(GAMMADIR)/make/$(OS_FAMILY)/makefiles/$(@F)"; \
 338         ) > $@
 339 
 340 FORCE:
 341 
 342 .PHONY:  all FORCE


  30 # The macros ARCH, GAMMADIR, OS_FAMILY and VARIANT must be defined in the
  31 # environment or on the command-line:
  32 #
  33 # ARCH          - sparc, i486, ... HotSpot cpu and os_cpu source directory
  34 # BUILDARCH     - build directory
  35 # LIBARCH       - the corresponding directory in JDK/JRE
  36 # GAMMADIR      - top of workspace
  37 # OS_FAMILY     - operating system
  38 # VARIANT       - core, compiler1, compiler2, or tiered
  39 # HOTSPOT_RELEASE_VERSION - <major>.<minor>-b<nn> (11.0-b07)
  40 # HOTSPOT_BUILD_VERSION   - internal, internal-$(USER_RELEASE_SUFFIX) or empty
  41 # JRE_RELEASE_VERSION     - <major>.<minor>.<micro> (1.7.0)
  42 #
  43 # Builds the directory trees with makefiles plus some convenience files in
  44 # each directory:
  45 #
  46 # Makefile      - for "make foo"
  47 # flags.make    - with macro settings
  48 # vm.make       - to support making "$(MAKE) -v vm.make" in makefiles
  49 # adlc.make     -
  50 # trace.make    - generate tracing event and type definitions
  51 # jvmti.make    - generate JVMTI bindings from the spec (JSR-163)
  52 # sa.make       - generate SA jar file and natives
  53 #
  54 # The makefiles are split this way so that "make foo" will run faster by not
  55 # having to read the dependency files for the vm.
  56 
  57 -include $(SPEC)
  58 include $(GAMMADIR)/make/scm.make
  59 include $(GAMMADIR)/make/defs.make
  60 include $(GAMMADIR)/make/altsrc.make
  61 
  62 
  63 # 'gmake MAKE_VERBOSE=y' or 'gmake QUIETLY=' gives all the gory details.
  64 QUIETLY$(MAKE_VERBOSE)  = @
  65 
  66 ### maye ARCH_XXX instead?
  67 ifdef USE_GCC
  68 PLATFORM_FILE   = $(GAMMADIR)/make/$(OS_FAMILY)/platform_$(BUILDARCH).gcc
  69 GCC_LIB         = /usr/local/lib
  70 else


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


 312 adlc.make: $(BUILDTREE_MAKE)
 313         @echo Creating $@ ...
 314         $(QUIETLY) ( \
 315         $(BUILDTREE_COMMENT); \
 316         echo; \
 317         echo include flags.make; \
 318         echo; \
 319         echo "include \$$(GAMMADIR)/make/$(OS_FAMILY)/makefiles/$(@F)"; \
 320         ) > $@
 321 
 322 jvmti.make: $(BUILDTREE_MAKE)
 323         @echo Creating $@ ...
 324         $(QUIETLY) ( \
 325         $(BUILDTREE_COMMENT); \
 326         echo; \
 327         echo include flags.make; \
 328         echo; \
 329         echo "include \$$(GAMMADIR)/make/$(OS_FAMILY)/makefiles/$(@F)"; \
 330         ) > $@
 331 
 332 trace.make: $(BUILDTREE_MAKE)
 333         @echo Creating $@ ...
 334         $(QUIETLY) ( \
 335         $(BUILDTREE_COMMENT); \
 336         echo; \
 337         echo include flags.make; \
 338         echo; \
 339         echo "include \$$(GAMMADIR)/make/$(OS_FAMILY)/makefiles/$(@F)"; \
 340         ) > $@
 341 
 342 sa.make: $(BUILDTREE_MAKE)
 343         @echo Creating $@ ...
 344         $(QUIETLY) ( \
 345         $(BUILDTREE_COMMENT); \
 346         echo; \
 347         echo include flags.make; \
 348         echo; \
 349         echo "include \$$(GAMMADIR)/make/$(OS_FAMILY)/makefiles/$(@F)"; \
 350         ) > $@
 351 
 352 FORCE:
 353 
 354 .PHONY:  all FORCE