forked from daveho/CloudCoder
-
Notifications
You must be signed in to change notification settings - Fork 61
Expand file tree
/
Copy pathbuild.xml
More file actions
129 lines (105 loc) · 4.81 KB
/
build.xml
File metadata and controls
129 lines (105 loc) · 4.81 KB
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
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
<project name="cloudcoderrepowebserver" default="jar">
<property name="jarfile" value="cloudcoderRepoApp.jar"/>
<!-- Filename of JSTL jarfile. -->
<property name="jstl.jar" value="org.apache.taglibs.standard.glassfish_1.2.0.v201004190952.jar"/>
<path id="cloudcoderrepowebserver.path">
<pathelement location="bin"/>
<pathelement location="../CloudCoderJetty/cloudcoderJetty.jar"/>
<fileset dir="../CloudCoderJetty/lib" includes="**/*.jar"/>
<fileset dir="../CloudCoderLogging/lib" includes="**.jar"/>
</path>
<target name="modelClasses">
<ant dir="../CloudCoderModelClasses" target="jar" inheritall="false"/>
</target>
<target name="modelClassesPersist">
<ant dir="../CloudCoderModelClassesPersistence" target="jar" inheritall="false"/>
</target>
<target name="cloudcoderJetty">
<ant dir="../CloudCoderJetty" target="jar" inheritall="false"/>
</target>
<target name="modelClassesJSON">
<ant inheritall="false" dir="../CloudCoderModelClassesJSON" target="jar"/>
</target>
<target name="webServiceUtil">
<ant inheritall="false" dir="../CloudCoderWebServiceUtil" target="jar"/>
</target>
<target name="repoWebapp">
<ant dir="../CloudCoderRepository" target="build" inheritall="false"/>
</target>
<target name="javac" depends="cloudcoderJetty">
<mkdir dir="bin"/>
<javac srcdir="src" destdir="bin" source="1.6" target="1.6">
<classpath refid="cloudcoderrepowebserver.path"/>
</javac>
</target>
<target name="jar" depends="javac,modelClasses,modelClassesPersist,modelClassesJSON,webServiceUtil,repoWebapp">
<jar destfile="${jarfile}">
<!-- Copy classes from the bin directory. -->
<fileset dir="bin" includes="**"/>
<!-- Copy classes and other files from required libraries and Jetty. -->
<zipfileset src="../CloudCoderJetty/jettyDeps.jar" excludes="META-INF/**"/>
<!-- Copy Jetty single-file-deployment support code. -->
<zipfileset src="../CloudCoderJetty/cloudcoderJetty.jar" excludes="META-INF/**"/>
<!-- Include the repository webapp.
However, exclude the slf4j jars, since Jetty will already have
them on its classpath, and we don't want two copies. -->
<fileset
dir="../CloudCoderRepository"
includes="war/**"
excludes="**/slf4j*.jar,war/logs/**" />
<!-- Include the model classes jar file in webapp's WEB-INF/lib. -->
<zipfileset
file="../CloudCoderModelClasses/cloudcoderModelClasses.jar"
fullpath="war/WEB-INF/lib/cloudcoderModelClasses.jar"/>
<!-- Include the model classes persistence jar file in webapp's WEB-INF/lib. -->
<zipfileset
file="../CloudCoderModelClassesPersistence/cloudcoderModelClassesPersist.jar"
fullpath="war/WEB-INF/lib/cloudcoderModelClassesPersist.jar"/>
<!-- Include the model classes JSON serialization jar file in the webapp's WEB-INF/lib. -->
<zipfileset
file="../CloudCoderModelClassesJSON/cloudcoderModelClassesJSON.jar"
fullpath="war/WEB-INF/lib/cloudcoderModelClassesJSON.jar"/>
<!-- Include web service util jarfile. -->
<zipfileset
file="../CloudCoderWebServiceUtil/cloudcoderWebServiceUtil.jar"
fullpath="war/WEB-INF/lib/cloudcoderWebServiceUtil.jar"/>
<!-- Include JSTL taglib jarfile. -->
<zipfileset
file="../CloudCoderJetty/lib/jetty/jsp/${jstl.jar}"
fullpath="war/WEB-INF/lib/${jstl.jar}"/>
<!-- Include owasp-java-html-sanitizer and associated jarfiles. -->
<zipfileset
file="../CloudCoderLogging/lib/owasp-java-html-sanitizer.jar"
fullpath="war/WEB-INF/lib/owasp-java-html-sanitizer.jar"/>
<zipfileset
file="../CloudCoderLogging/lib/guava.jar"
fullpath="war/WEB-INF/lib/guava.jar"/>
<!-- Include cloudcoder configuration properties (cloudcoder.properties) -->
<zipfileset
file="../cloudcoder.properties"
fullpath="cloudcoder.properties"/>
<!-- Include log4j.properties -->
<zipfileset
file="src/log4j.properties"
fullpath="log4j.properties"/>
<!-- Include a Manifest specifying the Main-Class to start/control/shutdown the webapp. -->
<manifest>
<attribute name="Main-Class" value="org.cloudcoder.repoapp.webserver.CloudCoderRepositoryWebServer" />
</manifest>
</jar>
</target>
<target name="clean">
<delete quiet="true">
<fileset dir="bin" includes="**"/>
</delete>
<delete quiet="true" file="${jarfile}"/>
</target>
<target name="depclean" depends="clean">
<ant dir="../CloudCoderModelClasses" target="clean" inheritall="false"/>
<ant dir="../CloudCoderModelClassesPersistence" target="clean" inheritall="false"/>
<ant dir="../CloudCoderModelClassesJSON" target="clean" inheritall="false"/>
<ant dir="../CloudCoderJetty" target="clean" inheritall="false"/>
<ant dir="../CloudCoderRepository" target="clean" inheritall="false"/>
<ant dir="../CloudCoderWebServiceUtil" target="clean" inheritall="false"/>
</target>
</project>