source: trunk/build.xml @ 2641

Last change on this file since 2641 was 2641, checked in by Nicklas Nordborg, 16 years ago

References #351: External job server usage

The core of the job agent is now working. Still missing code for actually running the jobs. A dummy
job executor which marks the job as beeing executed allows testing of the job agent.

  • Property svn:eol-style set to native
  • Property svn:keywords set to Id
File size: 28.2 KB
Line 
1<?xml version="1.0" encoding="UTF-8"?>
2
3<!--
4    $Id: build.xml 2641 2006-09-14 10:17:01Z nicklas $
5
6    Copyright (C) 2005-2006
7    Samuel Andersson, Jari H&auml;kkinen, Nicklas Nordborg, Gregory Vincic
8
9    Files are copyright by their respective authors. The contributions
10    to files where copyright is not explicitly stated can be traced
11    with the source code revision system.
12
13    This file is part of BASE - BioArray Software Environment.
14    Available at http://base.thep.lu.se/
15
16    BASE is free software; you can redistribute it and/or modify it
17    under the terms of the GNU General Public License as published by
18    the Free Software Foundation; either version 2 of the License, or
19    (at your option) any later version.
20
21    BASE is distributed in the hope that it will be useful, but
22    WITHOUT ANY WARRANTY; without even the implied warranty of
23    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
24    General Public License for more details.
25
26    You should have received a copy of the GNU General Public License
27    along with this program; if not, write to the Free Software
28    Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
29    02111-1307, USA.
30-->
31
32<project
33  name="BASE2"
34  default="main"
35  basedir="."
36  >
37
38  <description>
39    Build file for BASE 2.0
40    Main targets:
41    main (default): build the core, plugins and Hibernate mappings
42    core: build the core and generate Hibernate mappings
43    nohibernate: build the core, but do not regenerate the Hibernate mappings
44    coreplugins: build the core plugins
45    test: build the test programs
46    web: build the web client
47    migrate: build the migration client
48    jobagent: build the job agent client
49    javadoc: generate documentation
50    package: create binary distribution
51    all: core, clients, docs
52    clean: clean up everything
53  </description>
54
55  <!-- set global properties for this build -->
56  <property name="compilerarg" value="-Xlint:unchecked" />
57  <property name="base.version" value="2.0RC2" />
58  <property environment="env" />
59 
60  <property name="src" location="src" />
61  <property name="build" location="build" />
62  <property name="dist" location="dist" />
63  <property name="dist.webinf" location="${dist}/www/WEB-INF" />
64  <property name="dist.lib" location="${dist}/www/WEB-INF/lib" />
65  <property name="dist.classes" location="${dist}/www/WEB-INF/classes" />
66  <property name="dist.bin" location="${dist}/bin" />
67  <property name="doc" location="doc" />
68  <property name="lib" location="lib" />
69  <property name="www" location="www" />
70
71  <property name="core.src" location="${src}/core" />
72  <property name="coreplugins.src" location="${src}/plugins/core" />
73  <property name="test.src" location="${src}/test" />
74  <property name="web.src" location="${src}/clients/web" />
75  <property name="migrate.src" location="${src}/clients/migrate" />
76  <property name="install.src" location="${src}/install" />
77  <property name="jobagent.src" location="${src}/clients/jobagent" />
78
79  <property name="core.build" location="${build}/core" />
80  <property name="coreplugins.build" location="${build}/plugins/core" />
81  <property name="test.build" location="${build}/test" />
82  <property name="migrate.build" location="${build}/clients/migrate" />
83  <property name="install.build" location="${build}/install" />
84  <property name="jobagent.build" location="${build}/clients/jobagent" />
85  <property name="web.build" location="${build}/clients/web" />
86  <property name="web.inf" location="${www}/WEB-INF" />
87  <property name="jsp.build" location="${build}/jsp" />
88
89  <property name="doc.develop" location="${doc}/api/develop" />
90  <property name="doc.public" location="${doc}/api/public" />
91
92  <uptodate
93    property="nohibernate"
94    srcfile="${core.src}/net/sf/basedb/core/data/UserData.java"
95    targetfile="${core.build}/net/sf/basedb/core/data/UserData.hbm.xml"
96    >
97  </uptodate>
98 
99  <path id="core.compile.classpath">
100    <fileset dir="${lib}/compile">
101      <include name="**/*.jar"/>
102    </fileset>
103  </path>
104
105  <path id="plugins.compile.classpath">
106    <path refid="core.compile.classpath"/>
107    <pathelement location="${core.build}"/>
108  </path>
109
110  <path id="test.compile.classpath">
111    <path refid="core.compile.classpath"/>
112    <pathelement location="${core.build}"/>
113    <pathelement location="${jobagent.build}"/>
114  </path>
115
116  <path id="migrate.compile.classpath">
117    <path refid="core.compile.classpath" />
118    <pathelement location="${core.build}" />
119  </path>
120
121  <path id="install.compile.classpath">
122    <path refid="core.compile.classpath" />
123    <pathelement location="${core.build}" />
124    <pathelement location="${coreplugins.build}" />
125  </path>
126
127  <path id="jobagent.compile.classpath">
128    <path refid="core.compile.classpath" />
129    <pathelement location="${core.build}" />
130  </path>
131
132  <path id="web.compile.classpath">
133    <path refid="core.compile.classpath"/>
134    <pathelement location="${core.build}"/>
135  </path>
136
137  <path id="hibernatedoclet.classpath">
138    <fileset dir="${lib}/hibernatedoclet">
139      <include name="**/*.jar"/>
140    </fileset>
141  </path>
142
143  <taskdef
144    name="hibernatedoclet"
145    classname="xdoclet.modules.hibernate.HibernateDocletTask"
146    classpathref="hibernatedoclet.classpath"
147    description="Task for generating Hibernate mapping files from XDoclet tags"
148  />
149
150  <target
151    name="all"
152    depends="core, test, web, javadoc"
153    description="Compile/create everything"
154  />
155
156  <target
157    name="main"
158    depends="core.compile,coreplugins.compile,core.hibernate"
159    description="Compile the core and plugins, generate Hibernate mappings"
160  />
161
162  <target
163    name="core"
164    depends="core.compile,core.hibernate"
165    description="Compile the core and plugins, generate Hibernate mappings"
166  />
167 
168  <target
169    name="coreplugins"
170    depends="coreplugins.compile,core"
171    description="Compile the core plugins"
172  />
173
174  <target
175    name="core.hibernate"
176    depends="core.compile"
177    description="Generates Hibernate mappings for the core."
178    unless="nohibernate"
179    >
180    <hibernatedoclet
181      destdir="${core.build}"
182      excludedtags="@version,@author,@todo"
183      mergedir="${core.build}"
184      verbose="${xdoclet.verbose}">
185      <fileset dir="${core.src}">
186        <include name="**/*.java"/>
187      </fileset>
188      <hibernate version="2.0"/>
189    </hibernatedoclet>
190   
191    <replace
192      dir="${core.build}"
193      >
194      <include name="**/*.hbm.xml"/>
195      <replacefilter 
196        token="2.0//EN"
197        value="3.0//EN"
198      />
199      <replacefilter 
200        token="2.0.dtd"
201        value="3.0.dtd"
202      />
203      <replacefilter
204        token="outer-join=&#34;false&#34;"
205        value="fetch=&#34;select&#34;"
206      />
207      <replacefilter
208        token="outer-join=&#34;true&#34;"
209        value="fetch=&#34;join&#34;"
210      />
211      <replacefilter
212        token="index-many-to-many"
213        value="map-key-many-to-many"
214      />
215      <replacefilter
216        token="&lt;index&gt;"
217        value="&lt;list-index&gt;"
218      />
219      <replacefilter
220        token="&lt;/index&gt;"
221        value="&lt;/list-index&gt;"
222      />
223      <replacefilter
224        token="composite-index"
225        value="composite-map-key"
226      />
227    </replace>
228  </target>
229
230  <target
231    name="core.compile"
232    depends=""
233    description="compile the core source code"
234    >
235    <mkdir dir="${core.build}"/>
236    <javac
237      encoding="ISO-8859-1"
238      srcdir="${core.src}"
239      destdir="${core.build}"
240      classpathref="core.compile.classpath"
241      debug="true"
242      deprecation="true"
243      >
244      <compilerarg value="${compilerarg}" />
245    </javac>
246    <copy todir="${core.build}">
247      <fileset dir="${core.src}">
248        <include name="**/*.xml" />
249        <include name="**/*.dtd" />
250        <include name="**/*.config" />
251        <include name="**/*.properties" />
252      </fileset>
253    </copy>
254  </target>
255
256  <target
257    name="coreplugins.compile"
258    depends="core.compile"
259    description="compile the core plugins"
260    >
261    <mkdir dir="${coreplugins.build}"/>
262    <javac
263      encoding="ISO-8859-1"
264      srcdir="${coreplugins.src}"
265      destdir="${coreplugins.build}"
266      classpathref="plugins.compile.classpath"
267      debug="true"
268      deprecation="true"
269      >
270      <compilerarg value="${compilerarg}" />
271    </javac>
272  </target>
273 
274  <target
275    name="test"
276    depends="main,jobagent,test.compile"
277    description="Compile the test programs"
278  />
279
280  <target name="test.compile"
281    depends=""
282    description="compile the source code for the test programs"
283    >
284    <mkdir dir="${test.build}"/>
285    <javac
286      srcdir="${test.src}"
287      destdir="${test.build}"
288      classpathref="test.compile.classpath"
289      debug="true"
290      deprecation="true"
291      encoding="ISO-8859-1"
292      >
293      <compilerarg value="${compilerarg}" />
294    </javac>
295    <copy todir="${test.build}">
296      <fileset dir="${test.src}">
297        <include name="**/*.*" />
298        <exclude name="**/*.java" />
299      </fileset>
300    </copy>
301    <chmod dir="${test.build}" includes="*.sh" perm="a+x"/>
302    <copy todir="${test.build}">
303      <fileset dir="${src}">
304        <include name="*.config" />
305        <include name="*.properties" />
306        <include name="*.xml" />
307      </fileset>
308    </copy>
309    <jar 
310      jarfile="${test.build}/JarPluginAbout.jar" 
311      basedir="${test.build}" 
312      includes="JarPluginAbout.class" 
313    />
314    <jar 
315      jarfile="${test.build}/JarPlugin.jar" 
316      basedir="${test.build}" 
317      includes="JarPlugin*,NullPlugin*"
318      excludes="JarPlugin.jar,JarPluginAbout.class"
319      manifest="${test.src}/JarPluginManifest.txt"
320    />
321    <delete>
322      <fileset dir="${test.build}" includes="JarPlugin*" excludes="*.jar" />
323    </delete>
324  </target>
325
326  <target
327    name="migrate"
328    depends="main,dist.migrate"
329    description="create the Migrate.jar"
330  >
331  </target>
332 
333  <target name="dist.migrate" depends="migrate.compile,dist.init" description="">
334
335    <jar basedir="${migrate.build}" jarfile="${dist.bin}/Migrate.jar" includes="**/*.class">
336    </jar>
337    <copy todir="${dist.bin}" file="${migrate.src}/migrate_from_1.2.sh" />
338    <chmod file="${dist.bin}/migrate_from_1.2.sh" perm="a+x"/>
339    <copy tofile="${dist.classes}/migrate.properties" file="${migrate.src}/migrate.properties.in" />
340    <chmod file="${dist.classes}/migrate.properties" perm="600"/>
341    <copy tofile="${dist.classes}/mysql-migration-queries.sql" file="${migrate.src}/sql/mysql-migration-queries.sql" />
342    <chmod file="${dist.classes}/mysql-migration-queries.sql" perm="600"/>
343
344  </target>
345
346  <target name="migrate.properties" if="migrate.newproperties">
347    <copy tofile="${migrate.build}/migrate.properties" file="${migrate.src}/migrate.properties.in" />
348    <chmod file="${migrate.build}/migrate.properties" perm="600"/>
349  </target>
350
351  <target name="migrate.compile" description="compile the source code for the migration program">
352
353    <mkdir dir="${migrate.build}" />
354    <javac
355      encoding="ISO-8859-1"
356      srcdir="${migrate.src}"
357      destdir="${migrate.build}"
358      classpathref="migrate.compile.classpath"
359      debug="true"
360      >
361      <compilerarg value="${compilerarg}" />
362    </javac>
363    <copy todir="${migrate.build}">
364      <fileset dir="${src}">
365        <include name="*.config" />
366        <include name="*.properties" />
367        <include name="*.xml" />
368      </fileset>
369    </copy>
370    <copy todir="${migrate.build}" file="${migrate.src}/migrate_from_1.2.sh" />
371    <chmod file="${migrate.build}/migrate_from_1.2.sh" perm="a+x"/>
372    <condition property="migrate.newproperties">
373      <not>
374        <available file="${migrate.build}/migrate.properties"/>
375      </not>
376    </condition>
377    <antcall target="migrate.properties"/>
378
379  </target>
380
381  <target
382    name="install"
383    depends="install.compile"
384    description="Compile the installation program"
385  >
386  </target>
387
388  <target name="install.compile"
389    description="compile the source code for the installation program"
390    >
391    <mkdir dir="${install.build}" />
392    <javac
393      encoding="ISO-8859-1"
394      srcdir="${install.src}"
395      destdir="${install.build}"
396      classpathref="install.compile.classpath"
397      debug="true"
398      deprecation="true"
399      >
400      <compilerarg value="${compilerarg}" />
401    </javac>
402  </target>
403
404 
405  <target
406    name="jobagent"
407    depends="jobagent.compile"
408    description="Compile the job agent client"
409    >
410  </target>
411 
412  <target
413    name="jobagent.compile"
414    depends="core.compile"
415    >
416    <mkdir dir="${jobagent.build}" />
417    <javac
418      encoding="ISO-8859-1"
419      srcdir="${jobagent.src}"
420      destdir="${jobagent.build}"
421      classpathref="jobagent.compile.classpath"
422      debug="true"
423      deprecation="true"
424      >
425      <compilerarg value="${compilerarg}" />
426    </javac>
427  </target>
428 
429  <target
430    name="web"
431    depends="main,web.compile"
432    description="Compile the web client, and copy required files to the web-inf directory"
433  >
434    <mkdir dir="${web.inf}/lib"/>
435    <mkdir dir="${web.inf}/classes"/>
436    <jar
437      basedir="${core.build}"
438      jarfile="${web.inf}/lib/BASE2Core.jar"
439    />
440    <jar
441      basedir="${coreplugins.build}"
442      jarfile="${web.inf}/lib/BASE2CorePlugins.jar"
443    />
444    <jar
445      basedir="${web.build}"
446      jarfile="${web.inf}/lib/BASE2Webclient.jar"
447    />
448    <copy todir="${web.inf}/lib">
449      <fileset dir="${lib}/compile">
450        <include name="**/*.jar"/>
451        <exclude name="**/servlet-api.jar" />
452        <exclude name="**/jsp-api.jar" />
453      </fileset>
454      <fileset dir="${lib}/dist">
455        <include name="**/*.jar"/>
456      </fileset>
457    </copy>
458    <copy todir="${web.inf}/classes">
459      <fileset dir="${src}">
460        <include name="*.config"/>
461        <include name="*.properties"/>
462        <include name="*.xml"/>
463      </fileset>
464    </copy>
465  </target>
466
467  <target
468    name="web.compile"
469    depends=""
470    description="compile the source code for the web client"
471    >
472    <mkdir dir="${web.build}"/>
473    <javac
474      encoding="ISO-8859-1"
475      srcdir="${web.src}"
476      destdir="${web.build}"
477      classpathref="web.compile.classpath"
478      debug="true"
479      deprecation="true"
480      >
481      <compilerarg value="${compilerarg}" />
482    </javac>
483    <copy todir="${web.build}">
484      <fileset dir="${web.src}">
485        <include name="**/*.xml" />
486        <include name="**/*.dtd" />
487        <include name="**/*.config" />
488        <include name="**/*.properties" />
489      </fileset>
490    </copy>
491  </target>
492
493  <target 
494    name="jsp.compile"
495    depends="web"
496    description="Compile all JSP pages to a temporary directory"
497    >
498    <mkdir dir="${jsp.build}/src" />
499    <mkdir dir="${jsp.build}/classes" />
500   
501    <path id="jsp.precompile.classpath">
502      <pathelement location="${java.home}/../lib/tools.jar" />
503      <fileset dir="${env.CATALINA_HOME}/server/lib">
504        <include name="*.jar" />
505      </fileset>
506      <fileset dir="${env.CATALINA_HOME}/common/lib">
507        <include name="*.jar" />
508      </fileset>
509      <fileset dir="${env.CATALINA_HOME}/bin">
510        <include name="*.jar" />
511      </fileset>
512    </path>
513   
514    <path id="jsp.compile.classpath">
515      <path refid="web.compile.classpath" />
516      <pathelement location="${java.home}/../lib/tools.jar" />
517      <fileset dir="${env.CATALINA_HOME}/common/lib">
518        <include name="*.jar" />
519      </fileset>
520      <fileset dir="${env.CATALINA_HOME}/shared/lib">
521        <include name="*.jar" />
522      </fileset>
523      <fileset dir="${web.inf}/lib">
524        <include name="*.jar" />
525      </fileset>
526    </path>
527
528    <taskdef
529      classname="org.apache.jasper.JspC" 
530      name="jasper2"
531      classpathref="jsp.precompile.classpath"
532    />
533    <jasper2
534      validateXml="false"
535      uriroot="${www}"
536      webXmlFragment="${jsp.build}/generated_web.xml"
537      outputdir="${jsp.build}/src"
538    />
539    <javac
540      destdir="${jsp.build}/classes"
541      srcdir="${jsp.build}/src"
542      debug="true"
543      classpathref="jsp.compile.classpath"
544      memoryinitialsize="256m"
545      memorymaximumsize="512m"
546      fork="true"
547      >
548    </javac>
549  </target>
550 
551  <target
552    name="dist"
553    depends="clean,svn.revision,dist.init,dist.core,dist.coreplugins,dist.install,dist.web,dist.jobagent,dist.doc,dist.migrate"
554    description="Create the distribution and put all files in their correct places">
555    <move 
556      file="${core.src}/net/sf/basedb/core/Application.java.bak"
557      tofile="${core.src}/net/sf/basedb/core/Application.java"
558      overwrite="true"
559    />
560    <copy todir="${dist.lib}">
561      <fileset dir="${lib}/compile">
562        <include name="**/*.jar"/>
563        <!--exclude name="**/*jai*.jar" / -->
564        <exclude name="**/servlet-api.jar" />
565        <exclude name="**/jsp-api.jar" />
566      </fileset>
567      <fileset dir="${lib}/dist">
568        <include name="**/*.*"/>
569        <exclude name="**/ojdbc14.jar" />
570      </fileset>
571    </copy>
572    <copy tofile="${dist.webinf}/web.xml" file="${src}/web.xml.in" overwrite="true" />
573    <copy tofile="${dist.classes}/base.config" file="${src}/base.config.in" overwrite="true"/>
574    <chmod file="${dist.classes}/base.config" perm="600"/>
575    <copy tofile="${dist.classes}/log4j.properties" file="${src}/log4j.properties.in" overwrite="true"/>
576    <chmod file="${dist.classes}/log4j.properties" perm="600"/>
577  </target>
578
579  <target
580    name="dist.init"
581    description="Create the distribution directory structure"
582    >
583    <mkdir dir="${dist}"/>
584    <mkdir dir="${dist.bin}"/>
585    <mkdir dir="${dist}/doc"/>
586    <mkdir dir="${dist}/www"/>
587    <mkdir dir="${dist.lib}"/>
588    <copy 
589      file="${core.src}/net/sf/basedb/core/Application.java"
590      tofile="${core.src}/net/sf/basedb/core/Application.java.bak"
591      overwrite="false"
592    />
593    <replace
594      file="${core.src}/net/sf/basedb/core/Application.java"
595      token="@BUILD@"
596      value="${base.build}"
597    />
598  </target>
599
600  <target 
601    name="svn.revision"
602    description="Get the current revision number in the subversion and put the value into the base.build property"
603    >
604    <exec 
605      executable="svnversion"
606      outputproperty="base.build"
607      failifexecutionfails="false"
608      >
609      <arg line="." />
610    </exec>
611    <echo message="Build #${base.build}" />
612  </target>
613 
614  <target
615    name="dist.core"
616    depends="core.compile,core.hibernate"
617    description="Generate the core jar file: BASE2Core.jar"
618    >
619    <jar
620      basedir="${core.build}"
621      jarfile="${dist.lib}/BASE2Core.jar"
622    />
623  </target>
624 
625  <target
626    name="dist.coreplugins"
627    depends="coreplugins.compile"
628    description="Generate the core plugins jar file: BASE2CorePlugins.jar"
629    >
630    <jar
631      basedir="${coreplugins.build}"
632      jarfile="${dist.lib}/BASE2CorePlugins.jar"
633    />
634  </target>
635
636  <target 
637    name="dist.jobagent"
638    depends="jobagent.compile,dist.core"
639    >
640    <jar
641      basedir="${jobagent.build}"
642      jarfile="${dist.bin}/JobAgent.jar"
643    />
644    <copy todir="${dist.bin}">
645      <fileset dir="${jobagent.src}" includes="*.sh,*.bat" />
646    </copy>
647    <chmod dir="${dist.bin}" includes="*.sh" perm="a+x"/>
648    <copy tofile="${dist.bin}/jobagent.properties" file="${jobagent.src}/jobagent.properties.in" overwrite="true"/>
649    <chmod file="${dist.bin}/jobagent.properties" perm="600"/>
650  </target>
651 
652  <target
653    name="dist.install"
654    depends="install.compile"
655    description="Generate the installation jar file: BASE2Install.jar"
656    >
657    <jar
658      basedir="${install.build}"
659      jarfile="${dist.bin}/BASE2Install.jar"
660    />
661    <copy todir="${dist.bin}">
662      <fileset dir="${install.src}" includes="*.sh,*.bat" />
663      <fileset dir="${install.src}" includes="includes" />
664      <fileset file="${web.src}/helptexts.xml" />
665    </copy>
666    <chmod dir="${dist.bin}" includes="*.sh" perm="a+x"/>
667  </target>
668  <target
669    name="dist.web"
670    depends="web"
671    description="Generate the web jar file: BASE2Webclient.jar
672      and copy all *.jsp files"
673    >
674    <jar
675      basedir="${web.build}"
676      jarfile="${dist.lib}/BASE2Webclient.jar"
677    />
678    <copy
679      todir="${dist}/www"
680      >
681      <fileset dir="${www}">
682        <include name="**/*"/>
683        <exclude name="**/*.jar" />
684      </fileset>
685    </copy>
686  </target>
687 
688  <target
689    name="dist.doc"
690    depends=""
691    description="Copy required documentation"
692    >
693    <copy todir="${dist}" file="${doc}/installation.html" />
694    <copy todir="${dist}" file="base2.license.txt" />
695    <copy todir="${dist}" file="credits.txt" />
696    <copy todir="${dist}/doc" file="${doc}/3rd-party-components.txt" />
697    <copy todir="${dist}/doc" file="${doc}/configure_unicode_support.txt" />
698    <copy todir="${dist}/doc" file="${doc}/tomcat_with_java_1.5.txt" />
699    <copy todir="${dist}/doc/licenses">
700      <fileset dir="${doc}/licenses" />
701    </copy>
702  </target>
703 
704  <target
705    name="package"
706    depends="dist"
707    description="Package the distribution"
708    >
709    <tar
710      destfile="base-${base.version}.tar.gz"
711      compression="gzip"
712      >
713      <tarfileset
714        dir="${dist}"
715        prefix="base-${base.version}"
716        preserveLeadingSlashes="true"
717      />
718    </tar>
719    <checksum
720      file="base-${base.version}.tar.gz"
721    />
722  </target>
723
724  <target
725    name="clean"
726    description="Remove all generated files and backup files" >
727    <delete dir="${build}"/>
728    <delete dir="${dist}"/>
729    <delete dir="${web.inf}/lib"/>
730    <delete dir="${web.inf}/classes"/>
731    <delete>
732      <fileset dir="." includes="**/base-*.tar.gz*" defaultexcludes="no"/>
733      <fileset dir="." includes="**/*~" defaultexcludes="no"/>
734      <fileset dir="." includes="**/.#*" defaultexcludes="no"/>
735    </delete>
736  </target>
737
738  <target
739    name="exampleplugins"
740    description="Tar the code for example plugins"
741    >
742    <property name="exampledir" location="${src}/examples/plugins" />
743    <javac 
744      encoding="ISO-8859-1"
745      srcdir="${exampledir}/src"
746      destdir="${exampledir}/bin"
747      debug="true"
748      >
749      <classpath>
750        <fileset dir="${exampledir}/lib">
751          <include name="**/*.jar"/>
752        </fileset>
753        <pathelement path="${core.build}" />
754      </classpath>
755    </javac>
756    <jar 
757      jarfile="${exampledir}/ExamplePlugins.jar" 
758      basedir="${exampledir}/bin"
759      manifest="${exampledir}/MANIFEST.MF"
760    />
761    <tar
762      destfile="${doc}/development/plugins/exampleplugins.tar.gz"
763      compression="gzip"
764      >
765      <tarfileset
766        dir="${src}/examples/plugins"
767        preserveLeadingSlashes="true"
768      />
769    </tar>
770    <delete file="${exampledir}/ExamplePlugins.jar" />
771    <delete includeemptydirs="true">
772      <fileset dir="${exampledir}/bin" includes="**/*"/>
773    </delete>
774  </target>
775 
776  <target
777    name="javadoc"
778    depends="javadoc.develop,javadoc.public"
779  />
780
781  <target
782    name="javadoc.develop"
783    description="generate JavaDoc for developers of BASE, ie. include private and protecteed methods.">
784    <!-- Create the time stamp -->
785    <tstamp>
786      <format property="TODAY" pattern="yyyy-MM-dd"/>
787    </tstamp>
788    <mkdir dir="${doc}"/>
789
790    <javadoc
791      packagenames="net.sf.basedb.*"
792      sourcepath="${core.src}:${web.src}:${migrate.src}"
793      destdir="${doc.develop}"
794      author="true"
795      version="true"
796      use="true"
797      private="true"
798      windowtitle="BASE 2.0 Class documentation (developer edition)"
799      stylesheetfile="${doc}/javadoc.css"
800      classpathref="core.compile.classpath"
801      linksource="yes"
802      breakiterator="yes"
803      encoding="iso-8859-1"
804      >
805      <header><![CDATA[Last update: ${TODAY}]]></header>
806      <link href="http://java.sun.com/j2se/1.5/docs/api"/>
807      <link href="http://www.hibernate.org/hib_docs/v3/api"/>
808      <link href="http://www.jdom.org/docs/apidocs/" />
809      <link href="http://java.sun.com/products/servlet/2.2/javadoc/" />
810      <link href="http://www.singularsys.com/jep/doc/javadoc/" />
811      <tag name="base.internal" description="Developer info" />
812      <tag name="base.modified" description="Last modified" />
813      <tag name="hibernate.class" description="Hibernate: class" scope="types" />
814      <tag name="hibernate.subclass" description="Hibernate: subclass" scope="types" />
815      <tag name="hibernate.discriminator" description="Hibernate: discriminator" scope="types" />
816      <tag name="hibernate.id" description="Hibernate: id" scope="methods" />
817      <tag name="hibernate.generator-param" description="Hibernate: generator-param" scope="methods" />
818      <tag name="hibernate.version" description="Hibernate: version" scope="methods" />
819      <tag name="hibernate.property" description="Hibernate: property" scope="methods" />
820      <tag name="hibernate.column" description="Hibernate: column" scope="methods" />
821      <tag name="hibernate.map" description="Hibernate: map" scope="methods" />
822      <tag name="hibernate.set" description="Hibernate: set" scope="methods" />
823      <tag name="hibernate.list" description="Hibernate: list" scope="methods" />
824      <tag name="hibernate.array" description="Hibernate: array" scope="methods" />
825      <tag name="hibernate.one-to-one" description="Hibernate: one-to-one" scope="methods" />
826      <tag name="hibernate.many-to-one" description="Hibernate: many-to-one" scope="methods" />
827      <tag name="hibernate.many-to-many" description="Hibernate: many-to-many" scope="methods" />
828      <tag name="hibernate.index-many-to-many" description="Hibernate: index-many-to-many" scope="methods" />
829      <tag name="hibernate.collection-key" description="Hibernate: collection-key" scope="methods" />
830      <tag name="hibernate.collection-index" description="Hibernate: collection-index" scope="methods" />
831      <tag name="hibernate.collection-composite-index" description="Hibernate: collection-composite-index" scope="methods" />
832      <tag name="hibernate.collection-element" description="Hibernate: collection-element" scope="methods" />
833      <tag name="hibernate.collection-composite-element" description="Hibernate: collection-composite-element" scope="methods" />
834      <tag name="hibernate.collection-one-to-many" description="Hibernate: collection-one-to-many" scope="methods" />
835      <tag name="hibernate.collection-many-to-many" description="Hibernate: collection-many-to-many" scope="methods" />
836      <tag name="hibernate.bag" description="Hibernate: bag" scope="methods" />
837      <tag name="hibernate.many-to-any" description="Hibernate: many-to-any" scope="methods" />
838      <tag name="hibernate.many-to-any-column" description="Hibernate: many-to-any-column" scope="methods" />
839    </javadoc>
840  </target>
841
842  <target
843    name="javadoc.public"
844    description="generate public JavaDoc, ie. without private and protected methods">
845    <tstamp>
846      <format property="TODAY" pattern="yyyy-MM-dd"/>
847    </tstamp>
848    <mkdir dir="${doc}"/>
849    <javadoc
850      packagenames="net.sf.basedb.*"
851      sourcepath="${core.src}:${web.src}"
852      destdir="${doc.public}"
853      author="true"
854      version="true"
855      protected="true"
856      windowtitle="BASE 2.0 Class documentation"
857      stylesheetfile="${doc}/javadoc.css"
858      classpathref="core.compile.classpath"
859      breakiterator="yes"
860      encoding="iso-8859-1"
861      >
862      <header><![CDATA[Last update: ${TODAY}]]></header>
863      <link href="http://java.sun.com/j2se/1.5/docs/api"/>
864      <link href="http://www.hibernate.org/hib_docs/v3/api"/>
865      <link href="http://www.jdom.org/docs/apidocs/" />
866      <link href="http://java.sun.com/products/servlet/2.2/javadoc/" />
867      <link href="http://www.singularsys.com/jep/doc/javadoc/" />
868      <tag name="base.internal" description="Developer info" enabled="false" />
869      <tag name="base.modified" description="Last modified" enabled="false" />
870      <tag name="hibernate.class" description="Hibernate: class" scope="types" enabled="false" />
871      <tag name="hibernate.subclass" description="Hibernate: subclass" scope="types" enabled="false" />
872      <tag name="hibernate.discriminator" description="Hibernate: discriminator" scope="types" enabled="false" />
873      <tag name="hibernate.id" description="Hibernate: id" scope="methods" enabled="false" />
874      <tag name="hibernate.generator-param" description="Hibernate: generator-param" scope="methods" enabled="false" />
875      <tag name="hibernate.version" description="Hibernate: version" scope="methods" enabled="false" />
876      <tag name="hibernate.property" description="Hibernate: property" scope="methods" enabled="false" />
877      <tag name="hibernate.key-property" description="Hibernate: key-property" scope="methods" enabled="false" />
878      <tag name="hibernate.column" description="Hibernate: column" scope="methods" />
879      <tag name="hibernate.map" description="Hibernate: map" scope="methods" enabled="false" />
880      <tag name="hibernate.set" description="Hibernate: set" scope="methods" enabled="false" />
881      <tag name="hibernate.list" description="Hibernate: list" scope="methods" enabled="false" />
882      <tag name="hibernate.array" description="Hibernate: array" scope="methods" enabled="false" />
883      <tag name="hibernate.one-to-one" description="Hibernate: one-to-one" scope="methods" enabled="false" />
884      <tag name="hibernate.many-to-one" description="Hibernate: many-to-one" scope="methods" enabled="false" />
885      <tag name="hibernate.many-to-many" description="Hibernate: many-to-many" scope="methods" enabled="false" />
886      <tag name="hibernate.index-many-to-many" description="Hibernate: index-many-to-many" scope="methods" enabled="false" />
887      <tag name="hibernate.collection-key" description="Hibernate: collection-key" scope="methods" enabled="false" />
888      <tag name="hibernate.collection-index" description="Hibernate: collection-index" scope="methods" enabled="false" />
889      <tag name="hibernate.collection-composite-index" description="Hibernate: collection-composite-index" scope="methods" enabled="false" />
890      <tag name="hibernate.collection-element" description="Hibernate: collection-element" scope="methods" enabled="false" />
891      <tag name="hibernate.collection-composite-element" description="Hibernate: collection-composite-element" scope="methods" enabled="false" />
892      <tag name="hibernate.collection-one-to-many" description="Hibernate: collection-one-to-many" scope="methods" enabled="false" />
893      <tag name="hibernate.collection-many-to-many" description="Hibernate: collection-many-to-many" scope="methods" enabled="false" />
894      <tag name="hibernate.bag" description="Hibernate: bag" scope="methods" enabled="false" />
895      <tag name="hibernate.many-to-any" description="Hibernate: many-to-any" scope="methods" enabled="false" />
896      <tag name="hibernate.many-to-any-column" description="Hibernate: many-to-any-column" scope="methods" enabled="false" />
897    </javadoc>
898  </target>
899
900
901</project>
Note: See TracBrowser for help on using the repository browser.