1
0
Fork 0
mirror of https://github.com/eclipse-cdt/cdt synced 2025-08-16 04:35:45 +02:00
cdt/rse/doc/org.eclipse.rse.doc.isv/buildDoc.xml

171 lines
6.8 KiB
XML
Raw Normal View History

2009-05-14 08:19:13 +00:00
<?xml version="1.0" encoding="UTF-8"?> <!--
Copyright (c) 2005, 2007 IBM Corporation and others.
All rights reserved. This program and the accompanying materials
are made available under the terms of the Eclipse Public License v1.0
which accompanies this distribution, and is available at
http://www.eclipse.org/legal/epl-v10.html
Contributors:
IBM Corporation - initial API and implementation
-->
<project name="RSE ISV Doc Build" default="all" basedir=".">
2006-07-27 15:03:57 +00:00
<property name="javadoc.link.location" value="${basedir}/javadoc.link.location"/>
<target name="init">
<available file="${basedir}/index" property="index.present" />
<path id="path_bootclasspath">
<fileset dir="${java.home}/lib">
<include name="*.jar"/>
</fileset>
</path>
<property name="bootclasspath" refid="path_bootclasspath"/>
<condition property="safeBaseLocation"
value="${baseLocation}"
else="${eclipse.home}">
<isset property="baseLocation"/>
</condition>
2006-07-27 15:03:57 +00:00
<delete dir="${javadoc.link.location}" />
</target>
<target name="computeClasspath" unless="javadoc.classpath">
<!-- Construct the javadoc classpath and store it in a property. -->
<echo level="info" message="Computing classpath ..."/>
<!-- Add platform dependencies required by your plug-in here.
2006-07-27 15:03:57 +00:00
Note that this pattern expects Eclipse to have
been installed into the platform directory structure, as is
the case during the build. -->
<patternset id="platform.classpath.pattern">
<include name="**/org.eclipse.core*.jar"/>
<include name="**/org.eclipse.core*/**/*.jar"/>
<include name="**/org.eclipse.compare*.jar"/>
<include name="**/org.eclipse.debug.core*.jar"/>
<include name="**/org.eclipse.debug.ui*.jar"/>
<include name="**/org.eclipse.help*.jar"/>
<include name="**/org.eclipse.search*.jar"/>
<include name="**/org.eclipse.swt*.jar"/>
<include name="**/org.eclipse.swt*/**/*.jar"/>
<include name="**/org.eclipse.ui*.jar"/>
<include name="**/org.eclipse.ui*/**/*.jar"/>
<include name="**/org.eclipse.update*.jar"/>
<include name="**/org.eclipse.update*/**/*.jar"/>
<include name="**/org.eclipse.osgi*.jar"/>
<include name="**/org.eclipse.osgi*/**/*.jar"/>
<include name="**/org.eclipse.equinox*.jar"/>
<include name="**/org.eclipse.equinox*/**/*.jar"/>
<include name="**/org.eclipse.jface*.jar"/>
<include name="**/org.eclipse.jface*/**/*.jar"/>
<include name="**/org.eclipse.jsch*.jar"/>
<include name="**/org.eclipse.text*.jar"/>
<include name="**/org.eclipse.text*/**/*.jar"/>
<include name="**/org.eclipse.team*.jar"/>
<include name="**/org.eclipse.team*/**/*.jar"/>
<include name="**/org.junit*.jar"/>
<include name="**/org.junit*/**/*.jar"/>
<include name="**/com.ibm.icu*.jar"/>
<include name="**/com.jcraft.jsch*.jar"/>
</patternset>
<pathconvert property="javadoc.classpath">
<path>
<fileset dir="${safeBaseLocation}">
<patternset refid="platform.classpath.pattern"/>
</fileset>
</path>
</pathconvert>
<echo level="info" message="Done computing classpath."/>
2007-04-02 15:58:38 +00:00
<echo level="info" message="Bootclasspath is: ${bootclasspath}"/>
2006-07-27 15:03:57 +00:00
<echo level="debug" message="Classpath is: ${javadoc.classpath}"/>
</target>
<target name="extractLinks">
<mkdir dir="${javadoc.link.location}"/>
<patternset id="package.list">
<include name="**/package-list"/>
</patternset>
<!-- We only need the package-list files out of these -->
<unzip dest="${javadoc.link.location}/platform/">
<patternset refid="package.list"/>
<fileset dir="${safeBaseLocation}/plugins">
<include name="org.eclipse.platform.doc.isv*.jar"/>
</fileset>
</unzip>
</target>
<target name="all" depends="init" unless="index.present">
<antcall target="convertSchemaToHtml" />
<antcall target="generateJavadoc" />
<antcall target="build.index" />
</target>
<target name="build.index" description="Builds search index for the plug-in: org.eclipse.rse.doc.isv" if="eclipse.running">
<help.buildHelpIndex manifest="${basedir}/plugin.xml" destination="${basedir}" />
</target>
<target name="convertSchemaToHtml" if="eclipse.running">
<property name="dest" value="reference/extension-points" />
2006-07-27 15:03:57 +00:00
<record name="${basedir}/temp.convert.txt" action="start" />
<pde.convertSchemaToHTML manifest="../org.eclipse.rse.core/plugin.xml" destination="${dest}" />
<pde.convertSchemaToHTML manifest="../org.eclipse.rse.services/plugin.xml" destination="${dest}" />
<pde.convertSchemaToHTML manifest="../org.eclipse.rse.subsystems.files.core/plugin.xml" destination="${dest}" />
<pde.convertSchemaToHTML manifest="../org.eclipse.rse.subsystems.files.ftp/plugin.xml" destination="${dest}" />
<pde.convertSchemaToHTML manifest="../org.eclipse.rse.ui/plugin.xml" destination="${dest}" />
2006-07-27 15:03:57 +00:00
<record name="${basedir}/temp.convert.txt" action="stop" />
</target>
<target name="getJavadocPath">
<available file="${java.home}/../bin/javadoc.exe" property="javadoc" value="${java.home}/../bin/javadoc.exe" />
<available file="${java.home}/../bin/javadoc" property="javadoc" value="${java.home}/../bin/javadoc" />
<available file="/usr/bin/javadoc" property="javadoc" value="/usr/bin/javadoc" />
<available file="/shared/dsdp/tm/ibm-java2-ppc64-50/bin/javadoc" property="javadoc" value="/shared/dsdp/tm/ibm-java2-ppc64-50/bin/javadoc" />
</target>
2006-07-27 15:03:57 +00:00
<target name="generateJavadoc" depends="getJavadocPath,extractLinks,computeClasspath" if="javadoc">
<property name="optionsFile" value="temp.options.txt" />
<copy file="options.txt" tofile="${optionsFile}" overwrite="true" />
<condition property="argsListDelimiter" value=":">
<os family="unix" />
</condition>
<condition property="argsListDelimiter" value=";">
<os family="windows" />
</condition>
<replaceregexp file="${basedir}/${optionsFile}" flags="g" match="(\r\n?|\n);" replace="${argsListDelimiter}" />
<replace file="${basedir}/${optionsFile}" token="@rt@" value="${bootclasspath}" />
<replace file="${basedir}/${optionsFile}" token="@cp@" value="${javadoc.classpath}" />
<replace file="${basedir}/${optionsFile}" token="@baseLocation@" value="${safeBaseLocation}" />
2006-07-27 15:03:57 +00:00
<replace file="${basedir}/${optionsFile}" token="@javadoc.link.location@" value="${javadoc.link.location}" />
<!--scrub isv plugin directories of any preexisting api doc content-->
<delete dir="reference/api" />
<mkdir dir="reference/api" />
<echo message="sep = ${argsListDelimiter}"/>
<echo message="javadoc = ${javadoc}"/>
<exec dir="." executable="${javadoc}" output="temp.bin.log" resultproperty="javadocResult">
<arg line="@${basedir}/${optionsFile} -J-Xmx1000M" />
</exec>
<echo message="javadoc result = ${javadocResult}"/>
</target>
</project>