1 <?xml version="1.0" encoding="ISO-8859-1"?>
2 <project name="SIMAN SALOME Platform builder" default="help">
4 <property environment="env" />
5 <property file="build.properties" description="set the build parameters" />
7 <path id="dependencies.classpath">
8 <fileset dir="${tomcat.war.build.dir}">
9 <include name="${splat.lib.dir}/*.*"/>
15 slf4j-log4j12-1.6.1.jar
20 <pathelement location="${splat.lib.dir}/activation.jar" />
21 <pathelement location="${splat.lib.dir}/antlr-2.7.6.jar" />
22 <pathelement location="${splat.lib.dir}/commons-collections-3.1.jar" />
23 <pathelement location="${splat.lib.dir}/dom4j-1.6.1.jar" />
24 <pathelement location="${splat.lib.dir}/hibernate-3.5.jar" />
25 <pathelement location="${splat.lib.dir}/javassist-3.9.0.GA.jar" />
26 <pathelement location="${splat.lib.dir}/jta-1.1.jar" />
27 <pathelement location="${splat.lib.dir}/log4j-1.2.15.jar" />
28 <pathelement location="${splat.lib.dir}/lucene-core-2.9.2.jar" />
29 <pathelement location="${splat.lib.dir}/lucene-queries-2.9.2.jar" />
30 <pathelement location="${splat.lib.dir}/mailapi.jar" />
31 <pathelement location="${splat.lib.dir}/mysql-connector-java-5.1.5-bin.jar" />
32 <pathelement location="${splat.lib.dir}/" />
33 <pathelement location="${splat.lib.dir}/poi-3.7-20101029.jar" />
34 <pathelement location="${splat.lib.dir}/poi-ooxml-3.7-20101029.jar" />
35 <pathelement location="${splat.lib.dir}/poi-ooxml-schemas-3.7-20101029.jar" />
36 <pathelement location="${splat.lib.dir}/poi-scratchpad-3.7-20101029.jar" />
37 <pathelement location="${splat.lib.dir}/" />
38 <pathelement location="${splat.lib.dir}/" />
39 <pathelement location="${splat.lib.dir}/" />
40 <pathelement location="${splat.lib.dir}/" />
41 <pathelement location="${splat.lib.dir}/" />
42 <pathelement location="${splat.lib.dir}/" />-->
45 <path id="test.libs.classpath">
46 <pathelement location="${splat.lib.dir}/testng/testng-5.8-jdk15.jar" />
47 <pathelement location="${splat.lib.dir}/spring/spring-test.jar" />
51 <property name="time.simple.pattern" value="dd/MM/yyyy" />
53 <format property="timesimple" pattern="${time.simple.pattern}" />
56 <!-- ================================================= -->
58 <!-- Compile the sources file in build/classes -->
59 <!-- ================================================= -->
60 <target name="compile" description="compile source code">
61 <echo message="compiling SIMAN SALOME Platform" />
62 <echo message="compiler.max.memory : ${compiler.max.memory}" />
63 <echo message="build repository : ${splat.build.dir}" />
64 <echo message="splat.lib.dir : ${splat.lib.dir}" />
66 <mkdir dir="${splat.build.dir}" />
67 <mkdir dir="${splat.build.dir}/classes" />
68 <javac target="1.5" destdir="${splat.build.dir}/classes" debug="${compiler.debug}" nowarn="${compiler.generate.no.warnings}" memoryMaximumSize="${compiler.max.memory}" fork="true" optimize="${compiler.optimize}" deprecation="${compiler.deprecation}">
69 <src path="${splat.src.dir}/java" />
71 <path refid="dependencies.classpath" />
73 <exclude name="test/**" />
75 <copy todir="${splat.build.dir}/classes">
76 <fileset dir="${splat.src.dir}/conf">
78 <fileset dir="${splat.src.dir}/java">
79 <include name="com/**/*.xsd"/>
82 <mkdir dir="${splat.build.dir}/classes/META-INF" />
87 <!-- ================================================= -->
88 <!-- Compile tests -->
89 <!-- Compile the tests sources file in build/tests -->
90 <!-- ================================================= -->
91 <target name="compile-tests" description="compile source code">
92 <echo message="compiling splat tests classes" />
93 <echo message="compiler.max.memory : ${compiler.max.memory}" />
94 <echo message="build repository : ${splat.build.dir}" />
95 <echo message="splat.lib.dir : ${splat.lib.dir}" />
97 <mkdir dir="${splat.build.dir}" />
98 <mkdir dir="${splat.build.dir}/classes" />
99 <javac destdir="${splat.build.dir}/classes" debug="${compiler.debug}" nowarn="${compiler.generate.no.warnings}" memoryMaximumSize="${compiler.max.memory}" fork="true" optimize="${compiler.optimize}" deprecation="${compiler.deprecation}">
100 <src path="${splat.dir}/test" />
102 <path refid="dependencies.classpath" />
103 <path refid="test.libs.classpath" />
105 <include name="test/**" />
106 <exclude name="com/**" />
107 <exclude name="org/**" />
113 <!-- ================================================= -->
115 <!-- Create the jar file in the dist directory -->
116 <!-- ================================================= -->
117 <target name="jar" description="create jar file in dist directory">
118 <mkdir dir="${splat.dist.dir}" />
119 <jar destfile="${splat.dist.dir}/${splat.jar.name}">
120 <zipfileset dir="${splat.build.dir}/classes">
121 <include name="**" />
122 <exclude name="test" />
125 <attribute name="Built-By" value="EURIWARE" />
126 <attribute name="Version" value="${app.version}" />
127 <attribute name="Built-Date" value="${timesimple}" />
132 <!-- ================================================= -->
134 <!-- Compile and create the dist target -->
135 <!-- ================================================= -->
136 <target name="build" depends="compile,jar" description="compile and create the jar file in dist directory">
140 <!-- ================================================= -->
142 <!-- Compile and create the dist target -->
143 <!-- ================================================= -->
144 <target name="rebuild" depends="clean,compile,jar" description="clean, compile and create the jar file in dist directory">
147 <!-- ================================================= -->
149 <!-- Clean the build directory -->
150 <!-- ================================================= -->
151 <target name="clean" description="clean the build directory">
152 <echo message="deleting files in ${splat.dist.dir}" />
153 <delete includeemptydirs="true" failonerror="false">
154 <fileset dir="${splat.dist.dir}" includes="**/*" />
156 <echo message="deleting files in ${splat.build.dir}" />
157 <delete includeemptydirs="true" failonerror="false">
158 <fileset dir="${splat.build.dir}" includes="**/*" />
162 <!-- ============================================================================ -->
163 <!-- help : display the help page -->
164 <!-- ============================================================================ -->
166 <java fork="no" classname="org.apache.tools.ant.Main">
167 <arg line="-projecthelp" />