Author: bdube
Date: Mon Jul 30 19:32:15 2007
New Revision: 561216
URL: http://svn.apache.org/viewvc?view=rev&rev=561216
Log:
Issue: FOR-1033
Fix build regarding log4j. Contributed by Vincent Siveton.
See also FOR-1025.
Added:
forrest/trunk/whiteboard/forrestdoc/src/resources/log4j.properties (with
props)
Modified:
forrest/trunk/whiteboard/forrestdoc/build.properties
forrest/trunk/whiteboard/forrestdoc/build.xml
forrest/trunk/whiteboard/forrestdoc/core.xml
forrest/trunk/whiteboard/forrestdoc/src/ant.xml
forrest/trunk/whiteboard/forrestdoc/src/java.xml
forrest/trunk/whiteboard/forrestdoc/src/js.xml
Modified: forrest/trunk/whiteboard/forrestdoc/build.properties
URL:
http://svn.apache.org/viewvc/forrest/trunk/whiteboard/forrestdoc/build.properties?view=diff&rev=561216&r1=561215&r2=561216
==============================================================================
--- forrest/trunk/whiteboard/forrestdoc/build.properties (original)
+++ forrest/trunk/whiteboard/forrestdoc/build.properties Mon Jul 30 19:32:15
2007
@@ -15,15 +15,13 @@
version=0.1-dev
src.dir=./src/java
-ant.src.dir=./src/ant
resources.dir=./src/resources
build.dir=./build
-ant.build.dir=./build/tools/ant
dist.dir=./dist
lib.dir=./lib
build.classes.dir=${build.dir}/classes
-
+
ws.dir=../../..
jar.name=xml-forrest-scratchpad-forrestdoc
Modified: forrest/trunk/whiteboard/forrestdoc/build.xml
URL:
http://svn.apache.org/viewvc/forrest/trunk/whiteboard/forrestdoc/build.xml?view=diff&rev=561216&r1=561215&r2=561216
==============================================================================
--- forrest/trunk/whiteboard/forrestdoc/build.xml (original)
+++ forrest/trunk/whiteboard/forrestdoc/build.xml Mon Jul 30 19:32:15 2007
@@ -15,59 +15,88 @@
See the License for the specific language governing permissions and
limitations under the License.
-->
-<project
- name="forrestdoc" default="project" basedir=".">
-<!-- init -->
+
+<!-- ====================================================================== -->
+<!-- Ant build file (http://ant.apache.org/) for Ant 1.6.5 or above. -->
+<!-- ====================================================================== -->
+
+<project name="forrestdoc" default="project" basedir=".">
+
+ <!-- Init -->
<tstamp />
+
<property file="build.properties"/>
+
+ <!-- Get specific lib TODO -->
+ <mkdir dir="${build.dir}"/>
+
+ <get src="http://repo1.maven.org/maven2/junit/junit/3.8.1/junit-3.8.1.jar"
+ dest="${build.dir}/junit-3.8.1.jar"
+ usetimestamp="true"
+ ignoreerrors="true"/>
+
<path id="lib.classpath">
- <fileset dir="${lib.dir}">
+ <fileset dir="${lib.dir}">
<include name="*.jar" />
</fileset>
+ <fileset dir="${basedir}/../../lib/core">
+ <include name="log4j-1.2.13.jar" />
+ </fileset>
+ <fileset dir="${build.dir}">
+ <include name="junit-3.8.1.jar" />
+ </fileset>
<fileset dir="${ant.home}/lib">
<include name="*.jar" />
</fileset>
+ <fileset dir="${java.home}/../lib">
+ <include name="tools.jar" />
+ </fileset>
</path>
+
<path id="task.classpath">
<path refid="lib.classpath"/>
<pathelement path="${build.classes.dir}"/>
- <pathelement path="${ant.build.dir}"/>
</path>
- <mkdir dir="${ant.build.dir}" />
- <javac srcdir="${ant.src.dir}"
- debug="true"
- destdir="${ant.build.dir}"
- classpathref="lib.classpath" />
+
<taskdef resource="net/sf/antcontrib/antcontrib.properties"/>
- <taskdef name="extendedpathconvert"
classname="org.apache.forrest.tools.taskdefs.PathConvert"
classpathref="task.classpath"/>
-<!-- Targets -->
+
+ <!-- Targets -->
<target name="compile"
- description="Compile the java code from ${src} into ${target}">
+ description="Compile the java code from ${src} into ${target}">
<mkdir dir="${build.classes.dir}" />
<javac srcdir="${src.dir}"
- debug="true"
- destdir="${build.classes.dir}"
- classpathref="lib.classpath" />
+ debug="true"
+ destdir="${build.classes.dir}"
+ classpathref="lib.classpath" />
+
+ <copy todir="${build.classes.dir}">
+ <fileset dir="${resources.dir}" casesensitive="yes"/>
+ </copy>
</target>
+
<target name="jar" depends="compile"
- description="Put everything in ${target} into the ${jar.name}.jar
file">
+ description="Put everything in ${target} into the ${jar.name}.jar
file">
<mkdir dir="${dist.dir}" />
<jar jarfile="${dist.dir}/${jar.name}-${version}.jar"
basedir="${build.classes.dir}" />
<jar jarfile="${dist.dir}/${jar.name}-anttools-${version}.jar"
basedir="${ant.build.dir}" />
</target>
+
<target name="clean"
- description="Delete the ${target} and ${dist} directory trees">
+ description="Delete the ${target} and ${dist} directory trees">
<delete dir="${build.dir}" />
<delete dir="${dist.dir}" />
</target>
- <target name="all"
- description="test this project"
- depends="project"></target>
- <target name="project" depends="compile"
- description="create all possible docs for this project">
- <echo>START</echo>
+
+ <target name="all"
+ description="test this project"
+ depends="project"/>
+
+ <target name="project"
+ depends="compile"
+ description="Create all possible docs for this project">
+ <echo>start</echo>
<trycatch property="foo" reference="bar">
<try>
<ant antfile="core.xml" dir="." target="project"
@@ -81,13 +110,15 @@
</finally>
</trycatch>
</target>
-<!-- driver targets -->
- <target name="ws" depends="compile"
- description="create all possible docs for this workspace">
+
+ <!-- driver targets -->
+ <target name="ws"
+ depends="compile"
+ description="Create all possible docs for this workspace">
<property name="resolved.ws.dir" location="${ws.dir}"/>
-<!--
- <property name="ws.build.dir" location="${ws.dir}/build/forrestdoc"/>
- <property name="ws.temp.dir" location="${ws.dir}/build/temp"/>
+ <!--
+ <property name="ws.build.dir" location="${ws.dir}/build/forrestdoc"/>
+ <property name="ws.temp.dir" location="${ws.dir}/build/temp"/>
-->
<property name="ws.build.dir" location="./build/ws/forrestdoc"/>
<property name="ws.temp.dir" location="./build/temp/ws"/>
@@ -102,9 +133,9 @@
<extendedpathconvert pathsep="," type="xml" file="${ws.temp.dir}/dirs.xml"
refid="ws.project.dirs">
<map from="${resolved.ws.dir}" to=""/>
</extendedpathconvert>
- <xslt in="${ws.temp.dir}/dirs.xml"
+ <xslt in="${ws.temp.dir}/dirs.xml"
out="${ws.build.dir}/projects.html"
style="${resources.dir}/ws/dir2projects.xsl" />
- <xslt in="${ws.temp.dir}/dirs.xml"
+ <xslt in="${ws.temp.dir}/dirs.xml"
out="${ws.build.dir}/projects-summary.html"
style="${resources.dir}/ws/dir2projects-summary.xsl" />
<copy file="${resources.dir}/ws/index.html" todir="${ws.build.dir}"/>
<copy file="${resources.dir}/ws/styles.css" todir="${ws.build.dir}"/>
@@ -118,8 +149,8 @@
<try>
<ant antfile="core.xml" dir="." target="project"
inheritAll="true" inheritRefs="true">
- <property name="project.dir" value="@{current.project.dir}"/>
- <property name="target.dir" value="${ws.build.dir}"/>
+ <property name="project.dir" value="@{current.project.dir}"/>
+ <property name="target.dir" value="${ws.build.dir}"/>
</ant>
</try>
<catch>
Modified: forrest/trunk/whiteboard/forrestdoc/core.xml
URL:
http://svn.apache.org/viewvc/forrest/trunk/whiteboard/forrestdoc/core.xml?view=diff&rev=561216&r1=561215&r2=561216
==============================================================================
--- forrest/trunk/whiteboard/forrestdoc/core.xml (original)
+++ forrest/trunk/whiteboard/forrestdoc/core.xml Mon Jul 30 19:32:15 2007
@@ -15,20 +15,26 @@
See the License for the specific language governing permissions and
limitations under the License.
-->
-<project
- name="forrestdoc" default="dist" basedir=".">
- <property name="project.dir" location="."/>
- <property name="target.dir" location="${project.dir}/build/forrestdoc"/>
- <basename property="project.dirname" file="${project.dir}"/>
- <property name="project.target.dir"
location="${target.dir}/${project.dirname}"/>
+
+<project name="forrestdoc" default="dist" basedir=".">
+
+ <property name="project.dir" location="."/>
+ <property name="target.dir" location="${project.dir}/build/forrestdoc"/>
+
+ <basename property="project.dirname" file="${project.dir}"/>
+
+ <property name="project.target.dir"
location="${target.dir}/${project.dirname}"/>
+
<echo>Using Project dir: ${project.dir}</echo>
<echo>Using Target dir: ${project.target.dir}</echo>
+
<import file="./src/java.xml"/>
<import file="./src/ant.xml"/>
<import file="./src/js.xml"/>
- <target name="project"
- description="create all possible docs for this project"
- depends="javasrc, jsdoc, xml, uml, javadoc, vizant">
+
+ <target name="project"
+ description="create all possible docs for this project"
+ depends="javasrc, jsdoc, xml, uml, javadoc, vizant">
<copy todir="${project.target.dir}">
<fileset dir="${resources.dir}/common" casesensitive="yes"/>
</copy>
Modified: forrest/trunk/whiteboard/forrestdoc/src/ant.xml
URL:
http://svn.apache.org/viewvc/forrest/trunk/whiteboard/forrestdoc/src/ant.xml?view=diff&rev=561216&r1=561215&r2=561216
==============================================================================
--- forrest/trunk/whiteboard/forrestdoc/src/ant.xml (original)
+++ forrest/trunk/whiteboard/forrestdoc/src/ant.xml Mon Jul 30 19:32:15 2007
@@ -15,59 +15,67 @@
See the License for the specific language governing permissions and
limitations under the License.
-->
-<project
- name="forrestdoc-ant" default="dist" basedir=".">
+
+<project name="forrestdoc-ant" default="dist" basedir=".">
+
<condition property="ant.build.available">
<available file="${project.dir}/build.xml"/>
</condition>
- <echo>ant buildfine available: ${ant.build.available}</echo>
+
+ <echo>Ant buildfine available: ${ant.build.available}</echo>
+
<property name="target.vizant.dir" location="${project.target.dir}/vizant"
/>
+
<target name="vizant" depends="runvizant, antxml2formats"
if="ant.build.available"/>
+
<target name="runvizant" if="ant.build.available">
<mkdir dir="${target.vizant.dir}" />
<taskdef name="vizant"
classname="org.apache.forrest.forrestdoc.ant.doc.Vizant">
<classpath refid="task.classpath"/>
</taskdef>
- <vizant antfile="${project.dir}/build.xml"
- outfile="${target.vizant.dir}/buildgraph.xml"
- uniqueref="true">
-<!--
- <attrstmt type="graph">
- <attr name="ranksep" value="1.0"/>
- <attr name="nodesep" value="0.5"/>
- </attrstmt>
-
- <attrstmt type="node">
- <attr name="URL" value="javascript:alert('\N');"/>
- <attr name="color" value="grey90"/>
- <attr name="style" value="filled"/>
- </attrstmt>
+ <vizant antfile="${project.dir}/build.xml"
+ outfile="${target.vizant.dir}/buildgraph.xml"
+ uniqueref="true">
+ <!--
+ <attrstmt type="graph">
+ <attr name="ranksep" value="1.0"/>
+ <attr name="nodesep" value="0.5"/>
+ </attrstmt>
- <attrstmt type="edge">
- <attr name="color" value="grey70"/>
- </attrstmt>
+ <attrstmt type="node">
+ <attr name="URL" value="javascript:alert('\N');"/>
+ <attr name="color" value="grey90"/>
+ <attr name="style" value="filled"/>
+ </attrstmt>
- <attrstmt type="edge.antcall">
- <attr name="label" value="antcall"/>
- <attr name="fontcolor" value="gray70"/>
- <attr name="fontsize" value="9"/>
- </attrstmt>
+ <attrstmt type="edge">
+ <attr name="color" value="grey70"/>
+ </attrstmt>
+
+ <attrstmt type="edge.antcall">
+ <attr name="label" value="antcall"/>
+ <attr name="fontcolor" value="gray70"/>
+ <attr name="fontsize" value="9"/>
+ </attrstmt>
+
+ <attrstmt type="node.default">
+ <attr name="color" value="pink"/>
+ </attrstmt>
- <attrstmt type="node.default">
- <attr name="color" value="pink"/>
+ <subgraph>
+ <attrstmt type="graph">
+ <attr name="style" value="filled"/>
+ <attr name="color" value="grey95"/>
</attrstmt>
-
- <subgraph>
- <attrstmt type="graph">
- <attr name="style" value="filled"/>
- <attr name="color" value="grey95"/>
- </attrstmt>
- </subgraph>
- -->
+ </subgraph>
+ -->
</vizant>
</target>
+
<target name="antxml2formats" if="ant.build.available">
- <xslt in="${target.vizant.dir}/buildgraph.xml"
out="${target.vizant.dir}/target.dot"
style="${resources.dir}/vizant/xml2dot.xsl" />
+ <xslt in="${target.vizant.dir}/buildgraph.xml"
+ out="${target.vizant.dir}/target.dot"
+ style="${resources.dir}/vizant/xml2dot.xsl" />
<antcall target="dot">
<param name="dot.source" value="${target.vizant.dir}/target.dot"/>
<param name="dot.dest" value="${target.vizant.dir}/vizant"/>
@@ -77,9 +85,13 @@
<param name="dot.source" value="${target.vizant.dir}/target.dot"/>
<param name="dot.dest" value="${target.vizant.dir}/vizant"/>
</antcall>
- <xslt in="${target.vizant.dir}/buildgraph.xml"
out="${target.vizant.dir}/target.html"
style="${resources.dir}/vizant/xml2html.xsl" />
- <xslt in="${target.vizant.dir}/buildgraph.xml"
out="${target.vizant.dir}/buildtg.xml"
style="${resources.dir}/vizant/xml2tg.xsl" />
- <copy file="${target.vizant.dir}/buildtg.xml"
tofile="${target.vizant.dir}/InitialXML._xml"/>
+ <xslt in="${target.vizant.dir}/buildgraph.xml"
+ out="${target.vizant.dir}/target.html"
+ style="${resources.dir}/vizant/xml2html.xsl" />
+ <xslt in="${target.vizant.dir}/buildgraph.xml"
+ out="${target.vizant.dir}/buildtg.xml"
style="${resources.dir}/vizant/xml2tg.xsl" />
+ <copy file="${target.vizant.dir}/buildtg.xml"
+ tofile="${target.vizant.dir}/InitialXML._xml"/>
<copy todir="${target.vizant.dir}">
<fileset dir="${resources.dir}/touchgraph" casesensitive="yes"/>
</copy>
@@ -87,6 +99,7 @@
<fileset dir="${resources.dir}/vizant" casesensitive="yes"/>
</copy>
</target>
+
<target name="tg" if="ant.build.available">
<java classname="com.touchgraph.linkbrowser.TGLinkBrowser" fork="yes">
<arg value="${target.vizant.dir}/buildtg.xml"/>
Modified: forrest/trunk/whiteboard/forrestdoc/src/java.xml
URL:
http://svn.apache.org/viewvc/forrest/trunk/whiteboard/forrestdoc/src/java.xml?view=diff&rev=561216&r1=561215&r2=561216
==============================================================================
--- forrest/trunk/whiteboard/forrestdoc/src/java.xml (original)
+++ forrest/trunk/whiteboard/forrestdoc/src/java.xml Mon Jul 30 19:32:15 2007
@@ -15,32 +15,36 @@
See the License for the specific language governing permissions and
limitations under the License.
-->
+
<!-- made to be imported in the main forrestdoc build driver -->
<project name="forrestdoc-java">
+
<property name="target.javasrc.dir" location="${project.target.dir}/javasrc"
/>
<property name="target.javadoc.dir" location="${project.target.dir}/javadoc"
/>
<property name="target.xml.dir" location="${project.target.dir}/xml" />
<property name="target.dot.dir" location="${project.target.dir}/dot" />
<property name="target.uml.dir" location="${project.target.dir}/uml" />
+
<presetdef name="fjavadoc">
- <javadoc
- useexternalfile="true">
+ <javadoc useexternalfile="true">
<fileset dir="${project.dir}" defaultexcludes="yes">
<include name="**/*.java" />
</fileset>
</javadoc>
</presetdef>
+
<target name="javasrc">
<mkdir dir="${target.javasrc.dir}" />
<taskdef name="javasrc"
classname="org.apache.forrest.forrestdoc.java.src.JavaSrcTask">
<classpath refid="task.classpath"/>
</taskdef>
- <javasrc srcDir="${project.dir}"
- destDir="${target.javasrc.dir}"
+ <javasrc srcDir="${project.dir}"
+ destDir="${target.javasrc.dir}"
recurse="true"
title="${project.dirname}"
verbose="false"/>
</target>
+
<target name="clijavasrc">
<mkdir dir="${target.javasrc.dir}" />
<java classname="org.apache.forrest.forrestdoc.java.src.Pass1"
@@ -71,16 +75,19 @@
todir="${target.javasrc.dir}"
filtering="off" />
</target>
+
<target name="uml" depends="xml, xml2dot, dot">
<antcall target="dot">
<param name="dot.format" value="svg"/>
</antcall>
</target>
+
<target name="umlgraph" depends="umldoclet, dot"/>
+
<target name="umldoclet">
- <fjavadoc>
+ <fjavadoc classpathref="task.classpath">
<doclet name="org.apache.forrest.forrestdoc.java.doc.UmlDoclet"
- path="./build/classes/">
+ pathref="task.classpath">
<!-- <param name="-horizontal" value="true"/> -->
<!-- <param name="-attributes" value="true"/> -->
<!-- <param name="-operations" value="true"/> -->
@@ -90,34 +97,44 @@
</doclet>
</fjavadoc>
</target>
+
<target name="javadoc">
<mkdir dir="${target.javadoc.dir}" />
- <fjavadoc destDir="${target.javadoc.dir}"
- author = "true"
- version="true">
+ <fjavadoc classpathref="task.classpath"
+ destDir="${target.javadoc.dir}"
+ author = "true"
+ version="true">
<!-- <doctitle><![CDATA[<h1>Test</h1>]]></doctitle>
<header><![CDATA[<h2>header</h2>]]></header>
- <footer><![CDATA[<h3>footer</h3>]]></footer>
+ <footer><![CDATA[<h3>footer</h3>]]></footer>
<bottom><![CDATA[<i>Copyright © 2000 Dummy Corp. All Rights
Reserved.</i>]]></bottom>
-->
<tag name="todo" scope="all" description="To do:" /><link
href="http://developer.java.sun.com/developer/products/xml/docs/api/"/>
</fjavadoc>
</target>
+
<target name="xml">
<mkdir dir="${target.xml.dir}" />
- <fjavadoc>
+ <fjavadoc classpathref="task.classpath">
<doclet name="org.apache.forrest.forrestdoc.java.doc.XMLDoclet"
- path="./build/classes/">
+ pathref="task.classpath">
<!-- <param name="-foo" value="foovalue"/>
<param name="-bar" value="barvalue"/> -->
</doclet>
</fjavadoc>
<move file="simple.xml" tofile="${target.xml.dir}/xmldocs.xml"/>
</target>
+
<target name="xml2dot">
- <copy file="${resources.dir}/javadoc/javadoc-v04draft.dtd"
todir="${target.xml.dir}" filtering="off" />
- <xslt force="true" in="${target.xml.dir}/xmldocs.xml"
out="${target.dot.dir}/graph.dot" style="${resources.dir}/javadoc/xml2dot.xsl"/>
+ <copy file="${resources.dir}/javadoc/javadoc-v04draft.dtd"
+ todir="${target.xml.dir}"
+ filtering="off" />
+ <xslt force="true"
+ in="${target.xml.dir}/xmldocs.xml"
+ out="${target.dot.dir}/graph.dot"
+ style="${resources.dir}/javadoc/xml2dot.xsl"/>
</target>
+
<target name="dot">
<mkdir dir="${target.uml.dir}" />
<property name="dot.format" value="png"/>
Modified: forrest/trunk/whiteboard/forrestdoc/src/js.xml
URL:
http://svn.apache.org/viewvc/forrest/trunk/whiteboard/forrestdoc/src/js.xml?view=diff&rev=561216&r1=561215&r2=561216
==============================================================================
--- forrest/trunk/whiteboard/forrestdoc/src/js.xml (original)
+++ forrest/trunk/whiteboard/forrestdoc/src/js.xml Mon Jul 30 19:32:15 2007
@@ -15,12 +15,18 @@
See the License for the specific language governing permissions and
limitations under the License.
-->
-<project
- name="forrestdoc-js" default="dist" basedir=".">
+
+<project name="forrestdoc-js" default="dist" basedir=".">
+
<property name="target.jsdoc.dir" location="${project.target.dir}/jsdoc" />
+
<target name="jsdoc">
<mkdir dir="${target.jsdoc.dir}" />
- <taskdef name="jsdoc"
classname="org.apache.forrest.forrestdoc.js.doc.JSDocTask"
classpath="./build/classes/"/>
+
+ <taskdef name="jsdoc"
+ classname="org.apache.forrest.forrestdoc.js.doc.JSDocTask"
+ classpathref="task.classpath"/>
+
<jsdoc jSDir="${project.dir}" destDir="${target.jsdoc.dir}" />
</target>
</project>
Added: forrest/trunk/whiteboard/forrestdoc/src/resources/log4j.properties
URL:
http://svn.apache.org/viewvc/forrest/trunk/whiteboard/forrestdoc/src/resources/log4j.properties?view=auto&rev=561216
==============================================================================
--- forrest/trunk/whiteboard/forrestdoc/src/resources/log4j.properties (added)
+++ forrest/trunk/whiteboard/forrestdoc/src/resources/log4j.properties Mon Jul
30 19:32:15 2007
@@ -0,0 +1,25 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+
+log4j.rootCategory=INFO, stdout
+
+log4j.appender.stdout=org.apache.log4j.ConsoleAppender
+log4j.appender.stdout.layout=org.apache.log4j.PatternLayout
+log4j.appender.stdout.layout.ConversionPattern=[%5p] %m%n
+
+log4j.logger.org.apache.forrest.forrestdoc=INFO
+log4j.logger.org.apache.forrest.forrestdoc.java.src.symtab=INFO
Propchange: forrest/trunk/whiteboard/forrestdoc/src/resources/log4j.properties
------------------------------------------------------------------------------
svn:eol-style = native