-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathsubfloor-gwt.xml
More file actions
178 lines (150 loc) · 8.86 KB
/
Copy pathsubfloor-gwt.xml
File metadata and controls
178 lines (150 loc) · 8.86 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
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
<!--===========================================================================
Copyright (c) 2009, Pentaho Engineering Team
All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
* Redistributions of source code must retain the above copyright
notice, this list of conditions and the following disclaimer.
* Redistributions in binary form must reproduce the above copyright
notice, this list of conditions and the following disclaimer in the
documentation and/or other materials provided with the distribution.
* Neither the name of the Pentaho Corporation nor the
names of its contributors may be used to endorse or promote products
derived from this software without specific prior written permission.
THIS SOFTWARE IS PROVIDED BY Pentaho Engineering Team ''AS IS'' AND ANY
EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
DISCLAIMED. IN NO EVENT SHALL <copyright holder> BE LIABLE FOR ANY
DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
============================================================================-->
<!--===========================================================================
== SUBFLOOR-GWT ==
$Rev: 107 $
$Date: 2010-08-30 11:50:20 -0400 (Mon, 30 Aug 2010) $
Project Home: http://code.google.com/p/subfloor/
Provides default targets for building GWT applications.
============================================================================-->
<project name="subfloor-gwt" basedir="." default="default" xmlns:ivy="antlib:org.apache.ivy.ant">
<!-- Define the default location of the common build file -->
<property name="subfloor-pkg.file"
value="subfloor-pkg.xml"
description="This is the location of the subfloor-pkg.xml file" />
<!-- Import the common_build.xml file which contains all the default tasks -->
<import file="${subfloor-pkg.file}" />
<property name="gwt.output.dir"
value="${bin.dir}/gwt/output"
description="Base directory that holds all gwt generated files" />
<property name="gwt-dev.revision" value="1.6.4" description="The release of GWT-dev to download and install" />
<property name="gwt-log-level" value="INFO" description="The log level for GWT Compile" />
<property name="gwt-style" value="OBF" description="Style in which javascript should be generated, options include OBF[uscated], PRETTY, and DETAILED"/>
<property name="codegenlib.dir"
value="${basedir}/codegen-lib"
description="Location of the libraries needed for code generation" />
<property name="gwt-compile.maxmemory" value="512M" description="maxmemory argument for com.google.gwt.dev.GWTCompiler java task" />
<property name="gwt-compile.localWorkers" value="4" description="number of threads to use for running parallel compilation" />
<property name="gwt-compile.maxstack" value="1024k" description="vm stack size setting" />
<!-- override this in build.properties to change the copyright -->
<property name="pentaho-copyright" value="This program is free software; you can redistribute it and/or modify it under the${line.separator}terms of the GNU Lesser General Public License, version 2.1 as published by the Free Software ${line.separator}Foundation.${line.separator}${line.separator}You should have received a copy of the GNU Lesser General Public License along with this ${line.separator}program; if not, you can obtain a copy at http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html ${line.separator}or from the Free Software Foundation, Inc., ${line.separator}51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.${line.separator}${line.separator}This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY;${line.separator}without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.${line.separator}See the GNU Lesser General Public License for more details.${line.separator}${line.separator}Copyright 2011 Pentaho Corporation. All rights reserved.${line.separator}"/>
<!-- setup the classpath used for gwt-compile -->
<path id="codegen.classpath">
<fileset dir="${codegenlib.dir}">
<include name="*.jar" />
</fileset>
<path refid="classpath"/>
<pathelement path="${src.dir}" />
</path>
<!-- override the compile classpath so client source
can be compiled with javac (even though strictly speaking, this is
not necessary, it is helpful because it will fish out errors much quicker
than waiting until gwt-compile -->
<path id="classpath">
<fileset dir="${devlib.dir}">
<include name="*.jar" />
</fileset>
<fileset dir="${lib.dir}">
<include name="*.jar" />
</fileset>
<fileset dir="${codegenlib.dir}">
<include name="*.jar" />
</fileset>
</path>
<!--=======================================================================
init (override)
====================================================================-->
<target name="gwt.init" extensionOf="init">
<echo message="gwt: init"/>
<mkdir dir="${codegenlib.dir}" />
</target>
<!--=======================================================================
clean (override)
Removes all the files generated from the build process.
====================================================================-->
<target name="gwt.clean" extensionOf="clean"
description="Cleans all the files generated from a build with the exception of IVY-downloaded jars (see clean-all)">
<delete file="${bin.dir}/.gwtBuild*" />
</target>
<!--=======================================================================
clean-codegen
Removes all the codegen libraries that have been downloaded for this project
using the ivy dependencies.
====================================================================-->
<target name="clean-codegen" extensionOf="clean-jars">
<delete dir="${codegenlib.dir}" />
</target>
<!--=======================================================================
resolve-codgen (override)
Override to use OS-specific IVY configurations
====================================================================-->
<target name="resolve-codegen" extensionOf="resolve">
<ivy:resolve file="ivy.xml" conf="codegen" />
<ivy:retrieve conf="codegen" pattern="${codegenlib.dir}/[module]-[revision](-[classifier]).[ext]" />
</target>
<!--=======================================================================
gwt-compile
Performs GWT Compile which generates JavaScript
====================================================================-->
<target name="gwt-compile"
depends="gwt-compile.check, init"
unless="gwtBuild.notRequired"
description="Perform GWT Compile" extensionOf="dist">
<java classname="com.google.gwt.dev.Compiler" fork="true" failonerror="true" maxmemory="${gwt-compile.maxmemory}">
<classpath refid="codegen.classpath"/>
<jvmarg value="-Xss${gwt-compile.maxstack}"/>
<arg value="-war" />
<arg value="${gwt.output.dir}" />
<arg value="${gwt-module.path}" />
<arg value="-localWorkers" />
<arg value="${gwt-compile.localWorkers}" />
<arg value="-logLevel" />
<arg value="${gwt-log-level}" />
<arg value="-style" />
<arg value="${gwt-style}" />
</java>
<touch file="${bin.dir}/.gwtBuild-${gwt-module.path}" />
<!-- replace the Start of File (^^) with the copyright -->
<replaceregexp match="^^" replace="<!--${pentaho-copyright}-->${line.separator}">
<fileset dir="${gwt.output.dir}" includes="**/*.cache.html" />
</replaceregexp>
<copy todir="${stage.dir}">
<fileset dir="${gwt.output.dir}">
<exclude name=".gwt-tmp/" />
<exclude name="*-aux/" />
</fileset>
</copy>
</target>
<!--=======================================================================
gwt-compile.check
Detects changes in source since the last gwt-compile and sets a flag
so gwt-compile can skip when nothing has changed
====================================================================-->
<target name="gwt-compile.check">
<uptodate property="gwtBuild.notRequired" targetfile="${bin.dir}/.gwtBuild-${gwt-module.path}">
<srcfiles dir="${src.dir}" />
</uptodate>
</target>
</project>