-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathbuild.xml
114 lines (102 loc) · 4.35 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
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
<project name="Core" default="install" basedir=".">
<import file="framework.xml"/>
<!-- ...............................................................
Build dojo and themes after the basic framework is built but before
WebServerResources are copied.
-->
<target name="build.basic.woframework"
depends="common.build.basic.woframework, dojo.build, themes.build"/>
<target name="setProps" depends="common.setProps">
<property file="../Bootstrap/build.properties" prefix="bootstrap."/>
<propertyfile
file="Properties"
comment="This file is automatically rewritten by ANT, so all formatting will be trashed.">
<entry key="bootstrap.project.version"
value="${bootstrap.project.version}"/>
</propertyfile>
</target>
<target name="clean" depends="common.clean, dojo.clean" />
<!-- ...............................................................
Generates Dijit images and CSS overrides for any Web-CAT themes that
contain a themebuilder.properties file.
-->
<target name="themes.check">
<!-- just check one generated image file against the set of sources to
see if the ruby script has been run -->
<uptodate property="themes.uptodate"
targetfile="WebServerResources/theme/dream-way/images/button-enabled.png">
<srcfiles dir="dojo-release/extras/themebuilder/">
<exclude name="**/CVS/"/>
</srcfiles>
</uptodate>
</target>
<target name="themes.build" depends="themes.check" unless="themes.uptodate">
<apply executable="ruby" dir="dojo-release/extras/themebuilder">
<arg file="dojo-release/extras/themebuilder/build-theme.rb"/>
<fileset dir="WebServerResources/theme">
<include name="**/themebuilder.properties"/>
</fileset>
</apply>
</target>
<!-- ...............................................................
Compiles and shrinks the Dojo release.
-->
<target name="dojo.check">
<!-- just check one generated javascript file against the set of sources
to see if the dojo ditribution has been rebuilt -->
<uptodate property="dojo.uptodate"
targetfile="WebServerResources/webcat/BasePage.js">
<srcfiles dir="dojo-release">
<exclude name="extras/themebuilder/"/>
<exclude name="**/CVS/"/>
</srcfiles>
</uptodate>
</target>
<target name="dojo.clean">
<delete dir="WebServerResources/dojo"/>
<delete dir="WebServerResources/dijit"/>
<delete dir="WebServerResources/dojox"/>
<delete dir="WebServerResources/webcat"/>
<delete dir="dojo-release/dijit/themes/aristo"/>
</target>
<target name="dojo.build" depends="dojo.check" unless="dojo.uptodate">
<antcall target="dojo.clean"/>
<copy todir="dojo-release/dijit/themes/aristo">
<fileset dir="dojo-release/extras/aristo"/>
</copy>
<java
dir="dojo-release/util/buildscripts"
fork="true"
classname="org.mozilla.javascript.tools.shell.Main">
<classpath>
<pathelement location="dojo-release/util/shrinksafe/js.jar"/>
<pathelement location="dojo-release/util/shrinksafe/shrinksafe.jar"/>
</classpath>
<arg value="build.js"/>
<arg value="profileFile=../../webcat.profile.js"/>
<arg value="loader=xdomain"/>
<arg value="action=release"/>
<arg value="optimize=shrinksafe"/>
<arg value="cssOptimize=comments"/>
<arg value="copyTests=false"/>
<!-- this is kind of a hack, but I couldn't get Dijit's CSS images to
work when they were in a nested directory, and if I try to use
WebServerResources as the release name, it DELETES IT (!) before
building, so do everything in a temp directory and then copy the
dojo,dijit,dojox folders directly -->
<arg value="releaseName=wcdojo"/>
<arg value="releaseDir=../../../__dojo-tmp/"/>
</java>
<copy todir="WebServerResources">
<fileset dir="__dojo-tmp/wcdojo"/>
</copy>
<delete dir="__dojo-tmp"/>
<echo>
If you are running this task in Eclipse with automatic builds enabled,
the "build" directory for the Core project may have become out-of-sync
after this long file-based operation. It is recommended that you clean
the Core project now to ensure that all necessary web resources will
be found.
</echo>
</target>
</project>