6958391: add vizant support to langtools build

Fri, 04 Jun 2010 14:54:54 -0700

author
jjg
date
Fri, 04 Jun 2010 14:54:54 -0700
changeset 578
b7fc560217d3
parent 577
852d8bb356bc
child 579
d33b91f360fc

6958391: add vizant support to langtools build
Reviewed-by: mcimadamore

make/build.properties file | annotate | diff | comparison | revisions
make/build.xml file | annotate | diff | comparison | revisions
     1.1 --- a/make/build.properties	Thu Jun 03 19:56:12 2010 -0700
     1.2 +++ b/make/build.properties	Fri Jun 04 14:54:54 2010 -0700
     1.3 @@ -76,17 +76,27 @@
     1.4  javadoc.jls3.option=-tag "jls3:a:See <cite>${javadoc.jls3.cite}</cite>:"
     1.5  
     1.6  # jtreg, used to run the JDK regression tests
     1.7 +# See http://openjdk.java.net/jtreg/
     1.8  # Override this path as needed, either on the command line or in
     1.9  # one of the standard user build.properties files (see build.xml)
    1.10  
    1.11 -# jtreg.home = /opt/jtreg/3.2.2_02
    1.12 +# jtreg.home = /opt/jtreg/4.1
    1.13  
    1.14  # findbugs
    1.15 +# See http://findbugs.sourceforge.net/
    1.16  # Override this path as needed, either on the command line or in
    1.17  # one of the standard user build.properties files (see build.xml)
    1.18  
    1.19  # findbugs.home = /opt/findbugs/1.2.1
    1.20  
    1.21 +# vizant (graph visualization tool for Ant)
    1.22 +# See http://vizant.sourceforge.net/
    1.23 +# Override this path as needed, either on the command line or in
    1.24 +# one of the standard user build.properties files (see build.xml)
    1.25 +
    1.26 +# vizant.jar = /opt/vizant/0.1.2/vizant-0.1.2.jar
    1.27 +# dot = dot
    1.28 +
    1.29  #------------------------------------------------------------
    1.30  
    1.31  # The following properties define the packages for each of the tools.
     2.1 --- a/make/build.xml	Thu Jun 03 19:56:12 2010 -0700
     2.2 +++ b/make/build.xml	Fri Jun 04 14:54:54 2010 -0700
     2.3 @@ -136,6 +136,19 @@
     2.4          <echo message="import.jdk.jar: ${import.jdk.jar}"/>
     2.5          <echo message="import.jdk.src.dir: ${import.jdk.src.dir}"/>
     2.6      </target>
     2.7 +    
     2.8 +    <target name="vizant" depends="-def-vizant">
     2.9 +	<mkdir dir="${build.dir}"/>
    2.10 +	<echo message="Generating ${build.dir}/build.dot"/>
    2.11 +        <vizant antfile="${make.dir}/build.xml" outfile="${build.dir}/build.dot"/>
    2.12 +	<echo message="Generating ${build.dir}/build.png"/>
    2.13 +        <exec executable="${dot}" >
    2.14 +            <arg value="-Tpng"/>
    2.15 +            <arg value="-o"/>
    2.16 +            <arg file="${build.dir}/build.png"/>
    2.17 +            <arg file="${build.dir}/build.dot"/>
    2.18 +        </exec> 
    2.19 +    </target>
    2.20  
    2.21      <!-- Standard target to build deliverables for JDK build. -->
    2.22  
    2.23 @@ -459,6 +472,11 @@
    2.24          <check name="jtreg" property="jtreg.home" marker="lib/jtreg.jar"/>
    2.25      </target>
    2.26  
    2.27 +    <target name="-check-vizant" depends="-def-check">
    2.28 +        <check name="vizant" property="vizant.jar"/>
    2.29 +        <check name="dot" property="dot"/>
    2.30 +    </target>
    2.31 +
    2.32      <!-- Ant macro and preset defs -->
    2.33  
    2.34      <target name="-def-build-tool">
    2.35 @@ -765,12 +783,17 @@
    2.36          </macrodef>
    2.37          <property name="findbugs.defined" value="true"/>
    2.38      </target>
    2.39 +    
    2.40 +    <target name="-def-vizant" unless="vizant.defined" depends="-check-vizant">
    2.41 +	<taskdef name="vizant" classname="net.sourceforge.vizant.Vizant" classpath="${vizant.jar}"/>
    2.42 +        <property name="vizant.defined" value="true"/>
    2.43 +    </target>
    2.44  
    2.45      <target name="-def-check">
    2.46          <macrodef name="check">
    2.47              <attribute name="name"/>
    2.48              <attribute name="property"/>
    2.49 -            <attribute name="marker"/>
    2.50 +            <attribute name="marker" default=""/>
    2.51              <sequential>
    2.52                  <fail message="Cannot locate @{name}: please set @{property} to its location">
    2.53                      <condition>
    2.54 @@ -781,9 +804,14 @@
    2.55                  </fail>
    2.56                  <fail message="@{name} is not installed in ${@{property}}">
    2.57                      <condition>
    2.58 -                        <not>
    2.59 -                            <available file="${@{property}}/@{marker}"/>
    2.60 -                        </not>
    2.61 +			<and>
    2.62 +			    <not>
    2.63 +				<equals arg1="@{marker}" arg2=""/>
    2.64 +			    </not>
    2.65 +                            <not>
    2.66 +                                <available file="${@{property}}/@{marker}"/>
    2.67 +                            </not>
    2.68 +			</and>
    2.69                      </condition>
    2.70                  </fail>
    2.71              </sequential>

mercurial