Salome HOME
0d2c4e26ccd28a9b26e89af841e931560bd31e3c
[tools/siman.git] / Workspace / .metadata / .plugins / org.eclipse.core.resources / .history / 5f / 1097411abb03001210aca2509c1ad977
1 <?xml version="1.0" encoding="ISO-8859-1"?>
2 <project name="SIMAN SALOME Platform builder" default="build">
3
4         <property environment="env" />
5         <property file="build.properties" description="set the build parameters" />
6         
7         <path id="dependencies.classpath">
8                 <fileset dir="${tomcat.war.build.dir}">    
9                         <include name="${splat.lib.dir}/*.*"/>
10                 </fileset>
11         </path>
12
13         <path id="test.libs.classpath">
14                 <pathelement location="${splat.lib.dir}/testng/testng-5.8-jdk15.jar" />
15                 <pathelement location="${splat.lib.dir}/spring/spring-test.jar" />
16         </path>
17
18         
19         <property name="time.simple.pattern" value="dd/MM/yyyy" />
20         <tstamp>
21                 <format property="timesimple" pattern="${time.simple.pattern}" />
22         </tstamp>
23
24         <!-- ================================================= -->
25         <!--    build-splat-jar: Create the jar file in the        --> 
26         <!--                     dist directory                            -->
27         <!-- ================================================= -->
28         <target name="build-splat-jar" description="create jar file in dist directory">
29                 <echo message="build splat-${jar.name}.jar"/>
30                 <mkdir dir="${splat.dist.dir}" />
31                 <jar destfile="${splat.dist.dir}/splat-${jar.name}.jar" >
32                         <zipfileset dir="${splat.bin.dir}/">
33                                 <include name="org/splat/${jar.name}/**" />
34                         </zipfileset>
35                         <manifest>
36                                 <attribute name="Built-By" value="${app.author}" />
37                                 <attribute name="Version" value="${app.version}" />
38                                 <attribute name="Built-Date" value="${timesimple}" />
39                         </manifest>
40                 </jar>
41         </target>
42
43         <!-- ================================================= -->
44         <!--    Manox-Jar                                                                                          -->
45         <!--    Create the jar file in the dist directory          -->
46         <!-- ================================================= -->
47         <target name="manox-jar" description="create jar file in dist directory">
48                 <antcall target="build-splat-jar">
49                         <param name="jar.name" value="manox"/>
50                 </antcall>
51         </target>
52         
53         <!-- ================================================= -->
54         <!--    Kernel-Jar                                                                                         -->
55         <!--    Create the jar file in the dist directory          -->
56         <!-- ================================================= -->
57         <target name="kernel-jar" description="create jar file in dist directory">
58                 <antcall target="build-splat-jar">
59                         <param name="jar.name" value="kernel"/>
60                 </antcall>
61         </target>
62         
63         <!-- ================================================= -->
64         <!--    Som-Jar                                                                                    -->
65         <!--    Create the jar file in the dist directory          -->
66         <!-- ================================================= -->
67         <target name="som-jar" description="create jar file in dist directory">
68                 <antcall target="build-splat-jar">
69                         <param name="jar.name" value="som"/>
70                 </antcall>
71         </target>
72
73         <!-- ================================================= -->
74         <!--    Jar                                                                                -->
75         <!--    Build jars                                                 -->
76         <!-- ================================================= -->
77         <target name="jar" depends="kernel-jar,som-jar,manox-jar" description="compile and create the jar file in dist directory">
78         </target>
79
80         <!-- ================================================= -->
81         <!--    Build                                                                              -->
82         <!--    Compile and create the dist target                         -->
83         <!-- ================================================= -->
84         <target name="build" depends="compile,jar" description="compile and create the jar file in dist directory">
85         </target>
86
87
88         <!-- ================================================= -->
89         <!--    rebuild                                                                            -->
90         <!--    Compile and create the dist target                         -->
91         <!-- ================================================= -->
92         <target name="rebuild" depends="clean,compile,jar" description="clean, compile and create the jar file in dist directory">
93         </target>
94
95         <!-- ================================================= -->
96         <!--    Clean                                                                              -->
97         <!--    Clean the dist directory                                           -->
98         <!-- ================================================= -->
99         <target name="clean" description="clean the build directory">
100                 <echo message="deleting files in ${splat.dist.dir}" />
101                 <delete includeemptydirs="true" failonerror="false">
102                         <fileset dir="${splat.dist.dir}" includes="**/*" />
103                 </delete>
104         </target>
105
106         <!-- ============================================================================ -->
107         <!-- help : display the help page                                                 -->
108         <!-- ============================================================================ -->
109         <target name="help">
110                 <java fork="no" classname="org.apache.tools.ant.Main">
111                         <arg line="-projecthelp" />
112                 </java>
113         </target>
114
115         <!-- ================================================= -->
116         <!--    Compile                                                                            -->
117         <!--    Compile the sources file in build/classes          -->
118         <!-- ================================================= -->
119         <target name="compile" description="compile source code">
120                 <echo message="compiling SIMAN SALOME Platform" />
121                 <echo message="compiler.max.memory : ${compiler.max.memory}" />
122                 <echo message="build repository : ${splat.build.dir}" />
123                 <echo message="splat.lib.dir : ${splat.lib.dir}" />
124
125 <!--            <mkdir dir="${splat.build.dir}" />
126                 <mkdir dir="${splat.build.dir}/classes" />
127                 <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}">
128                         <src path="${splat.src.dir}" />
129                         <classpath>
130                                 <path refid="dependencies.classpath" />
131                         </classpath>
132                         <exclude name="test/**" />
133                 </javac>
134                 <copy todir="${splat.build.dir}/classes">
135                         <fileset dir="${splat.src.dir}/conf">
136                         </fileset>
137                         <fileset dir="${splat.src.dir}/java">
138                                 <include name="com/**/*.xsd"/>
139                         </fileset>
140                 </copy>
141                 <mkdir dir="${splat.build.dir}/classes/META-INF" />-->
142         </target>
143
144
145         
146         <!-- ================================================= -->
147         <!--    Compile tests                                                                      -->
148         <!--    Compile the tests sources file in build/tests      -->
149         <!-- ================================================= -->
150         <target name="compile-tests" description="compile source code">
151                 <echo message="compiling splat tests classes" />
152                 <echo message="compiler.max.memory : ${compiler.max.memory}" />
153                 <echo message="build repository : ${splat.build.dir}" />
154                 <echo message="splat.lib.dir : ${splat.lib.dir}" />
155
156                 <mkdir dir="${splat.build.dir}" />
157                 <mkdir dir="${splat.build.dir}/classes" />
158                 <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}">
159                         <src path="${splat.dir}/test" />
160                         <classpath>
161                                 <path refid="dependencies.classpath" />
162                                 <path refid="test.libs.classpath" />
163                         </classpath>
164                         <include name="test/**" />
165                         <exclude name="com/**" />
166                         <exclude name="org/**" />
167                 </javac>
168         </target>
169
170 </project>