1
by Michael Koch
Import upstream version 1.0~b3~svn20061109 |
1 |
<?xml version="1.0"?>
|
2 |
||
3 |
<!-- ===================================================================
|
|
4 |
||
5 |
Build file for Stylebook
|
|
6 |
||
7 |
Notes:
|
|
8 |
This is a build file for use with the Jakarta Ant java build tool.
|
|
9 |
||
10 |
Installation Instructions:
|
|
11 |
To install Ant on your system, you need to checkout the
|
|
12 |
"jakarta-tools" CVS module. Then you should place the files
|
|
13 |
- ant.jar
|
|
14 |
- projectx-tr2.jar
|
|
15 |
- javac.jar
|
|
16 |
in your classpath. (XML parser abstraction is currently in
|
|
17 |
the todo list, volunteers welcome!)
|
|
18 |
||
19 |
Build Instructions:
|
|
20 |
To build, run
|
|
21 |
||
22 |
java org.apache.tools.ant.Main
|
|
23 |
||
24 |
on the directory where this file is located.
|
|
25 |
|
|
26 |
Note: See build.bat in this directory for info on setting up your classpath
|
|
27 |
to build Stylebook. If you are using the compile2/package2 option to build
|
|
28 |
a version of Stylebook that works with Xalan-J 2, Xalan-J 2 (NOT Xalan-J 1) must be on the
|
|
29 |
classpath and an up-to-date version of Xerces-J with javax.xml.parsers must also be on the
|
|
30 |
classpath.
|
|
31 |
Donald Leslie <donald_leslie@lotus.com>
|
|
32 |
9-11-00
|
|
33 |
||
34 |
Authors:
|
|
35 |
Stefano Mazzocchi <stefano@apache.org>
|
|
36 |
||
37 |
Copyright:
|
|
38 |
Copyright (c) 1999 The Apache Software Foundation.
|
|
39 |
||
40 |
$Id: build.xml 313292 2004-12-14 15:54:50Z dims $
|
|
41 |
||
42 |
==================================================================== -->
|
|
43 |
||
44 |
<project name="Stylebook" default="package2" basedir="."> |
|
45 |
||
46 |
<target name="init"> |
|
47 |
<property name="name" value="stylebook"/> |
|
48 |
<property name="version" value="1.0-b2"/> |
|
49 |
<property name="version-xalan-2" value="1.0-b3_xalan-2"/> <!-- Version to use with Xalan-J 2 --> |
|
50 |
||
51 |
<property name="build.compiler" value="classic"/> |
|
52 |
<property name="debug" value="off"/> |
|
53 |
||
54 |
<property name="build.dir" value="./build"/> |
|
55 |
<property name="build.src" value="${build.dir}/src"/> |
|
56 |
<property name="build.dest" value="${build.dir}/classes"/> |
|
57 |
<property name="src.dir" value="./src"/> |
|
58 |
<property name="bin.dir" value="./bin"/> |
|
59 |
</target>
|
|
60 |
||
61 |
<target name="prepare" depends="init"> |
|
62 |
<mkdir dir="${build.dir}"/> |
|
63 |
<mkdir dir="${build.src}"/> |
|
64 |
<mkdir dir="${build.dest}"/> |
|
65 |
<copy todir="${build.src}"> |
|
66 |
<fileset dir="${src.dir}"/> |
|
67 |
</copy>
|
|
68 |
</target>
|
|
69 |
||
70 |
<!-- If compiling version to run with Xalan-J 1, must not include Xalan2Processor in the compile.
|
|
71 |
If compiling version to run with Xalan-J 2, must not include XalanProcessor in the compile. -->
|
|
72 |
||
73 |
<target name="compile" depends="prepare"> |
|
74 |
<javac srcdir="${build.src}" excludes="org/apache/stylebook/processors/Xalan2Processor.java" destdir="${build.dest}" classpath="${classpath}" debug="${debug}"/> |
|
75 |
<copy todir="${build.dest}/org/apache/stylebook/data"> |
|
76 |
<fileset dir="${build.src}/org/apache/stylebook/data"/> |
|
77 |
</copy>
|
|
78 |
</target>
|
|
79 |
||
80 |
<target name="package" depends="compile"> |
|
81 |
<jar jarfile="${bin.dir}/${name}-${version}.jar" basedir="${build.dest}" includes="org/**"/> |
|
82 |
</target>
|
|
83 |
||
84 |
<!--Compile and Package to work with Xalan-J 2 -->
|
|
85 |
<target name="compile2" depends="prepare"> |
|
86 |
<javac srcdir="${src.dir}" excludes="org/apache/stylebook/processors/XalanProcessor.java" destdir="${build.dest}" debug="${debug}"> |
|
87 |
<exclude name="**/org/apache/stylebook/processors/XalanProcessor.java"/> |
|
88 |
</javac>
|
|
89 |
<copy todir="${build.dest}/org/apache/stylebook/data"> |
|
90 |
<fileset dir="${build.src}/org/apache/stylebook/data"/> |
|
91 |
</copy>
|
|
92 |
</target>
|
|
93 |
<target name="package2" depends="compile2"> |
|
94 |
<replace file="${build.dest}/org/apache/stylebook/data/engine.xml" token="XalanProcessor" value="Xalan2Processor"/> |
|
95 |
<jar jarfile="${bin.dir}/${name}-${version-xalan-2}.jar" basedir="${build.dest}" includes="org/**"/> |
|
96 |
</target>
|
|
97 |
||
98 |
<target name="clean"> |
|
99 |
<deltree dir="${build.dir}"/> |
|
100 |
</target>
|
|
101 |
||
102 |
</project>
|