root/trunk/calendar3/build.xml

Revision 59 (checked in by douglm, 7 years ago)

A number of fixes to the restore so that it handles a full v3 dump file.

Changed restore so that syspars values supplied as arguments will override values read from the restore file. This allows us to use the configuration properties to initialise the db.

We need a new page to the config tool for syspars.

Moved all dump/restore default properties into config properties file. We now need a dump/restore page as well.
Then discovered they were already in there so that may have caused problems.

Deleted file calendar3/local.build.properties

Line 
1 <?xml version="1.0"?>
2
3 <!-- This is the main build file for UW Calendar which can be used in
4      conjunction with Ant (http://jakarta.apache.org/ant/) to
5      build, deploy, and distribute the UW calendar project. Type
6      "ant -projecthelp" to see a list of ant targets.
7
8      The assumption is that deployers of the calendar will want to create
9      a number of independent calendar applications managed by different
10      groups.
11
12      To facilitate this the build process is driven by a set of properties
13      in appsuite/clones.
14
15      You shouldn't need to modify base files or applications. Instead,
16      modify the application specific properties and html/jsp pages to create
17      a customized application.
18
19      This file will only need mofification to add a specific target for your
20      new application. These targets should be added in the appsuite
21      section of the file.
22
23      apps.root.dir  (Optional - defaults to apps)
24                     We expect to find a file
25                          ${apps.root.dir}/${app-name}.properties
26                     which defines build time properties for the application.
27                     Note this file does not get built in to the application.
28
29      Authors: Mike Douglass   douglm@rpi.edu
30 -->
31
32 <project name="bedework" default="bld.all">
33   <!-- ==================== Basic property Definitions =================
34       Each of the following properties are used in the build script.
35       Values for these properties are set by the first place they are
36       defined, from the following list:
37       * Definitions on the "ant" command line (ant -Ddeploy.home=xyz compile)
38       * Definitions from a "uwcal.build.properties" file in the developer's
39         home directory
40       * Definitions from a "local.build.properties" file in the top level
41         source directory
42       * Definitions from a "build.properties" file in the top level
43         source directory
44       * Default definitions in this build.xml file
45
46       You will note below that property values can be composed based on the
47       contents of previously defined properties.  This is a powerful
48       technique that helps you minimize the number of changes required when
49       your development environment is modified. Note that property
50       composition is allowed within "build.properties" files as well as in
51       the "build.xml" script.
52        ================================================================= -->
53
54   <property name="org.bedework.globaldefs.file" value="bldfiles/globalDefs.xml"/>
55   <import file="${org.bedework.globaldefs.file}"/>
56
57   <!-- =================================================================
58        init:  all the property defs are in bldfiles/globalDdefs.xml
59        ================================================================= -->
60
61   <target name="init" depends="globalDefs">
62     <!-- ==================== config properties ========================= -->
63     <property name="org.bedework.clone.name" value="${org.bedework.clone.default}" />
64     <property name="org.bedework.config.properties"
65               location="${org.bedework.config.base}/configs/${org.bedework.clone.name}.properties" />
66
67     <echo message="==========================================================" />
68     <echo message="Use config properties ${org.bedework.config.properties}" />
69     <loadproperties
70           srcFile="${org.bedework.config.properties}" >
71       <filterchain>
72         <expandproperties/>
73       </filterchain>
74     </loadproperties>
75   </target>
76
77   <!-- =================================================================
78        The "all" target does a complete clean rebuild of all applications.
79        ================================================================= -->
80
81   <target name="all" depends="init,clean,dist"
82           description="Clean build and dist"/>
83
84   <!-- ======================== Clean Target ===========================
85        The "clean" target deletes any generated directories, to ensure
86        applications are built from scratch.
87        ================================================================= -->
88
89   <target name="clean" depends="init"
90           description="Delete generated directories">
91     <delete dir="${org.bedework.temp.home}"/>
92     <delete dir="${dist.home}"/>
93     <delete>
94       <fileset dir="." includes="junit*.properties" />
95       <fileset dir="." includes="test.log*" />
96     </delete>
97   </target>
98
99 <!-- ===================== bld.all Target ===============================
100   This target builds jar files ready for the deploy target.
101      =================================================================== -->
102
103   <target name="bld.all"
104           depends="bld.locale,bld.access,bld.calfacade,
105                    bld.calenv,bld.ical,bld.common,bld.core,
106                    bld.http,bld.caldavclientapi,
107                    bld.calsvci,bld.mail,bld.logging,
108                    bld.calsvc,bld.appcommon,
109                    bld.webadmin,bld.webclient,
110                    bld.synchml,bld.caldav,
111                    bld.timers,build.tools,
112                    bld.dumprestore,
113                    bld.test,bld.config"
114           description="Build war and ear files">
115     <antcall inheritrefs="true" target="copy.to.jars.repository" />
116   </target>
117
118   <target name="copy.to.jars.repository" if="org.bedework.jars.repository">
119     <mkdir dir="${org.bedework.jars.repository}" />
120
121     <copy todir="${org.bedework.jars.repository}" >
122       <fileset dir="${org.bedework.temp.jars}">
123         <include name="*-${product.version}.jar"/>
124       </fileset>
125     </copy>
126   </target>
127
128 <!-- ===================== Deploy Target ===============================
129      The "deploy" target builds configured war files and zipped runnable
130      application based on the configuration properties. It then copies the
131      contents of the build directory into the locations required by our
132      servlet container, and picks up any external dependencies along the way.
133
134      After restarting the servlet container, you can then test bedework.
135
136      To build a version for your site you should probably copy and modify the
137                   config/configs/democal.properties
138      file and change the value of org.bedework.clone.name to the name of your
139      new clone.
140
141      To build more than  one appsuite duplicate the ant task
142      invocation below with a different clone name in each.
143      =================================================================== -->
144
145   <target name="deploy.debug" depends="bld.all,deploy.log4j.xml"
146           description="Deploy applications to servlet container" >
147     <ant antfile="${org.bedework.deployment.base}/build.xml" inheritrefs="true"
148            target="deploy"  >
149       <property name="app.debug.val" value="9" />
150     </ant>
151   </target>
152
153   <target name="deploy" depends="bld.all,deploy.log4j.xml"
154           description="Deploy applications to servlet container" >
155     <ant antfile="${org.bedework.deployment.base}/build.xml" inheritrefs="true"
156            target="deploy"  >
157       <property name="org.bedework.clone.name" value="${org.bedework.clone.default}" />
158     </ant>
159   </target>
160
161 <!-- ================== build.configured Target ========================
162      Build configured war files but don't deploy. Use to build versions to
163      be deployed elsewhere.
164      =================================================================== -->
165
166   <target name="build.configured.debug" depends="bld.all"
167           description="Build configured applications" >
168     <ant antfile="${org.bedework.deployment.base}/build.xml" inheritrefs="true"
169            target="build.configured" >
170       <property name="app.debug.val" value="9" />
171     </ant>
172   </target>
173
174   <target name="build.configured" depends="bld.all"
175           description="Build configured applications" >
176     <ant antfile="${org.bedework.deployment.base}/build.xml" inheritrefs="true"
177            target="build.configured" >
178       <property name="org.bedework.clone.name" value="${org.bedework.clone.default}" />
179     </ant>
180   </target>
181
182   <!-- Copy log4j.xml to the app server but overwrite only if specified.
183        Somewhat annoying to find a carefully crafted log4j.xml gets overwritten.
184     -->
185   <target name="deploy.log4j.xml" >
186     <copy todir="${log4j.config.destination}"
187           file="${calendar.dir}/resources/log4j.xml"
188           overwrite="${org.bedework.deploy.log4j.config}" />
189   </target>
190
191   <!-- Target used to build from property files built by config tool -->
192   <target name="deploy.config" >
193     <copy todir="${log4j.config.destination}"
194           file="${calendar.dir}/resources/log4j.xml"
195           overwrite="${org.bedework.deploy.log4j.config}" />
196
197     <!-- The property org.bedework.deploy.config.name must be set -->
198     <ant antfile="${org.bedework.appsuite.base}/build.xml" inheritrefs="true"
199            target="deploy.config"  />
200
201     <antcall inheritrefs="true" target="deploy.caldav" />
202   </target>
203
204 <!-- ==================== Dist Target ==================================
205      The "dist" target creates a binary distribution of your application
206      in a directory structure ready to be archived in a tar.gz or zip file.
207      Note that this target depends on two others:
208      * "deploy" so that the entire web application (including external
209        dependencies) will have been assembled
210      * "javadoc" so that the application Javadocs will have been created
211      =================================================================== -->
212
213   <target name="dist" depends="bld.all,javadoc"
214           description="Create binary distribution" />
215
216 <!-- ==================== Javadoc Target ===============================
217      The "javadoc" target creates Javadoc API documentation for the Java
218      classes included in your application.  Normally, this is only required
219      when preparing a distribution release, but is available as a separate
220      target in case the developer wants to create Javadocs independently.
221      =================================================================== -->
222
223   <target name="javadoc" depends="init"
224           description="Create Javadoc API documentation">
225
226     <path id="javadoc.classpath">
227       <pathelement location="${servlet.jar}"/>
228       <pathelement location="${struts.jar}"/>
229       <pathelement location="${fop.jar}"/>
230       <pathelement location="${avalon.jar}"/>
231       <pathelement location="${log4j.jar}"/>
232       <pathelement location="${hibernate.jar}"/>
233       <pathelement location="${ical4j.jar}"/>
234       <pathelement location="${logkit.jar}"/>
235       <pathelement location="${jtidy.jar}"/>
236     </path>
237     <mkdir dir="${dist.home}/docs/api"/>
238     <javadoc sourcepath="${org.bedework.access.base}/src:
239                          ${org.bedework.appcommon.base}/src:
240                          ${org.bedework.core.base}/src:
241                          ${org.bedework.caldav.base}/src:
242                          ${org.bedework.caldavClientApi.base}/src:
243                          ${org.bedework.calenv.base}/src:
244                          ${org.bedework.calfacade.base}/src:
245                          ${org.bedework.calsvc.base}/src:
246                          ${org.bedework.calsvci.base}/src:
247                          ${org.bedework.common.base}/src:
248                          ${org.bedework.config.base}/src:
249                          ${org.bedework.dumprestore.base}/src:
250                          ${org.bedework.http.base}/src:
251                          ${org.bedework.ical.base}/src:
252                          ${org.bedework.locale.base}/src:
253                          ${org.bedework.logging.base}/src:
254                          ${org.bedework.mail.base}/src:
255                          ${org.bedework.synchml.base}/src:
256                          ${org.bedework.timers.base}/src:
257                          ${org.bedework.tools.base}/src:
258                          ${org.bedework.webadmin.base}/src:
259                          ${org.bedework.webclient.base}/src:
260                          ${org.bedework.webcommon.base}/src:"
261            classpathref="javadoc.classpath"
262                 destdir="${dist.home}/docs/api"
263            packagenames="org.bedework.access.*,
264                          org.bedework.*,
265                          edu.rpi.cct.uwcal.access.*,
266                          edu.rpi.*,
267                          edu.washington.*"
268                  access="public"
269                  author="true"
270                 version="true"
271           breakiterator="yes"
272             windowtitle="${product.name} ${product.version} API Documentation">
273       <doctitle><![CDATA[${product.name} ${product.version}<br/>API Documentation]]></doctitle>
274       <header><![CDATA[${product.name} ${product.version}<br/>API Documentation]]></header>
275     </javadoc>
276
277   </target>
278
279   <!-- ======================== calfacade target =========================
280        This builds the back end facade for the core of the calendar.
281        ================================================================= -->
282
283   <target name="bld.calfacade"
284           depends="bld.access"
285           description="Build calendar calfacade jars" >
286       <ant antfile="${org.bedework.calfacade.base}/build.xml" inheritrefs="true"
287            target="build" />
288   </target>
289
290   <!-- ======================== calenv target =========================
291        This builds the some environment dependent classes for the core
292        of the calendar.
293        ================================================================= -->
294
295   <target name="bld.calenv"
296           depends="bld.calfacade"
297           description="Build calendar env jars" >
298       <ant antfile="${org.bedework.calenv.base}/build.xml" inheritrefs="true"
299            target="build" />
300   </target>
301
302   <!-- ======================== core target =========================
303        This builds the back end core of the calendar. Applications interact
304        with that core through the CalFacade interface.
305        ================================================================= -->
306
307   <target name="bld.core"
308           depends="bld.calfacade,bld.calenv,bld.ical"
309           description="Build calendar core jars" >
310       <ant antfile="${org.bedework.core.base}/build.xml" inheritrefs="true"
311            target="build" />
312   </target>
313
314   <!-- ======================== locale target =========================
315        This builds the localization suite of the calendar.
316        ================================================================= -->
317
318   <target name="bld.locale"
319           depends="init"
320           description="Build calendar localization suite jars" >
321       <ant antfile="${org.bedework.locale.base}/build.xml" inheritrefs="true"
322            target="build" />
323   </target>
324
325   <!-- ======================== access target =========================
326        This builds the access control suite of the calendar.
327        ================================================================= -->
328
329   <target name="bld.access"
330           depends="bld.locale"
331           description="Build calendar access control suite jars" >
332       <ant antfile="${org.bedework.access.base}/build.xml" inheritrefs="true"
333            target="build" />
334   </target>
335
336   <!-- ======================== common target =======================
337        This builds the common classes jar.
338        ================================================================= -->
339
340   <target name="bld.common"
341           depends="init,bld.calfacade,bld.locale"
342           description="Build calendar common classes jar">
343       <ant antfile="${org.bedework.common.base}/build.xml" inheritrefs="true"
344            target="build" />
345   </target>
346
347   <!-- ======================== http target =======================
348        This builds the http-client classes jar.
349        ================================================================= -->
350
351   <target name="bld.http"
352           depends="init,bld.calenv,bld.calfacade,bld.locale"
353           description="Build calendar http classes jar">
354       <ant antfile="${org.bedework.http.base}/build.xml" inheritrefs="true"
355            target="build" />
356   </target>
357
358   <!-- ======================== caldavclientapi target =======================
359        This builds the http-client classes jar.
360        ================================================================= -->
361
362   <target name="bld.caldavclientapi"
363           depends="init,bld.http,bld.calfacade"
364           description="Build calendar caldav client api classes jar">
365       <ant antfile="${org.bedework.caldavClientApi.base}/build.xml" inheritrefs="true"
366            target="build" />
367   </target>
368
369   <!-- ======================== logging target =======================
370        This builds the logging classes jar.
371        ================================================================= -->
372
373   <target name="bld.logging"
374           depends="init,bld.calfacade"
375           description="Build logging classes jar">
376       <ant antfile="${org.bedework.logging.base}/build.xml" inheritrefs="true"
377            target="build" />
378   </target>
379
380   <!-- ======================== mail target =======================
381        This builds the mail classes jar.
382        ================================================================= -->
383
384   <target name="bld.mail"
385           depends="init,bld.calsvci"
386           description="Build calendar mail classes jar">
387       <ant antfile="${org.bedework.mail.base}/build.xml" inheritrefs="true"
388            target="build" />
389   </target>
390
391   <!-- ======================== calsvci target =======================
392        This builds the service level interface classes
393        ================================================================= -->
394
395   <target name="bld.calsvci"
396           depends="init,bld.common,bld.ical"
397           description="Build calendar service interface classes jar">
398       <ant antfile="${org.bedework.calsvci.base}/build.xml" inheritrefs="true"
399            target="build" />
400   </target>
401
402   <!-- ======================== calsvc target =======================
403        This builds the service level interface implementation classes
404        ================================================================= -->
405
406   <target name="bld.calsvc"
407           depends="init,bld.common,bld.mail"
408           description="Build calendar service interface implementation classes jar">
409       <ant antfile="${org.bedework.calsvc.base}/build.xml" inheritrefs="true"
410            target="build" />
411   </target>
412
413   <!-- ======================== ical target =======================
414        This builds the classes associated with ical (rfc2445 etc)
415        ================================================================= -->
416
417   <target name="bld.ical"
418           depends="init,bld.common,bld.locale"
419           description="Build icalendar classes jar">
420       <ant antfile="${org.bedework.ical.base}/build.xml" inheritrefs="true"
421            target="build" />
422   </target>
423
424   <!-- ======================== appcommon target =======================
425        This builds a jar file which provides application support.
426        ================================================================= -->
427
428   <target name="bld.appcommon"
429           depends="init,bld.calsvci"
430           description="Build calendar service interface classes jar">
431       <ant antfile="${org.bedework.appcommon.base}/build.xml" inheritrefs="true"
432            target="build" />
433   </target>
434
435   <!-- ======================== webcommon target =======================
436        This builds the web common classes jar.
437        ================================================================= -->
438
439   <target name="bld.webcommon"
440           depends="bld.appcommon"
441           description="Build calendar web common classes jar">
442       <ant antfile="${org.bedework.webcommon.base}/build.xml" inheritrefs="true"
443            target="build" />
444   </target>
445
446   <!-- ======================= web client Targets ======================
447        This builds the web applications jars.
448        ================================================================= -->
449
450   <target name="bld.webadmin"
451           depends="init,bld.webcommon"
452           description="Build calendar webadmin suite">
453     <ant antfile="${org.bedework.webadmin.base}/build.xml" inheritrefs="true"
454            target="build" />
455   </target>
456
457   <target name="bld.webclient"
458           depends="init,bld.webcommon"
459           description="Build calendar webclient suite">
460     <ant antfile="${org.bedework.webclient.base}/build.xml" inheritrefs="true"
461            target="build" />
462   </target>
463
464   <!-- ======================== synchml Targets ========================
465        *
466        *  NOTE: Incomplete and under development
467        * The following comments map out an approach rather than document the
468        * facts
469        This builds the synchml library and applications.
470        Many build properties are taken from the appsuite clones property files.
471        To build a version for your site you should probably copy and modify the
472                   appsuite/clones/democal.properties
473        file and change the value of org.bedework.clone.name to the name of your
474        new clone.
475
476        To build more than  one appsuite duplicate the ant task
477        invocation below with a different clone name in each.
478        ================================================================= -->
479
480   <target name="bld.synchml"
481           depends="init,bld.appcommon,bld.calsvci,bld.ical,bld.calsvc,bld.webcommon"
482           description="Build calendar synchml suite">
483     <ant antfile="${org.bedework.synchml.base}/build.xml" inheritrefs="true"
484            target="build"  >
485       <property name="org.bedework.clone.name" value="${org.bedework.clone.default}" />
486     </ant>
487   </target>
488
489   <target name="bld.synchml.debug"
490           depends="init,bld.appcommon,bld.calsvci,bld.ical,bld.calsvc,bld.webcommon"
491           description="Build calendar synchml suite">
492     <ant antfile="${org.bedework.synchml.base}/build.xml" inheritrefs="true"
493            target="build" >
494       <property name="org.bedework.clone.name" value="${org.bedework.clone.default}" />
495       <property name="app.debug.val" value="9" />
496     </ant>
497   </target>
498
499   <!-- ======================== caldav Targets ========================
500        *
501        *  NOTE: Incomplete and under development
502        ================================================================= -->
503
504   <target name="bld.caldav" if="org.bedework.build.caldav"
505           depends="init,bld.appcommon"
506           description="Build calendar caldav suite">
507     <ant antfile="${org.bedework.caldav.base}/build.xml" inheritrefs="true"
508            target="build" />
509   </target>
510
511   <!-- ======================== config Target ========================
512        This builds the config and deploy application
513        ================================================================= -->
514
515   <target name="bld.config"
516           depends="init"
517           description="Build calendar config and deploy module">
518     <ant antfile="${org.bedework.config.base}/build.xml" inheritrefs="true"
519            target="build" />
520   </target>
521
522   <!-- ======================== timers Targets ========================
523        This builds some timing service classes and applications
524        ================================================================= -->
525
526   <target name="bld.timers"
527           depends="init,bld.appcommon"
528           description="Build calendar timed services suite">
529     <ant antfile="${org.bedework.timers.base}/build.xml" inheritrefs="true"
530            target="build" >
531       <property name="org.bedework.clone.name" value="${org.bedework.clone.default}" />
532     </ant>
533   </target>
534
535   <target name="bld.timers.debug"
536           depends="init,bld.appcommon"
537           description="Build calendar timed services suite">
538     <ant antfile="${org.bedework.timers.base}/build.xml" inheritrefs="true"
539            target="build" >
540       <property name="app.debug.val" value="9" />
541       <property name="org.bedework.clone.name" value="${org.bedework.clone.default}" />
542     </ant>
543   </target>
544
545   <target name="bld.dumprestore"
546           depends="init,bld.appcommon"
547           description="Build calendar dumprestore suite">
548     <ant antfile="${org.bedework.dumprestore.base}/build.xml" inheritrefs="true"
549          target="build" />
550   </target>
551
552   <!-- ======================== tools Targets ========================
553        This builds the tools
554
555        To build more than  one appsuite duplicate the ant task
556        invocation below with a different clone name in each.
557        ================================================================= -->
558
559   <target name="build.tools"
560           depends="init,bld.appcommon"
561           description="Build calendar tools suite">
562     <ant antfile="${org.bedework.tools.base}/build.xml" inheritrefs="true"
563            target="build" />
564   </target>
565
566   <target name="dumpdb" depends="init">
567     <ant antfile="${org.bedework.dumprestore.base}/build.xml" inheritrefs="true"
568            target="dumpdb" />
569   </target>
570
571   <target name="restoredb" depends="init">
572     <ant antfile="${org.bedework.dumprestore.base}/build.xml" inheritrefs="true"
573            target="restoredb" />
574   </target>
575
576   <target name="initdb" depends="init">
577     <ant antfile="${org.bedework.dumprestore.base}/build.xml" inheritrefs="true"
578            target="initdb" />
579   </target>
580
581   <target name="tzconvert" depends="init">
582     <ant antfile="${org.bedework.tools.base}/build.xml" inheritrefs="true"
583            target="tzconvert" />
584   </target>
585
586   <!-- ======================== test target =======================
587        This builds the test suite
588        ================================================================= -->
589
590   <target name="bld.test"
591           depends="init,bld.core,bld.appcommon,bld.synchml"
592           description="Build all calendar test jars">
593       <ant antfile="${org.bedework.testsuite.base}/build.xml" inheritrefs="true"
594            target="build" />
595   </target>
596
597   <target name="run.test"
598           depends="init,bld.core,bld.access,bld.appcommon,bld.synchml"
599           description="Run JUnit tests and generate a report">
600       <ant antfile="${org.bedework.testsuite.base}/build.xml" inheritrefs="true"
601            target="run.unittest" />
602   </target>
603
604   <target name="bld.httptest"
605           depends="init"
606           description="Build calendar http test suite classes jar">
607       <ant antfile="${org.bedework.testsuite.base}/build.xml" inheritrefs="true"
608            target="build.httptest" />
609   </target>
610
611   <target name="run.httptest"
612           depends="init"
613           description="Run calendar http test suite classes jar">
614     <!-- Define location of run-time env.properties -->
615     <property name="uwcal.env.properties.root"
616               location="${uwcal.test.env.properties.root}" />
617
618       <ant antfile="${org.bedework.testsuite.base}/build.xml" inheritrefs="true"
619            target="run.httptest" />
620   </target>
621
622   <target name="synchmltest"
623           depends="bld.test"
624           description="Run calendar synchml test">
625     <!-- Define location of run-time env.properties -->
626     <property name="uwcal.env.properties.root"
627               location="${uwcal.test.env.properties.root}" />
628
629     <ant antfile="${org.bedework.testsuite.base}/build.xml" inheritrefs="true"
630          target="synchmltest" />
631   </target>
632
633   <!-- ======================== schema target =======================
634        This builds the ddl from the hibernate schema
635        ================================================================= -->
636
637   <target name="schema" depends="init"
638           description="Generate schema from mapping files">
639     <input message="text only? no will update db with new schema "
640            validargs="yes,no"
641            addproperty="schema.text.only" />
642
643     <property name="schema.run.base"
644               location="${org.bedework.temp.home}/schema"/>
645     <property name="schema.run.resources"
646               location="${schema.run.base}/resources"/>
647
648     <delete dir="${schema.run.resources}" />
649     <mkdir dir="${schema.run.resources}" />
650     <copy tofile="${schema.run.resources}/log4j.xml"
651           file="${org.bedework.testsuite.base}/resources/log4j.xml" />
652     <property name="org.bedework.schema.hibernate.properties"
653               location="${org.bedework.testsuite.base}/resources/hibernate.properties" />
654     <copy todir="${schema.run.resources}"
655           file="${org.bedework.schema.hibernate.properties}" />
656
657     <property name="org.bedework.hibernate.schema.properties"
658               location="${schema.run.resources}/hibernate.properties" />
659
660     <path id="schema.cp">
661       <fileset dir="${org.bedework.default.lib}">
662          <include name="**/*.jar"/>
663       </fileset>
664       <!--
665       <fileset dir="${org.bedework.temp.jars}">
666          <include name="*.jar"/>
667       </fileset>
668       -->
669       <fileset dir="${hibernate.jars.dir}">
670          <include name="**/*.jar"/>
671       </fileset>
672       <pathelement location="${log4j.jar}"/>
673
674       <!-- for commons stuff -->
675       <fileset dir="${struts.dir}">
676          <include name="commons*.jar"/>
677       </fileset>
678       <pathelement location="${org.bedework.access.jar}"/>
679       <pathelement location="${org.bedework.calfacadeshared.jar}"/>
680
681       <pathelement location="${org.bedework.core.base}/resources"/>
682       <pathelement location="${schema.run.resources}"/>
683       <pathelement location="${schema.run.resources}/hibernate.properties"/>
684       <!--
685       <fileset dir="${org.bedework.hsqldb.dir}/lib">
686          <include name="*.jar"/>
687       </fileset>
688       -->
689     </path>
690
691     <property name="cp" refid="schema.cp" />
692     <echo message="***************cp: ${cp}"/>
693
694     <taskdef name="schemaexport"
695              classname="org.hibernate.tool.hbm2ddl.SchemaExportTask">
696       <classpath refid="schema.cp"/>
697     </taskdef>
698
699     <!-- text="no" causes task to create db. Requires db system to be running
700          and jdbc drivers on class path
701          -->
702     <schemaexport properties="${org.bedework.hibernate.schema.properties}"
703                   quiet="no"
704                   text="${schema.text.only}"
705                   drop="no"
706                   delimiter=";"
707                   output="schema-export.sql">
708                   <fileset dir="${org.bedework.core.base}/resources/hbms">
709                     <include name="*.hbm.xml"/>
710                   </fileset>
711     </schemaexport>
712   </target>
713
714 <!-- ===================== Quickstart target ===============================
715      The "quickstart.build" target 'builds' quickstart by copying particular
716      files into the quickstart directory.  We assume quickstart consists of
717      a directory containing 4 subdirectories:  tomcat, hsqldb, ant, and
718      this one (calendar3), along with the 3 ant executable files.  This
719      target copies files from calendar3 into the quickstart and tomcat
720      directories to create a calendar version that works out of the box
721      (once ant deploy is run).
722      =================================================================== -->
723
724   <target name="quickstart.build" depends="init"
725           description="copy files to quickstart directories">
726
727     <property name="quickstart.files.dir"
728               location="${calendar.dir}/quickstartFiles"/>
729
730     <copy todir="${org.bedework.appserver.dir}/conf" overwrite="yes">
731        <fileset dir="${quickstart.files.dir}/tomcat.conf" />
732     </copy>
733
734     <copy todir="${calendar.dir}/.." overwrite="yes">
735        <fileset dir="${quickstart.files.dir}/root" />
736     </copy>
737   </target>
738
739   <!-- Create a version using acegi security
740     -->
741   <target name="quickstart.acegi.build" depends="init"
742           description="copy files to quickstart directories">
743
744     <property name="quickstart.files.dir"
745               location="${calendar.dir}/quickstartFiles"/>
746
747     <copy todir="${org.bedework.appserver.dir}/common/lib" overwrite="yes">
748        <fileset dir="${calendar.dir}/lib/acegi"
749                 excludes="acegi-security-catalina-server.jar" />
750     </copy>
751
752     <copy todir="${org.bedework.appserver.dir}/server/lib" overwrite="yes">
753        <fileset dir="${calendar.dir}/lib/acegi"
754                 includes="acegi-security-catalina-server.jar" />
755     </copy>
756
757     <copy tofile="${org.bedework.appserver.dir}/conf/server.xml" overwrite="yes"
758           file="${quickstart.files.dir}/tomcat.conf/server.acgi.xml" />
759
760     <copy tofile="${org.bedework.appserver.dir}/conf/acegisecurity.xml" overwrite="yes"
761           file="${quickstart.files.dir}/tomcat.conf/acegisecurity.xml" />
762
763     <copy todir="${calendar.dir}/.." overwrite="yes">
764        <fileset dir="${quickstart.files.dir}/root" />
765     </copy>
766   </target>
767 </project>
Note: See TracBrowser for help on using the browser.