root/trunk/build/quickstart/linux/bw

Revision 3564 (checked in by douglm, 1 year ago)

config for eventreg

  • Property svn:mergeinfo set to
  • Property svn:executable set to *
Line 
1 #! /bin/sh
2
3 #
4 # This file is included by the quickstart script file "bw" so that it can live
5 # within the svn repository.
6 #
7
8 ANT_HOME=`dirname "$PRG"`/apache-ant-1.7.0
9 ANT_HOME=`cd "$ANT_HOME" && pwd`
10
11 #ant_listener="-listener org.apache.tools.ant.listener.Log4jListener"
12 #ant_xmllogfile="-DXmlLogger.file=log.xml"
13 #ant_logger="-logger org.apache.tools.ant.XmlLogger"
14
15 ant_listener=
16 ant_xmllogfile=
17 ant_logger=
18
19 ant_loglevel="-quiet"
20 bw_loglevel=""
21
22 # Projects we need to update - these are the svn projects - not internal variables
23 # or user parameters.
24 updateProjects="access"
25 updateProjects="$updateProjects  bedenote"
26 updateProjects="$updateProjects  bedework"
27 updateProjects="$updateProjects  bedework-carddav"
28 updateProjects="$updateProjects  bwannotations"
29 updateProjects="$updateProjects  bwcalcore"
30 updateProjects="$updateProjects  bwcaldav"
31 updateProjects="$updateProjects  bwcalFacade"
32 updateProjects="$updateProjects  bwdeployutil"
33 updateProjects="$updateProjects  bwical"
34 updateProjects="$updateProjects  bwinterfaces"
35 updateProjects="$updateProjects  bwmisc"
36 updateProjects="$updateProjects  bwsysevents"
37 updateProjects="$updateProjects  bwtzsvr"
38 updateProjects="$updateProjects  bwwebapps"
39 updateProjects="$updateProjects  bwxml"
40 updateProjects="$updateProjects  cachedfeeder"
41 updateProjects="$updateProjects  caldav"
42 updateProjects="$updateProjects  davutil"
43 updateProjects="$updateProjects  dumprestore"
44 # updateProjects="$updateProjects  eventreg"
45 # updateProjects="$updateProjects  geronimo-hib"
46 updateProjects="$updateProjects  genkeys"
47 updateProjects="$updateProjects  indexer"
48 updateProjects="$updateProjects  rpiutil"
49 updateProjects="$updateProjects  synch"
50 updateProjects="$updateProjects  webdav"
51
52 # Projects we will build - pkgdefault (bedework) is built if nothing specified
53 pkgdefault=yes
54 access=
55 bedenote=
56 bedework=
57 bwannotations=
58 bwcalcore=
59 bwcaldav=
60 bwcalfacade=
61 bwdeployutil=
62 bwicalendar=
63 bwinterfaces=
64 bwmisc=
65 bwsysevents=
66 bwtools=
67 bwwebapps=
68 bwxml=
69 caldav=
70 caldavTest=
71 carddav=
72 catsvr=
73 client=
74 davutil=
75 dumprestore=
76 eventreg=
77 exchgGateway=
78 genkeys=
79 geronimoHib=
80 indexer=
81 monitor=
82 naming=
83 rpiutil=
84 synch=
85 testsuite=
86 tzsvr=
87 webdav=
88
89 # Special targets - avoiding dependencies
90
91 deploylog4j=
92 deployActivemq=
93 deploySolr=
94 dirstart=
95
96 specialTarget=
97
98 echo ""
99 echo "  Bedework Calendar System"
100 echo "  ------------------------"
101 echo ""
102
103 PRG="$0"
104
105 usage() {
106   echo "  $PRG ACTION"
107   echo "  $PRG [CONFIG-SOURCE] [CONFIG] [PROJECT] [ -offline ] [LOG_LEVEL] [ target ] "
108   echo ""
109   echo " where:"
110   echo ""
111   echo "   ACTION defines an action to take usually in the context of the quickstart."
112   echo "    In a deployed system many of these actions are handled directly by a"
113   echo "    deployed application. ACTION may be one of"
114   echo "      -updateall  Does an svn update of all projects"
115   echo "      -zoneinfo   builds zoneinfo data for the timezones server"
116   echo "                  requires -version and -tzdata parameters.   "
117   echo "                  NOTE: build depends on glib2 and only works on Linux/Unix"
118   echo "      -buildwebcache     builds webcache"
119   echo "      -deploywebcache    deploys webcache"
120   echo "      -deployurlbuilder  deploys url/widget builder"
121   echo ""
122   echo "   CONFIG-SOURCE optionally defines the location of configurations and"
123   echo "                 is one or none of  "
124   echo "     -quickstart    to use the configurations within the quickstart"
125   echo "     -bwchome path  to specify the location of the bwbuild directory"
126   echo "   The default is to look in the user home for the bwbuild directory."
127   echo ""
128   echo "   CONFIG optionally defines the configuration to build"
129   echo "      -bwc configname"
130   echo ""
131   echo "   -offline     Build without attempting to retrieve library jars"
132   echo ""
133   echo "   LOG_LEVEL sets the level of logging and can be"
134   echo "      -log-silent   Nearly silent"
135   echo "      -log-quiet    The default"
136   echo "      -log-inform   A little more noisy"
137   echo "      -log-verbose  Noisier"
138   echo "      -log-configs  Some info about configurations"
139   echo "      -ant-debug    Vast amounts of ant output"
140   echo "      -build-debug  Some bedework build debug output"
141   echo ""
142   echo "   target       Special target or Ant target to execute"
143   echo ""
144   echo "   Special targets"
145   echo "      deploylog4j       deploys a log4j configuration"
146   echo "      deployActivemq    deploys the Activemq config"
147   echo "      deploySolr        deploys the quickstart solr config"
148   echo ""
149   echo "   PROJECT optionally defines the package to build. If omitted the main"
150   echo "           bedework calendar system will be built otherwise it is one of"
151   echo "           the core, ancillary or experimental targets below:"
152   echo ""
153   echo "   Core sub-projects: required for a functioning system"
154   echo "     -access       Target is for the access classes"
155   echo "     -bwann        Target is for the annotation classes"
156   echo "     -bwcalcore    Target is for the bedework core api implementation"
157   echo "     -bwcaldav     Target is for the bedework CalDAV implementation"
158   echo "     -bwcalfacade  Target is for the bedework api interface classes"
159   echo "     -bwicalendar  Target is for the bedework icalendar classes"
160   echo "     -bwinterfaces Target is for the bedework service and api interfaces"
161   echo "     -bwmisc       Target is for misc classes"
162   echo "     -bwsysevents  Target is for the system JMS event classes"
163   echo "     -bwwebapps    Target is for the bedework web ui classes"
164   echo "     -bwxml        Target is for the Bedework XML schemas build"
165   echo "                        (usually built automatically be dependent projects"
166   echo "     -caldav       Target is for the generic CalDAV server"
167   echo "     -carddav      Target is for the CardDAV build"
168   echo "     -carddav deploy-addrbook    To deploy the Javascript Addressbook client."
169   echo "     -davutil      Target is for the Bedework dav util classes"
170   echo "     -dumprestore  Target is for the Bedework dump/restore service"
171   echo "     -eventreg     Target is for the event registration service build"
172   echo "     -genkeys      Target is for the genkeys module build"
173   echo "     -indexer      Target is for the Bedework indexer service"
174   echo "     -rpiutil      Target is for the Bedework util classes"
175   echo "     -synch        Target is for the synch build"
176   echo "     -tzsvr        Target is for the timezones server build"
177   echo "     -webdav       Target is for the WebDAV build"
178   echo "   Ancillary projects: not required"
179   echo "     -bwtools      Target is for the Bedework tools build"
180   echo "     -caldavTest   Target is for the CalDAV Test build"
181   echo "     -deployutil   Target is for the Bedework deployment classes"
182   echo "     -monitor      Target is for the bedework monitor application"
183   echo "     -testsuite    Target is for the bedework test suite"
184   echo "   Experimental projects: no guarantees"
185   echo "     -catsvr       Target is for the Catsvr build"
186   echo "     -client       Target is for the bedework client application build"
187   echo "     -naming       Target is for the abstract naming api"
188   echo ""
189   echo "   Invokes ant to build or deploy the Bedework system. Uses a configuration"
190   echo "   directory which contains one directory per configuration."
191   echo ""
192   echo "   Within each configuration directory we expect a file called build.properties"
193   echo "   which should point to the property and options file needed for the deploy process"
194   echo ""
195   echo "   In general these files will be in the same directory as build.properties."
196   echo "   The environment variable BEDEWORK_CONFIG contains the path to the current"
197   echo "   configuration directory and can be used to build a path to the other files."
198   echo ""
199 }
200
201 errorUsage() {
202   echo "*******************************************************************************************"
203   echo "Error: $1"
204   echo "*******************************************************************************************"
205   echo
206   echo "Sleeping 5 seconds before displaying usage. Safe to ctrl-C."
207   sleep 5
208   echo ""
209   usage
210   exit 1
211 }
212
213 # ----------------------------------------------------------------------------
214 # Update the projects
215 # ----------------------------------------------------------------------------
216 actionUpdateall() {
217   for project in $updateProjects
218   do
219     if [ ! -d "$project" ] ; then
220       echo "*********************************************************************"
221       echo "Project $project is missing. Check it out from the repository"
222       echo "*********************************************************************"
223       exit 1
224     else
225       echo "*********************************************************************"
226       echo "Updating project $project"
227       echo "*********************************************************************"
228       svn update $project
229     fi
230   done
231  
232   exit 0
233 }
234
235 usageZoneinfo() {
236   echo ""
237   echo "$PRG -zoneinfo -fetch"
238   echo "to have data fetched and processed. Alternatively to process a specifi set of data"
239   echo "$PRG -zoneinfo -version VERSION -tzdata path-to-data"
240   echo "for example:"
241   echo "$PRG -zoneinfo -version 2010m -tzdata /data/olson/tzdata2010m.tar.gz"
242   echo ""
243   echo "The data can be obtained manually in the following manner:"
244   echo "  wget 'ftp://elsie.nci.nih.gov/pub/tz*.tar.gz'"
245   echo ""
246   echo "The version is the '*' part of the name"
247  
248   exit 1
249 }
250
251 # Change to the next project to build. Exit if we're done.
252 # The order below reflects the dependencies
253 setDirectory() {
254     specialTarget=
255    
256 #     Special targets
257         if [ "$dirstart" != "" ] ; then
258           cd $QUICKSTART_HOME
259           specialTarget=dirstart
260       dirstart=
261           return
262         fi
263
264         if [ "$deploylog4j" != "" ] ; then
265           cd $QUICKSTART_HOME
266           specialTarget=deploylog4j
267       deploylog4j=
268           return
269         fi
270
271         if [ "$deployActivemq" != "" ] ; then
272           cd $QUICKSTART_HOME
273           specialTarget=deployActivemq
274       deployActivemq=
275           return
276         fi
277
278         if [ "$deploySolr" != "" ] ; then
279           cd $QUICKSTART_HOME
280           specialTarget=deploySolr
281       deploySolr=
282           return
283         fi
284        
285 #     projects
286
287         if [ "$geronimoHib" != "" ] ; then
288           cd $QUICKSTART_HOME/geronimo-hibernate
289       geronimoHib=
290           return
291         fi
292
293         if [ "$bedenote" != "" ] ; then
294           cd $QUICKSTART_HOME/bedenote
295       bedenote=
296           return
297         fi
298
299         if [ "$bwdeployutil" != "" ] ; then
300           cd $QUICKSTART_HOME/bwdeployutil
301       bwdeployutil=
302           return
303         fi
304
305         if [ "$bwxml" != "" ] ; then
306           cd $QUICKSTART_HOME/bwxml
307       bwxml=
308           return
309         fi
310        
311         if [ "$rpiutil" != "" ] ; then
312           cd $QUICKSTART_HOME/rpiutil
313       rpiutil=
314           return
315         fi
316        
317         if [ "$access" != "" ] ; then
318           cd $QUICKSTART_HOME/access
319       access=
320           return
321         fi
322        
323         if [ "$davutil" != "" ] ; then
324           cd $QUICKSTART_HOME/davutil
325       davutil=
326           return
327         fi
328        
329         if [ "$eventreg" != "" ] ; then
330           cd $QUICKSTART_HOME/eventreg
331       eventreg=
332           return
333         fi
334        
335         if [ "$webdav" != "" ] ; then
336           cd $QUICKSTART_HOME/webdav
337       webdav=
338           return
339         fi
340        
341         if [ "$caldav" != "" ] ; then
342           cd $QUICKSTART_HOME/caldav
343       caldav=
344           return
345         fi
346        
347         if [ "$caldavTest" != "" ] ; then
348           cd $QUICKSTART_HOME/caldavTest
349       caldavTest=
350           return
351         fi
352        
353         if [ "$carddav" != "" ] ; then
354           cd $QUICKSTART_HOME/bedework-carddav
355       carddav=
356           return
357         fi
358
359         if [ "$bwannotations" != "" ] ; then
360           cd $QUICKSTART_HOME/bwannotations
361       bwannotations=
362           return
363         fi
364
365         if [ "$bwcalfacade" != "" ] ; then
366           cd $QUICKSTART_HOME/bwcalFacade
367       bwcalfacade=
368           return
369         fi
370
371         if [ "$bwinterfaces" != "" ] ; then
372           cd $QUICKSTART_HOME/bwinterfaces
373       bwinterfaces=
374           return
375         fi
376
377         if [ "$genkeys" != "" ] ; then
378           cd $QUICKSTART_HOME/genkeys
379       genkeys=
380           return
381         fi
382
383         if [ "$bwsysevents" != "" ] ; then
384           cd $QUICKSTART_HOME/bwsysevents
385       bwsysevents=
386           return
387         fi
388
389         if [ "$bwicalendar" != "" ] ; then
390           cd $QUICKSTART_HOME/bwical
391       bwicalendar=
392           return
393         fi
394
395         if [ "$bwmisc" != "" ] ; then
396           cd $QUICKSTART_HOME/bwmisc
397       bwmisc=
398           return
399         fi
400        
401         if [ "$bwwebapps" != "" ] ; then
402           cd $QUICKSTART_HOME/bwwebapps
403       bwwebapps=
404           return
405         fi
406
407         if [ "$bwcaldav" != "" ] ; then
408           cd $QUICKSTART_HOME/bwcaldav
409       bwcaldav=
410           return
411         fi
412
413         if [ "$bwcalcore" != "" ] ; then
414           cd $QUICKSTART_HOME/bwcalcore
415       bwcalcore=
416           return
417         fi
418        
419         if [ "$catsvr" != "" ] ; then
420           cd $QUICKSTART_HOME/catsvr
421       catsvr=
422           return
423         fi
424        
425         if [ "$client" != "" ] ; then
426           cd $QUICKSTART_HOME/bwclient
427       client=
428           return
429         fi
430        
431         if [ "$indexer" != "" ] ; then
432           cd $QUICKSTART_HOME/indexer
433       indexer=
434           return
435         fi
436        
437         if [ "$dumprestore" != "" ] ; then
438           cd $QUICKSTART_HOME/dumprestore
439       dumprestore=
440           return
441         fi
442        
443         if [ "$bedework" != "" ] ; then
444           cd $QUICKSTART_HOME
445       bedework=
446           return
447         fi
448        
449         if [ "$monitor" != "" ] ; then
450           cd $QUICKSTART_HOME/MonitorApp
451       monitor=
452           return
453         fi
454        
455         if [ "$naming" != "" ] ; then
456           cd $QUICKSTART_HOME/bwnaming
457       naming=
458           return
459         fi
460        
461         if [ "$exchgGateway" != "" ] ; then
462           cd $QUICKSTART_HOME/exchgGateway
463       exchgGateway=
464           return
465         fi
466
467         if [ "$synch" != "" ] ; then
468           cd $QUICKSTART_HOME/synch
469       synch=
470           return
471         fi
472        
473         if [ "$testsuite" != "" ] ; then
474           cd $QUICKSTART_HOME/testsuite
475       testsuite=
476           return
477         fi
478        
479         if [ "$tzsvr" != "" ] ; then
480           cd $QUICKSTART_HOME/bwtzsvr
481       tzsvr=
482           return
483         fi
484        
485         if [ "$bwtools" != "" ] ; then
486           cd $QUICKSTART_HOME/bwtools
487       bwtools=
488           return
489         fi
490
491 # Nothing left to do
492     echo "Finished at $(date)" 
493         exit 0;
494 }
495
496 # ----------------------------------------------------------------------------
497 # Build zoneinfo - require -version -tzdata
498 # tzdata file can be obtained via http://www.twinsun.com/tz/tz-link.htm or
499 # more directly from ftp://elsie.nci.nih.gov/pub/
500 # The version parameter value should be the version code from the tzdata name
501 # ----------------------------------------------------------------------------
502 actionZoneinfo() {
503   bwtzsvr="$QUICKSTART_HOME/bwtzsvr"
504   bwresources="$bwtzsvr/resources"
505
506   rm -rf /tmp/bedework
507   mkdir /tmp/bedework
508   mkdir /tmp/bedework/timezones
509   mkdir /tmp/bedework/timezones/data
510  
511   cd /tmp/bedework/timezones
512  
513   shift
514  
515   if [ "$1" = "-fetch" ] ; then
516     shift
517     cd data
518     wget 'ftp://elsie.nci.nih.gov/pub/tz*.tar.gz'
519     gzip -dc tzdata*.tar.gz | tar -xf -
520    
521     filename=$(basename `ls tzdata*`)
522     version=$( echo $filename | cut -c 7-11 )
523    
524     tzdata="/tmp/bedework/timezones/data/$filename"
525    
526     cd ..
527    
528     echo version=$version
529     echo tzdata=$tzdata
530   else
531     if [ "$1" != "-version" ] ; then
532       echo "got $1"
533       echo "Must supply -version parameter for -zoneinfo"
534       usageZoneinfo
535     fi
536    
537     shift
538
539     echo "got $1"
540     version=$1
541
542     shift
543    
544     if [ "$1" != "-tzdata" ] ; then
545       echo "Must supply -tzdata parameter for -zoneinfo"
546       usageZoneinfo
547     fi
548    
549     shift
550
551     tzdata=$1
552
553     shift
554   fi
555  
556   wget http://bedework.org/downloads/lib/vzic-1.3.tgz
557   gunzip vzic-1.3.tgz
558   tar -xf vzic-1.3.tar
559
560 # copy and unpack the data
561   mkdir olsondata
562   cd olsondata
563   cp $tzdata tzdata.tar.gz
564   gunzip tzdata.tar.gz
565   tar -xf tzdata.tar
566   rm tzdata.tar
567   cd ..
568  
569 # Replace lines in the makefile. Sure real unix types can do better 
570  
571   cd vzic-1.3
572  
573   sed "s/\(^OLSON_DIR = \)\(..*$\)/\1\/tmp\/bedework\/timezones\/olsondata/" Makefile > Makefile1
574
575   sed "s/\(^PRODUCT_ID = \)\(..*$\)/\1\/bedework.org\/\/NONSGML Bedework\/\/EN/" Makefile1 > Makefile2
576
577   sed "s/\(^TZID_PREFIX = \)\(..*$\)/\1/" Makefile2 > Makefile
578  
579   make
580  
581 # omit the pure for allegedly better outlook compatability -
582 # but not altogether correct timezones 
583   ./vzic --pure
584
585   cd ..
586  
587   mkdir tzdata
588   cp -r vzic-1.3/zoneinfo tzdata
589   cp $bwresources/aliases.txt tzdata
590  
591   cd tzdata
592  
593   echo "version=$version" > info.txt
594 #  date +buildTime=%D-%T-%N >> info.txt
595   date --utc +buildTime=%Y%m%dT%H%M%SZ >> info.txt
596  
597   zip -r tzdata *
598  
599   cp tzdata.zip $bwtzsvr/dist
600  
601   echo ""
602   echo "------------------------------------------------------------------------------"
603   echo "tzdata.zip has been built and is at $bwtzsvr/dist/tzdata.zip"
604   echo "------------------------------------------------------------------------------"
605   echo ""
606  
607   exit 0
608 }
609
610 if [ -z "$JAVA_HOME" -o ! -d "$JAVA_HOME" ] ; then
611   errorUsage "JAVA_HOME is not defined correctly for bedework."
612 fi
613
614 saveddir=`pwd`
615
616 trap 'cd $saveddir' 0
617 trap "exit 2" 1 2 3 15
618
619 export QUICKSTART_HOME=$saveddir
620
621 CLASSPATH=$ANT_HOME/lib/ant-launcher.jar
622 CLASSPATH=$CLASSPATH:$QUICKSTART_HOME/bedework/build/quickstart/antlib
623
624 # Default some parameters
625
626 BWCONFIGS=
627 bwc=default
628 BWCONFIG=
629 offline=
630 quickstart=
631
632 action=
633
634 if [ "$1" = "" ] ; then
635   usage
636   exit 1
637 fi
638
639 # look for actions first
640
641 if [ "$1" = "-updateall" ] ; then
642   actionUpdateall
643 fi
644
645 if [ "$1" = "-zoneinfo" ] ; then
646   actionZoneinfo $*
647 fi
648
649 if [ "$1" = "-buildwebcache" ] ; then
650   cd $QUICKSTART_HOME/cachedfeeder
651   ./buildWebCache
652   exit
653 fi
654
655 if [ "$1" = "-deploywebcache" ] ; then
656   cd $QUICKSTART_HOME/cachedfeeder
657   $JAVA_HOME/bin/java -classpath $CLASSPATH $ant_xmllogfile -Dant.home=$ANT_HOME org.apache.tools.ant.launch.Launcher \
658                  $BWCONFIG $ant_listener $ant_logger $ant_loglevel $bw_loglevel -lib $QUICKSTART_HOME/bedework/build/quickstart/antlib deploy-webcache
659   exit
660 fi
661
662 if [ "$1" = "-deployurlbuilder" ] ; then
663   cd $QUICKSTART_HOME/cachedfeeder
664   $JAVA_HOME/bin/java -classpath $CLASSPATH $ant_xmllogfile -Dant.home=$ANT_HOME org.apache.tools.ant.launch.Launcher \
665                  $BWCONFIG $ant_listener $ant_logger $ant_loglevel $bw_loglevel -lib $QUICKSTART_HOME/bedework/build/quickstart/antlib deploy-urlbuilder
666   exit
667 fi
668
669 # ----------------------------------------------------------------------------
670 #  Here we go through looking for arguments.
671
672 #  Look firther down for wher we are specifying projects to build. I've
673 #  not tried specifying more than one but I think it would work.
674
675 #  There's a hidden default project "bedework" which you get if you don't specify
676 #  any of the below projects. That gets turned off by each of them  with
677 #        pkgdefault=
678 #  Each also turns on it's own project build and any dependencies it has.
679 #  Further up in this file is where we build each project that has been turned
680 #  on. That processing is done in dependency order. Of course this whole process
681 #  fails if we ever build in a circular dependency - that's why it's important to
682 #  do a clean build fairly regularly. So as an example
683 #   -webdav)
684 #      webdav="yes"
685 #
686 #      access="yes"
687 #      bwxml="yes"
688 #      rpiutil="yes"
689 #      pkgdefault=
690 #  Turns on the webdav build and also access, bwxml and rpiutil because it depends
691 #  on them.
692 # ----------------------------------------------------------------------------
693
694 while [ "$1" != "" ]
695 do
696   # Process the next arg
697   case $1       # Look at $1
698   in
699     -bwchome)         # Define location of configs
700       shift
701       BWCONFIGS="$1"
702       shift
703       ;;
704     -quickstart)
705       quickstart="yes"
706       shift
707       ;;
708     -usage | -help | -? | ?)
709       usage
710       exit
711       shift
712       ;;
713     -bwc)
714       shift
715       bwc="$1"
716       shift
717       ;;
718     -offline)
719       offline="-Dorg.bedework.offline.build=yes"
720       shift
721       ;;
722 # ----------------------- Log level       
723     -log-silent)
724       ant_loglevel="-quiet"
725       bw_loglevel="-Dorg.bedework.build.silent=true"
726       shift
727       ;;
728     -log-quiet)
729       ant_loglevel="-quiet"
730       bw_loglevel=""
731       shift
732       ;;
733     -log-inform)
734       ant_loglevel=""
735       bw_loglevel="-Dorg.bedework.build.inform=true"
736       shift
737       ;;
738     -log-verbose)
739       ant_loglevel="-verbose"
740       bw_loglevel="-Dorg.bedework.build.inform=true -Dorg.bedework.build.noisy=true"
741       shift
742       ;;
743     -log-configs)
744       bw_loglevel="$bw_loglevel -Dorg.bedework.build.showconfigs=true"
745       shift
746       ;;
747     -ant-debug)
748       ant_loglevel="-debug"
749       shift
750       ;;
751     -build-debug)
752       bw_loglevel="-Dorg.bedework.build.inform=true -Dorg.bedework.build.noisy=true -Dorg.bedework.build.debug=true "
753       shift
754       ;;
755 # ------------------------Special targets
756     deploylog4j)
757           deploylog4j="yes"
758       pkgdefault=
759       shift
760       ;;
761     deployActivemq)
762           deployActivemq="yes"
763       pkgdefault=
764       shift
765       ;;
766     deploySolr)
767           deploySolr="yes"
768       pkgdefault=
769       shift
770       ;;
771         dirstart)
772           dirstart="yes"
773       pkgdefault=
774       shift
775       ;;
776 # ------------------------Projects
777     -access)
778       access="yes"
779      
780       bwxml="yes"
781       rpiutil="yes"
782       pkgdefault=
783       shift
784       ;;
785     -bedenote)
786       bedenote="yes"
787       pkgdefault=
788       shift
789       ;;
790     -bwann)
791       bwannotations="yes"
792       pkgdefault=
793       shift
794       ;;
795     -bwcaldav)
796       bwcaldav="yes"
797      
798       access="yes"
799       bwannotations="yes" 
800       bwcalfacade="yes"
801       bwicalendar="yes"
802       bwinterfaces="yes"
803 #      bwmisc="yes"
804       bwsysevents="yes"
805       bwxml="yes"
806       caldav="yes"
807 #      davutil="yes"
808       rpiutil="yes"
809       webdav="yes"
810       pkgdefault=
811       shift
812       ;;
813     -bwcalcore)
814       bwcalcore="yes"
815      
816       access="yes"
817       bwannotations="yes" 
818       bwcalfacade="yes"
819       bwicalendar="yes"
820       bwinterfaces="yes"
821       bwmisc="yes"
822       bwsysevents="yes"
823       bwxml="yes"
824       caldav="yes"
825       davutil="yes"
826       rpiutil="yes"
827       webdav="yes"
828       pkgdefault=
829       shift
830       ;;
831     -bwcalfacade)
832       bwcalfacade="yes"
833    
834       access="yes"
835       bwannotations="yes"
836       bwxml="yes"
837       caldav="yes"
838       davutil="yes"
839       rpiutil="yes"
840       webdav="yes"
841       pkgdefault=
842       shift
843       ;;
844     -bwicalendar)
845       bwicalendar="yes"
846    
847       bwannotations="yes"
848       bwcalfacade="yes"
849       bwxml="yes"
850      
851       pkgdefault=
852       shift
853       ;;
854     -bwinterfaces)
855       bwinterfaces="yes"
856    
857       access="yes"
858       bwannotations="yes"
859       bwcalfacade="yes"
860       bwxml="yes"
861       caldav="yes"
862       davutil="yes"
863       rpiutil="yes"
864       webdav="yes"
865      
866       pkgdefault=
867       shift
868       ;;
869     -bwmisc)
870       bwmisc="yes"
871      
872       bwannotations="yes" 
873       bwcalfacade="yes"
874       bwicalendar="yes"
875       davutil="yes"
876       pkgdefault=
877       shift
878       ;;
879     -bwsysevents)
880       bwsysevents="yes"
881      
882       bwinterfaces="yes"
883       rpiutil="yes"
884       pkgdefault=
885       shift
886       ;;
887     -bwtools)
888       bwtools="yes"
889      
890       bwannotations="yes" 
891       bwcalfacade="yes"
892       bwinterfaces="yes"
893       bwxml="yes"
894       rpiutil="yes"
895       pkgdefault=
896       shift
897       ;;
898     -bwwebapps)
899       bwwebapps="yes"
900      
901       access="yes"
902       bwannotations="yes" 
903       bwcalfacade="yes"
904       bwicalendar="yes"
905       bwinterfaces="yes"
906       bwxml="yes"
907       caldav="yes"
908       davutil="yes"
909       rpiutil="yes"
910       webdav="yes"
911       pkgdefault=
912       shift
913       ;;
914     -bwxml)
915       bwxml="yes"
916       pkgdefault=
917       shift
918       ;;
919     -caldav)
920       caldav="yes"
921
922       access="yes"
923       bwxml="yes"
924       rpiutil="yes"
925       davutil="yes"
926       webdav="yes"
927       pkgdefault=
928       shift
929       ;;
930     -caldavTest)
931       caldavTest="yes"
932
933       access="yes"
934       bwxml="yes"
935       rpiutil="yes"
936       webdav="yes"
937       pkgdefault=
938       shift
939       ;;
940     -carddav)
941       carddav="yes"
942
943       access="yes"
944       bwxml="yes"
945       davutil="yes"
946       rpiutil="yes"
947       webdav="yes"
948       pkgdefault=
949       shift
950       ;;
951     -catsvr)
952       catsvr="yes"
953
954       access="yes"
955       bwxml="yes"
956       rpiutil="yes"
957       webdav="yes"
958       pkgdefault=
959       shift
960       ;;
961     -client)
962       client="yes"
963       pkgdefault=
964       shift
965       ;;
966     -davutil)
967       davutil="yes"
968
969       bwxml="yes"
970       rpiutil="yes"
971       pkgdefault=
972       shift
973       ;;
974     -deployutil)
975       bwdeployutil="yes"
976
977       pkgdefault=
978       shift
979       ;;
980     -dumprestore)
981       dumprestore="yes"
982      
983       access="yes"
984       bwannotations="yes" 
985       bwcalcore="yes"   
986       bwcalfacade="yes"
987       bwicalendar="yes"
988       bwinterfaces="yes"
989       bwmisc="yes"
990       bwsysevents="yes"
991       indexer="yes"
992       rpiutil="yes"
993       pkgdefault=
994       shift
995       ;;
996     -eventreg)
997       eventreg="yes"
998
999       bwxml="yes"
1000       rpiutil="yes"
1001       pkgdefault=
1002       shift
1003       ;;
1004     -genkeys)
1005       genkeys="yes"
1006      
1007       bwinterfaces="yes"
1008       rpiutil="yes"
1009       pkgdefault=
1010       shift
1011       ;;
1012     -geronimohib)
1013       geronimoHib="yes"
1014
1015       pkgdefault=
1016       shift
1017       ;;
1018     -indexer)
1019       indexer="yes"
1020      
1021       access="yes"
1022       bwannotations="yes" 
1023       bwcalcore="yes"   
1024       bwcalfacade="yes"
1025       bwicalendar="yes"
1026       bwinterfaces="yes"
1027       bwmisc="yes"
1028       bwsysevents="yes"
1029       rpiutil="yes"
1030       pkgdefault=
1031       shift
1032       ;;
1033     -monitor)
1034       monitor="yes"
1035       pkgdefault=
1036       shift
1037       ;;
1038     -naming)
1039       naming="yes"
1040       pkgdefault=
1041       shift
1042       ;;
1043     -rpiutil)
1044       rpiutil="yes"
1045
1046       bwxml="yes"
1047       pkgdefault=
1048       shift
1049       ;;
1050     -exchgGateway)
1051       exchgGateway="yes"
1052      
1053 #      access="yes"
1054       bwxml="yes"
1055 #      davutil="yes"
1056 #      rpiutil="yes"
1057       pkgdefault=
1058       shift
1059       ;;
1060     -synch)
1061       synch="yes"
1062      
1063       access="yes"
1064       bwxml="yes"
1065       davutil="yes"
1066       rpiutil="yes"
1067       pkgdefault=
1068       shift
1069       ;;
1070     -testsuite)
1071       testsuite="yes"
1072      
1073       pkgdefault="yes"
1074       shift
1075       ;;
1076     -tzsvr)
1077       tzsvr="yes"
1078       bwxml="yes"
1079       rpiutil="yes"
1080       pkgdefault=
1081       shift
1082       ;;
1083     -webdav)
1084       webdav="yes"
1085
1086       access="yes"
1087       bwxml="yes"
1088       davutil="yes"
1089       rpiutil="yes"
1090       pkgdefault=
1091       shift
1092       ;;
1093     -*)
1094       usage
1095       exit 1
1096       ;;
1097     *)
1098       # Assume we've reached the target(s)
1099       break
1100       ;;
1101   esac
1102 done
1103
1104 if [ "$pkgdefault" = "yes" ] ; then
1105   bedework="yes"
1106
1107   access="yes"
1108   bwannotations="yes" 
1109   bwcalcore="yes"   
1110   bwcaldav="yes"   
1111   bwcalfacade="yes"
1112   bwicalendar="yes"
1113   bwinterfaces="yes"
1114   bwmisc="yes"
1115   bwsysevents="yes"
1116   bwwebapps="yes"
1117   bwxml="yes"
1118   caldav="yes"
1119   davutil="yes"
1120   dumprestore="yes"
1121   indexer="yes"
1122   rpiutil="yes"
1123   webdav="yes"
1124 fi
1125
1126 if [ "$quickstart" != "" ] ; then
1127   if [ "$BWCONFIGS" != "" ] ; then
1128     errorUsage "Cannot specify both -quickstart and -bwchome"
1129   fi
1130   if [ "$bwc" = "jboss" ] ; then
1131         errorUsage "The jboss configuration has been removed from the quickstart.  It is now the default.  Remove the '-bwc jboss' option."
1132   fi
1133
1134   BWCONFIGS=$QUICKSTART_HOME/bedework/config/bwbuild
1135 elif [ "$BWCONFIGS" = "" ] ; then
1136   BWCONFIGS=$HOME/bwbuild
1137 fi
1138
1139 export BEDEWORK_CONFIGS_HOME=$BWCONFIGS
1140 export BEDEWORK_CONFIG=$BWCONFIGS/$bwc
1141
1142 if [ ! -d "$BEDEWORK_CONFIGS_HOME/.platform" ] ; then
1143   errorUsage "Configurations directory $BEDEWORK_CONFIGS_HOME is missing directory '.platform'."
1144 fi
1145
1146 if [ ! -d "$BEDEWORK_CONFIGS_HOME/.defaults" ] ; then
1147   errorUsage "Configurations directory $BEDEWORK_CONFIGS_HOME is missing directory '.defaults'."
1148 fi
1149
1150 if [ ! -f "$BEDEWORK_CONFIG/build.properties" ] ; then
1151   errorUsage "Configuration $BEDEWORK_CONFIG does not exist or is not a bedework configuration."
1152 fi
1153
1154 # Make available for ant
1155 export BWCONFIG="-Dorg.bedework.build.properties=$BEDEWORK_CONFIG/build.properties"
1156
1157 echo "BWCONFIGS=$BWCONFIGS"
1158 echo "BWCONFIG=$BWCONFIG"
1159
1160 javacmd="$JAVA_HOME/bin/java -classpath $CLASSPATH"
1161 # Build (of bwxml) blew up with permgen error
1162 javacmd="$javacmd -Xmx512M -XX:MaxPermSize=512M"
1163
1164 javacmd="$javacmd $ant_xmllogfile $offline"
1165 javacmd="$javacmd -Dant.home=$ANT_HOME org.apache.tools.ant.launch.Launcher"
1166 javacmd="$javacmd $BWCONFIG"
1167 javacmd="$javacmd $ant_listener $ant_logger $ant_loglevel $bw_loglevel"
1168 javacmd="$javacmd -lib $QUICKSTART_HOME/bedework/build/quickstart/antlib"
1169
1170 while true
1171 do
1172   setDirectory
1173  
1174   if [ "$specialTarget" != "" ] ; then
1175     $javacmd $specialTarget
1176   else 
1177 #    echo $javacmd $*
1178     $javacmd $*
1179   fi
1180 done
1181  
Note: See TracBrowser for help on using the browser.