Path: blob/aarch64-shenandoah-jdk8u272-b10/hotspot/make/aix/makefiles/jfr.make
32284 views
#1# Copyright (c) 2020, Oracle and/or its affiliates. All rights reserved.2# Copyright (c) 2020 SAP SE. 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 it6# under the terms of the GNU General Public License version 2 only, as7# published by the Free Software Foundation.8#9# This code is distributed in the hope that it will be useful, but WITHOUT10# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or11# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License12# version 2 for more details (a copy is included in the LICENSE file that13# accompanied this code).14#15# You should have received a copy of the GNU General Public License version16# 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 USA20# or visit www.oracle.com if you need additional information or have any21# questions.22#23#2425# This makefile (jfr.make) is included from the jfr.make in the26# build directories.27#28# It knows how to build and run the tools to generate jfr.2930include $(GAMMADIR)/make/linux/makefiles/rules.make3132# #########################################################################33# Build tools needed for the Jfr source code generation3435TOPDIR = $(shell echo `pwd`)36GENERATED = $(TOPDIR)/../generated3738JFR_TOOLS_SRCDIR := $(GAMMADIR)/src/share/vm/jfr39JFR_TOOLS_OUTPUTDIR := $(GENERATED)/tools/jfr4041JFR_OUTPUTDIR := $(GENERATED)/jfrfiles42JFR_SRCDIR := $(GAMMADIR)/src/share/vm/jfr/metadata4344METADATA_XML ?= $(JFR_SRCDIR)/metadata.xml45METADATA_XSD ?= $(JFR_SRCDIR)/metadata.xsd4647# Changing these will trigger a rebuild of generated jfr files.48JFR_DEPS += \49$(METADATA_XML) \50$(METADATA_XSD) \51#5253JfrGeneratedNames = \54jfrEventClasses.hpp \55jfrEventControl.hpp \56jfrEventIds.hpp \57jfrPeriodic.hpp \58jfrTypes.hpp5960JfrGenSource = $(JFR_TOOLS_SRCDIR)/GenerateJfrFiles.java61JfrGenClass = $(JFR_TOOLS_OUTPUTDIR)/build/tools/jfr/GenerateJfrFiles.class6263JfrGeneratedFiles = $(JfrGeneratedNames:%=$(JFR_OUTPUTDIR/%)6465.PHONY: all clean cleanall6667# #########################################################################6869all: $(JfrGeneratedFiles)7071$(JfrGenClass): $(JfrGenSource)72mkdir -p $(@D)73$(QUIETLY) $(REMOTE) $(COMPILE.JAVAC) -d $(JFR_TOOLS_OUTPUTDIR) $(JfrGenSource)7475$(JFR_OUTPUTDIR)/jfrEventClasses.hpp: $(METADATA_XML) $(METADATA_XSD) $(JfrGenClass)76$(QUIETLY) echo Generating $(@F)77mkdir -p $(@D)78$(QUIETLY) $(REMOTE) $(RUN.JAVA) -cp $(JFR_TOOLS_OUTPUTDIR) build.tools.jfr.GenerateJfrFiles $(METADATA_XML) $(METADATA_XSD) $(JFR_OUTPUTDIR)79test -f $@8081$(filter-out $(JFR_OUTPUTDIR)/jfrEventClasses.hpp, $(JfrGeneratedFiles)): $(JFR_OUTPUTDIR)/jfrEventClasses.hpp8283TARGETS += $(JFR_OUTPUTDIR)/jfrEventClasses.hpp8485# #########################################################################8687clean cleanall :88rm $(JfrGenClass) $(JfrGeneratedFiles)8990# #########################################################################91929394