| 1 |
<?xml version="1.0"?> |
|---|
| 2 |
|
|---|
| 3 |
<!-- =================================================================== |
|---|
| 4 |
This file is imported by buildsh.xml and others and adds the targets: |
|---|
| 5 |
doHibProps: builds a set of properties for the service |
|---|
| 6 |
addLibs: add libraries for this platform |
|---|
| 7 |
addResources: add anything we want in the resources directory |
|---|
| 8 |
addExtras: add scripts for runnable versions and META-INF for |
|---|
| 9 |
jboss services etc. |
|---|
| 10 |
deployService: deploy the service |
|---|
| 11 |
=================================================================== --> |
|---|
| 12 |
|
|---|
| 13 |
<project name="bedework.platformService" default="doHibProps" > |
|---|
| 14 |
<import file="${build.dir}/platforms/runnableService.xml" /> |
|---|
| 15 |
|
|---|
| 16 |
<target name="doHibProps" > |
|---|
| 17 |
<if> |
|---|
| 18 |
<istrue value="${propval.app.runnable}" /> |
|---|
| 19 |
<then> |
|---|
| 20 |
<antcall target="runnableDoHibProps" inheritRefs="true" /> |
|---|
| 21 |
</then> |
|---|
| 22 |
<else> |
|---|
| 23 |
<echo file="${app.dest.classes}/hibernate.properties"> |
|---|
| 24 |
hibernate.query.substitutions true 'T', false 'F', yes 'Y', no 'N' |
|---|
| 25 |
hibernate.dialect=${org.bedework.global.hibernate.dialect} |
|---|
| 26 |
|
|---|
| 27 |
hibernate.connection.datasource=java:${org.bedework.global.jboss.db.datasource.jndiname} |
|---|
| 28 |
|
|---|
| 29 |
hibernate.bytecode.use_reflection_optimizer=false |
|---|
| 30 |
hibernate.cache.use_second_level_cache=false |
|---|
| 31 |
# |
|---|
| 32 |
# Here for better debugging |
|---|
| 33 |
# |
|---|
| 34 |
hibernate.jdbc.batch_size=0 |
|---|
| 35 |
</echo> |
|---|
| 36 |
</else> |
|---|
| 37 |
</if> |
|---|
| 38 |
</target> |
|---|
| 39 |
|
|---|
| 40 |
<!-- ================================================================ |
|---|
| 41 |
Add libraries |
|---|
| 42 |
================================================================ --> |
|---|
| 43 |
|
|---|
| 44 |
<target name="addLibs"> |
|---|
| 45 |
<if> |
|---|
| 46 |
<istrue value="${propval.app.runnable}" /> |
|---|
| 47 |
<then> |
|---|
| 48 |
<property name="app.dest.lib" |
|---|
| 49 |
location="${app.dest.home}/lib" /> |
|---|
| 50 |
<antcall target="runnableAddLibs" inheritRefs="true" /> |
|---|
| 51 |
</then> |
|---|
| 52 |
<else> |
|---|
| 53 |
<!-- Library in sar file --> |
|---|
| 54 |
<property name="app.dest.lib" |
|---|
| 55 |
location="${app.dest.webinf}/lib" /> |
|---|
| 56 |
<antcall target="copyLibs" inheritRefs="true" /> |
|---|
| 57 |
</else> |
|---|
| 58 |
</if> |
|---|
| 59 |
</target> |
|---|
| 60 |
|
|---|
| 61 |
<!-- ================================================================ |
|---|
| 62 |
Add resources |
|---|
| 63 |
================================================================ --> |
|---|
| 64 |
|
|---|
| 65 |
<target name="addResources"> |
|---|
| 66 |
<if> |
|---|
| 67 |
<istrue value="${propval.app.runnable}" /> |
|---|
| 68 |
<then> |
|---|
| 69 |
<antcall target="runnableAddResources" inheritRefs="true" /> |
|---|
| 70 |
</then> |
|---|
| 71 |
<else> |
|---|
| 72 |
<!-- None for this platform --> |
|---|
| 73 |
</else> |
|---|
| 74 |
</if> |
|---|
| 75 |
</target> |
|---|
| 76 |
|
|---|
| 77 |
<!-- ================================================================ |
|---|
| 78 |
Add extras |
|---|
| 79 |
================================================================ --> |
|---|
| 80 |
|
|---|
| 81 |
<target name="addExtras"> |
|---|
| 82 |
<if> |
|---|
| 83 |
<istrue value="${propval.app.runnable}" /> |
|---|
| 84 |
<then> |
|---|
| 85 |
<antcall target="runnableAddExtras" inheritRefs="true" /> |
|---|
| 86 |
</then> |
|---|
| 87 |
<else> |
|---|
| 88 |
<property name="metainf.dir" |
|---|
| 89 |
location="${app.resources.dir}/../META-INF" /> |
|---|
| 90 |
|
|---|
| 91 |
<mkdir dir="${app.dest.home}/META-INF" /> |
|---|
| 92 |
|
|---|
| 93 |
<echo file="${app.dest.home}/META-INF/jboss-structure.xml"><![CDATA[<?xml version="1.0" encoding="UTF-8"?> |
|---|
| 94 |
<structure> |
|---|
| 95 |
<context> |
|---|
| 96 |
<path name=""/> |
|---|
| 97 |
<metaDataPath> |
|---|
| 98 |
<path name="META-INF"/> |
|---|
| 99 |
</metaDataPath> |
|---|
| 100 |
<classpath> |
|---|
| 101 |
<path name="classes"/> |
|---|
| 102 |
<path name="lib" suffixes=".jar" /> |
|---|
| 103 |
</classpath> |
|---|
| 104 |
</context> |
|---|
| 105 |
</structure> |
|---|
| 106 |
]]></echo> |
|---|
| 107 |
|
|---|
| 108 |
<copy todir="${app.dest.home}/META-INF"> |
|---|
| 109 |
<fileset dir="${metainf.dir}" /> |
|---|
| 110 |
<filterset refid="property.filters" /> |
|---|
| 111 |
</copy> |
|---|
| 112 |
</else> |
|---|
| 113 |
</if> |
|---|
| 114 |
</target> |
|---|
| 115 |
|
|---|
| 116 |
<target name="deployService"> |
|---|
| 117 |
<!-- copy the sar - at the moment copy the uncompressed. --> |
|---|
| 118 |
|
|---|
| 119 |
<if> |
|---|
| 120 |
<istrue value="${propval.app.runnable}" /> |
|---|
| 121 |
<then> |
|---|
| 122 |
<antcall target="runnableDeployService" inheritRefs="true" /> |
|---|
| 123 |
</then> |
|---|
| 124 |
<else> |
|---|
| 125 |
<if> |
|---|
| 126 |
<isset property="org.bedework.appserver.deploy.dir" /> |
|---|
| 127 |
<then> |
|---|
| 128 |
<property name="app.dest.home" |
|---|
| 129 |
location="${org.bedework.temp.shellscr.home}/${propval.app.zip.name}" /> |
|---|
| 130 |
|
|---|
| 131 |
<delete dir="${org.bedework.appserver.deploy.dir}/${propval.app.zip.name}.sar" /> |
|---|
| 132 |
<mkdir dir="${org.bedework.appserver.deploy.dir}/${propval.app.zip.name}.sar" /> |
|---|
| 133 |
<copy todir="${org.bedework.appserver.deploy.dir}/${propval.app.zip.name}.sar"> |
|---|
| 134 |
<fileset dir="${app.dest.home}"/> |
|---|
| 135 |
</copy> |
|---|
| 136 |
</then> |
|---|
| 137 |
</if> |
|---|
| 138 |
</else> |
|---|
| 139 |
</if> |
|---|
| 140 |
</target> |
|---|
| 141 |
|
|---|
| 142 |
<!-- ================================================================ |
|---|
| 143 |
Private target to copy libraries |
|---|
| 144 |
================================================================ --> |
|---|
| 145 |
|
|---|
| 146 |
<target name="copyLibs"> |
|---|
| 147 |
<!-- hibernate jars --> |
|---|
| 148 |
<copy todir="${app.dest.lib}" file="${org.bedework.appjar.antlr}" /> |
|---|
| 149 |
<copy todir="${app.dest.lib}" file="${org.bedework.appjar.asm-attrs}" /> |
|---|
| 150 |
<copy todir="${app.dest.lib}" file="${org.bedework.appjar.asm}" /> |
|---|
| 151 |
<copy todir="${app.dest.lib}" file="${org.bedework.appjar.cglib}" /> |
|---|
| 152 |
<copy todir="${app.dest.lib}" file="${org.bedework.appjar.dom4j}" /> |
|---|
| 153 |
<copy todir="${app.dest.lib}" file="${org.bedework.appjar.ehcache}" /> |
|---|
| 154 |
<copy todir="${app.dest.lib}" file="${org.bedework.appjar.hibernate}" /> |
|---|
| 155 |
<copy todir="${app.dest.lib}" file="${org.bedework.appjar.javassist}" /> |
|---|
| 156 |
<copy todir="${app.dest.lib}" file="${org.bedework.appjar.jgroups}" /> |
|---|
| 157 |
<copy todir="${app.dest.lib}" file="${org.bedework.appjar.jta}" /> |
|---|
| 158 |
<copy todir="${app.dest.lib}" file="${org.bedework.appjar.commons-collections}"/> |
|---|
| 159 |
<copy todir="${app.dest.lib}" file="${org.bedework.appjar.slf4j-api}" /> |
|---|
| 160 |
<copy todir="${app.dest.lib}" file="${org.bedework.appjar.slf4j-log4j12}" /> |
|---|
| 161 |
|
|---|
| 162 |
<copy todir="${app.dest.lib}" file="${org.bedework.appjar.commons-logging}"/> |
|---|
| 163 |
|
|---|
| 164 |
<!-- core files --> |
|---|
| 165 |
|
|---|
| 166 |
<copy todir="${app.dest.lib}" file="${org.bedework.appjar.rpiaccess}" /> |
|---|
| 167 |
<copy todir="${app.dest.lib}" file="${org.bedework.appjar.rpiutil}" /> |
|---|
| 168 |
<copy todir="${app.dest.lib}" file="${org.bedework.appjar.bw-davio}" /> |
|---|
| 169 |
|
|---|
| 170 |
<copy todir="${app.dest.lib}" file="${org.bedework.appjar.bw-annotations}" /> |
|---|
| 171 |
<copy todir="${app.dest.lib}" file="${org.bedework.appjar.bw-apiutil}" /> |
|---|
| 172 |
<copy todir="${app.dest.lib}" file="${org.bedework.appjar.bw-calcore}" /> |
|---|
| 173 |
<copy todir="${app.dest.lib}" file="${org.bedework.appjar.bw-calcorei}" /> |
|---|
| 174 |
<copy todir="${app.dest.lib}" file="${org.bedework.appjar.bw-calfacade}" /> |
|---|
| 175 |
<copy todir="${app.dest.lib}" file="${org.bedework.appjar.bw-calsvc}" /> |
|---|
| 176 |
<copy todir="${app.dest.lib}" file="${org.bedework.appjar.bw-calsvci}" /> |
|---|
| 177 |
<copy todir="${app.dest.lib}" file="${org.bedework.appjar.bw-icalendar}" /> |
|---|
| 178 |
<copy todir="${app.dest.lib}" file="${org.bedework.appjar.bw-logging}" /> |
|---|
| 179 |
<copy todir="${app.dest.lib}" file="${org.bedework.appjar.bw-mail}" /> |
|---|
| 180 |
<copy todir="${app.dest.lib}" file="${org.bedework.appjar.bw-sysevents}" /> |
|---|
| 181 |
|
|---|
| 182 |
<!-- any extra files--> |
|---|
| 183 |
<copy todir="${app.dest.lib}" > |
|---|
| 184 |
<fileset dir="${org.bedework.temp.extrajars.dir}" /> |
|---|
| 185 |
</copy> |
|---|
| 186 |
|
|---|
| 187 |
<!-- Some more standard libs --> |
|---|
| 188 |
<copy todir="${app.dest.lib}" file="${org.bedework.appjar.lucene-core}"/> |
|---|
| 189 |
<copy todir="${app.dest.lib}" file="${org.bedework.appjar.lucene-misc}"/> |
|---|
| 190 |
<copy todir="${app.dest.lib}" file="${org.bedework.appjar.ical4j}"/> |
|---|
| 191 |
<copy todir="${app.dest.lib}" file="${org.bedework.appjar.commons-codec}"/> |
|---|
| 192 |
<copy todir="${app.dest.lib}" file="${org.bedework.appjar.commons-digester}"/> |
|---|
| 193 |
<copy todir="${app.dest.lib}" file="${org.bedework.appjar.commons-httpclient}"/> |
|---|
| 194 |
<copy todir="${app.dest.lib}" file="${org.bedework.appjar.commons-lang}"/> |
|---|
| 195 |
<copy todir="${app.dest.lib}" file="${org.bedework.appjar.commons-ssl}"/> |
|---|
| 196 |
</target> |
|---|
| 197 |
</project> |
|---|