Path: blob/master/debugtools/DDR_VM/generate-ddr.xml
5986 views
<!--1Copyright (c) 2017, 2018 IBM Corp. and others23This program and the accompanying materials are made available under4the terms of the Eclipse Public License 2.0 which accompanies this5distribution and is available at https://www.eclipse.org/legal/epl-2.0/6or the Apache License, Version 2.0 which accompanies this distribution and7is available at https://www.apache.org/licenses/LICENSE-2.0.89This Source Code may also be made available under the following10Secondary Licenses when the conditions for such availability set11forth in the Eclipse Public License, v. 2.0 are satisfied: GNU12General Public License, version 2 with the GNU Classpath13Exception [1] and GNU General Public License, version 2 with the14OpenJDK Assembly Exception [2].1516[1] https://www.gnu.org/software/classpath/license.html17[2] http://openjdk.java.net/legal/assembly-exception.html1819SPDX-License-Identifier: EPL-2.0 OR Apache-2.0 OR GPL-2.0 WITH Classpath-exception-2.0 OR LicenseRef-GPL-2.0 WITH Assembly-exception20-->2122<project name="generate-ddr" default="generate-all" basedir=".">2324<target name="-init-for-eclipse" if="eclipse.running">25<eclipse.convertPath property="DDR_Artifacts.loc" resourcepath="/DDR_Artifacts" />26<eclipse.convertPath property="DDR_VM.loc" resourcepath="/DDR_VM" />27</target>2829<target name="-init-no-eclipse" unless="eclipse.running">30<fail message="DDR_Artifacts.loc must be defined." unless="DDR_Artifacts.loc" />31<fail message="DDR_VM.loc must be defined." unless="DDR_VM.loc" />3233<!-- Refresh does nothing when not running under eclipse. -->34<macrodef name="eclipse.refreshLocal">35<attribute name="resource" />36<sequential />37</macrodef>38</target>3940<target name="-init" depends="-init-for-eclipse, -init-no-eclipse">41<path id="tools.class.path">42<pathelement path="${DDR_VM.loc}/bin" />43</path>44</target>4546<target name="generate-all" depends="-init">47<generate-package version="29" />48</target>4950<macrodef name="generate-package">51<attribute name="version" />52<attribute name="superset" default="superset.ibuild.dat" />53<sequential>54<generate-structure version="@{version}" superset="@{superset}" />5556<!--57Refresh now so eclipse can begin compiling the structure stubs which58are required by the pointer types we're about to generate.59-->60<eclipse.refreshLocal resource="/DDR_VM" />6162<generate-pointers version="@{version}" superset="@{superset}" />6364<!-- Refresh again so eclipse can see the final content. -->65<eclipse.refreshLocal resource="/DDR_VM" />66</sequential>67</macrodef>6869<macrodef name="generate-pointers">70<attribute name="version" />71<attribute name="superset" />72<sequential>73<java classname="com.ibm.j9ddr.tools.PointerGenerator" classpathref="tools.class.path" fork="true">74<jvmarg value="-Dfile.encoding=UTF-8" />7576<arg value="-o" />77<arg value="${DDR_VM.loc}/src" />7879<arg value="-p" />80<arg value="com.ibm.j9ddr.vm@{version}.pointer.generated" />8182<arg value="-f" />83<arg value="${DDR_Artifacts.loc}/supersets/@{version}/" />8485<arg value="-s" />86<arg value="@{superset}" />8788<arg value="-v" />89<arg value="@{version}" />9091<arg value="-l" />92<arg value="true" />93</java>94</sequential>95</macrodef>9697<macrodef name="generate-structure">98<attribute name="version" />99<attribute name="superset" />100<sequential>101<java classname="com.ibm.j9ddr.tools.StructureStubGenerator" classpathref="tools.class.path" fork="true">102<jvmarg value="-Dfile.encoding=UTF-8" />103104<arg value="-o" />105<arg value="${DDR_VM.loc}/src" />106107<arg value="-p" />108<arg value="com.ibm.j9ddr.vm@{version}.structure" />109110<arg value="-f" />111<arg value="${DDR_Artifacts.loc}/supersets/@{version}/" />112113<arg value="-s" />114<arg value="@{superset}" />115116<arg value="-l" />117<arg value="true" />118</java>119</sequential>120</macrodef>121122</project>123124125