-
Notifications
You must be signed in to change notification settings - Fork 0
/
build.xml
64 lines (54 loc) · 2.42 KB
/
build.xml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
<?xml version="1.0"?>
<project default="build-war">
<property name="project.name" value="sametimed" />
<property name="project.version" value="g0.5" />
<property name="project.dir" value="${basedir}" />
<property name="src.dir" value="${basedir}/src" />
<property name="war.dir" value="${basedir}/WebContent" />
<target name="compile">
<delete dir="${war.dir}/WEB-INF/classes" />
<mkdir dir="${war.dir}/WEB-INF/classes" />
<javac destdir="${war.dir}/WEB-INF/classes" srcdir="${src.dir}">
<classpath>
<fileset dir="${war.dir}/WEB-INF/lib">
<include name="*.jar" />
</fileset>
</classpath>
</javac>
<copy todir="${war.dir}/WEB-INF/classes">
<fileset dir="src">
<include name="**/*.properties" />
<include name="**/*.xml" />
</fileset>
</copy>
</target>
<target name="build-war" depends="build-complete-war" />
<target name="build-jetty-war" depends="build-complete-war" />
<target name="build-tomcat-war" depends="build-with-no-logback-lib-war" />
<!-- it is required to place slf4j-api, logback-classic and logback-core
jars into $TOMCAT_HOME/common/lib/ folder and running it with
-Dlogback.ContextSelector=JNDI.
see http://logback.qos.ch/manual/contextSelector.html -->
<target name="build-complete-war" depends="compile">
<war basedir="${war.dir}"
destfile="${project.name}.${project.version}.war"
webxml="${war.dir}/WEB-INF/web.xml" />
</target>
<target name="build-with-no-logback-lib-war" depends="compile">
<war basedir="${war.dir}"
destfile="${project.name}.${project.version}.no-servlet-lib.war"
webxml="${war.dir}/WEB-INF/web.xml"
excludes="WEB-INF/lib/slf4j-api-*.jar,
WEB-INF/lib/logback-*.jar" />
<war basedir="${war.dir}"
destfile="${project.name}.${project.version}.war"
webxml="${war.dir}/WEB-INF/web.xml" />
</target>
<target name="archive-project-files">
<zip basedir="${project.dir}"
destfile="${project.name}.${project.version}.eclipse-files.zip"
includes=".project, .classpath, .settings/, .externalToolBuilders/"
update="false"
/>
</target>
</project>