Source

main-silver / spi.debugger.ui / build.xml

<?xml version='1.0' encoding='ISO-8859-1' ?>
<!--
                Sun Public License Notice

The contents of this file are subject to the Sun Public License
Version 1.0 (the "License"). You may not use this file except in
compliance with the License. A copy of the License is available at
http://www.sun.com/

The Original Code is NetBeans. The Initial Developer of the Original
Code is Sun Microsystems, Inc. Portions Copyright 1997-2002 Sun
Microsystems, Inc. All Rights Reserved.
-->

<project name="debuggercore" default="netbeans" basedir=".">

  <property name="nbm_alias" value="nb_ide"/>
  <property name="homepage.base" value="netbeans.org"/>
  <property name="dist.base" value="www.netbeans.org/download/nbms/40"/>
  <property name="license.file" value="../nbbuild/standard-nbm-license.txt"/>

  <taskdef name="makenbm" classname="org.netbeans.nbbuild.MakeNBM" classpath="../nbbuild/nbantext.jar"/>
  <taskdef name="genlist" classname="org.netbeans.nbbuild.MakeListOfNBM" classpath="../nbbuild/nbantext.jar"/>

  <target name="setup-jdkhome-1">
    <!-- Note: user-configured -Djavahome=... will always override this: -->
    <property name="javahome" location="${java.home}"/>
    <available property="javahome-valid" file="${javahome}/lib/tools.jar"/>
  </target>
  <target name="setup-jdkhome-2" depends="setup-jdkhome-1" if="javahome-valid">
    <property name="jdkhome" value="${javahome}"/>
    <property name="jdkhome-valid" value="true"/>
  </target>
  <target name="setup-jdkhome-3" depends="setup-jdkhome-1" unless="javahome-valid">
    <property name="jdkhome" location="${javahome}/.."/>
    <available property="jdkhome-valid" file="${jdkhome}/lib/tools.jar"/>
  </target>
  <target name="setup-jdkhome" depends="setup-jdkhome-2,setup-jdkhome-3" unless="jdkhome-valid">
    <fail message="No tools.jar found in ${javahome}! Set -Djavahome=... as needed."/>
  </target>
  
  <target name="compile" depends="setup-jdkhome">
    <javac srcdir="src" destdir="src" deprecation="${build.compiler.deprecation}" debug="${build.compiler.debug}">
      <classpath>
	<pathelement location="../openide/openide-13javac-workaround.jar"/>
        <pathelement location="${jdkhome}/lib/tools.jar"/>
        <pathelement location="../openide/netbeans/lib/openide.jar"/>
        <pathelement location="../openide/deprecated/netbeans/modules/autoload/openide-deprecated.jar"/> <!-- XXX -->
        <pathelement location="../java/srcmodel/netbeans/modules/autoload/java-src-model.jar"/>
        <pathelement location="../openide/compiler/netbeans/modules/autoload/openide-compiler.jar"/>
        <pathelement location="../openide/execution/netbeans/modules/autoload/openide-execution.jar"/>
        <pathelement location="../openide/io/netbeans/modules/autoload/openide-io.jar"/>
      </classpath>
    </javac>
  </target>
  <target name="jars" depends="compile">
    <mkdir dir="netbeans/modules/autoload"/>
    <filter token="BUILD_NUMBER_SUBST" value="${buildnumber}"/>
    <copy file="manifest.mf" tofile="manifest-subst.mf" filtering="on"/>
    <taskdef name="locjar" classname="org.netbeans.nbbuild.LocalizedJar" classpath="../nbbuild/nbantext.jar"/>
    <locjar jarfile="netbeans/modules/autoload/debuggerCore.jar"
            manifest="manifest-subst.mf"
            basedir="src"
	    excludesfile="../nbbuild/standard-jar-excludes.txt"
	    compress="false">
      <locale name="ja"/>
    </locjar>
  </target>

   
  <target name="netbeans" depends="jars">
    <genlist targetname="nbm" outputfiledir="netbeans"/>
  </target>

  <target name="nbm" depends="netbeans">
    <makenbm file="debuggercore.nbm"
             topdir="."
             module="netbeans/modules/autoload/debuggerCore.jar"
	     homepage="http://debuggercore.${homepage.base}/"
	     distribution="http://${dist.base}/debuggercore.nbm">
      <license file="${license.file}"/>
      <signature keystore="${keystore}" storepass="${storepass}" alias="${nbm_alias}"/>
    </makenbm>
  </target>
  <target name="clean">
    <delete>
      <fileset dir="src">
        <include name="**/*.class"/>
      </fileset>
    </delete>
    <delete file="manifest-subst.mf"/>
    <delete file="debuggercore.nbm"/>
    <delete dir="netbeans"/>
    <delete dir="javadoc"/>
    <delete dir="Info"/>
  </target>

  <target name="javadoc" depends="setup-jdkhome" description="Build debuggercore module API documentation.">
    <tstamp/>
    <property name="apis-footer" value="&lt;font size=-2 color=gray&gt;Built on ${TODAY}.&amp;nbsp;&amp;nbsp;|&amp;nbsp;&amp;nbsp;Portions Copyright 1997-2002 Sun Microsystems, Inc. All rights reserved.&lt;/font&gt;"/>
    <echo message="Build debuggercore module API documentation..."/>
    <mkdir dir="javadoc"/>
    <javadoc destdir="javadoc"
             packagenames="org.netbeans.modules.debugger,org.netbeans.modules.debugger.delegator,org.netbeans.modules.debugger.multisession,org.netbeans.modules.debugger.support,org.netbeans.modules.debugger.support.actions,org.netbeans.modules.debugger.support.java,org.netbeans.modules.debugger.support.java.nodes,org.netbeans.modules.debugger.support.nodes,org.netbeans.modules.debugger.support.util"
             doctitle="NetBeans debuggercore module APIs"
             windowtitle="NetBeans debuggercore module APIs"
             bottom="${apis-footer}"
             use="true"
             splitindex="true"
             author="false"
             version="false"
             maxmemory="384m"
    >
      <sourcepath>
        <pathelement location="src"/>
      </sourcepath>
      <classpath>
        <!-- this classpath probably should be the same as for compilation -->
	<pathelement location="../openide/openide-13javac-workaround.jar"/>
        <pathelement location="${jdkhome}/lib/tools.jar"/>
        <fileset dir="../openide/netbeans/lib">
          <include name="openide*.jar" />
        </fileset>
	<pathelement location="../debuggercore/netbeans/modules/autoload/debuggerCore.jar"/>
      </classpath>
    </javadoc>    
  </target>

</project>