svn-gvsig-desktop / tags / gvsig_topologia-0_1_0-1232 / extensions / extSymbology / build.xml
History | View | Annotate | Download (9.63 KB)
1 |
<project name="extSymbology" default="generate-without-source" basedir="."> |
---|---|
2 |
<description>
|
3 |
Instala el plugin en Andami |
4 |
</description>
|
5 |
<!-- set global properties for this build -->
|
6 |
<property name="src" location="src"/> |
7 |
<property name="build" location="bin"/> |
8 |
<property name="dist" location="dist"/> |
9 |
<property name="build-test" location="bin-test"/> |
10 |
<property name="src-test" location="src-test"/> |
11 |
<property name="andami" location="../_fwAndami"/> |
12 |
<property name="extensionsDir" location="${andami}/gvSIG/extensiones"/> |
13 |
<property name="andamiJar" location="${andami}/andami.jar"/> |
14 |
<property name="gvsigJar" location="${extensionsDir}/com.iver.cit.gvsig/lib/com.iver.cit.gvsig.jar"/> |
15 |
<property name="fmapLibs" location="../libFMap/lib" /> |
16 |
<property name="andamiLibs" location="${andami}/lib" /> |
17 |
<property name="fmapJar" location="../libFMap/dist/lib/fmap.jar"/> |
18 |
<property name="fmapRTJar" location="org.gvsig.symbology-ext.jar"/> |
19 |
|
20 |
<property name="default_symbols_dir" location="./defaultSymbology"/> |
21 |
<property name="symbols-dir" location="${default_symbols_dir}/Symbols"/> |
22 |
<property name="home" location="${user.home}"/> |
23 |
<property name="target-symbols" location="${home}/gvSIG/Symbols"/> |
24 |
|
25 |
<property name="styles-dir" location="${default_symbols_dir}/Styles"/> |
26 |
<property name="target-styles" location="${home}/gvSIG/Styles"/> |
27 |
|
28 |
<!--<import file="compile-classpath.xml"/>-->
|
29 |
<!--<property name="compile-classpath" value="${andamiJar}:${gvsigJar}:${fmapJar}:${andamiLibs}/iver-utiles.jar:${cmsLibs}/jecw-0.0.2.jar:${cmsLibs}/jecwcompress-1.0.0.jar:${cmsLibs}/jgdal-0.6.1.jar:${cmsLibs}/jmrsid-0.0.2.jar:${fmapLibs}/libproj.jar" />-->
|
30 |
<import file="../binaries/ant/utilities.xml"/> |
31 |
|
32 |
<!--Plugins-->
|
33 |
|
34 |
<property name="log4j-jar" location="${andamiLibs}/log4j-1.2.8.jar" /> |
35 |
<property name="gdbms-jar" location="${fmapLibs}/gdbms-0.8-SNAPSHOT.jar"/> |
36 |
<property name="generated-src" location="generated-src"/> |
37 |
|
38 |
<property name="labelparserpackage" value="org/gvsig/symbology/fmap/labeling/parse"/> |
39 |
<property name="LabelParserJar" value="org.gvsig.fmap.label-expr-parser"/> |
40 |
<property name="LabelJarParserName" value="${LabelParserJar}.jar"/> |
41 |
|
42 |
|
43 |
<property name="filterexprparserpackage" value="org/gvsig/symbology/fmap/rendering/filter/parser"/> |
44 |
<property name="FilterExprParserJar" value="org.gvsig.fmap.filter-expr-parser"/> |
45 |
<property name="FilterExprParserName" value="${FilterExprParserJar}.jar"/> |
46 |
|
47 |
<property name="javacchome" location="ext-tools"/> |
48 |
|
49 |
<property name="plugin" value="org.gvsig.extended-symbology"/> |
50 |
<property name="jarName" value="${plugin}.jar"/> |
51 |
|
52 |
|
53 |
<property name="RemoteServicesJar" value="org.gvsig.remote-client.sld"/> |
54 |
<property name="jarRSerName" value="${RemoteServicesJar}.jar"/> |
55 |
|
56 |
<target name="init"> |
57 |
<!-- Create the time stamp -->
|
58 |
<tstamp/> |
59 |
|
60 |
<echo>
|
61 |
Compiling ${ant.project.name}...</echo>
|
62 |
<!-- Create the build directory structure used by compile -->
|
63 |
<mkdir dir="${dist}"/> |
64 |
<!-- Creamos un fichero con el timeStamp para que lo lea el FPanelAbout -->
|
65 |
<!-- <buildnumber/> -->
|
66 |
</target>
|
67 |
|
68 |
|
69 |
|
70 |
<target name="generate-without-source" |
71 |
description="generate the distribution without the source file" |
72 |
depends="init,copy-symbols,copy-styles,filter-expression-parser-jar,label-expression-parser-jar,compile-sources,create-jar,copy-data-files,copy-to-fmap,move-to-andami"> |
73 |
</target>
|
74 |
<target name="copy-symbols"> |
75 |
<copy todir="${target-symbols}"> |
76 |
<fileset dir="${symbols-dir}" includes="**"/> |
77 |
</copy>
|
78 |
</target>
|
79 |
<target name="copy-styles"> |
80 |
<copy todir="${target-styles}"> |
81 |
<fileset dir="${styles-dir}" includes="**"/> |
82 |
</copy>
|
83 |
</target>
|
84 |
<target name="batch-build" |
85 |
description="compile the sources, create the jar file" |
86 |
depends="init,copy-symbols,copy-styles,filter-expression-parser-jar,label-expression-parser-jar, compile,create-jar,copy-data-files,copy-to-fmap,move-to-andami"> |
87 |
</target>
|
88 |
|
89 |
<target name="import_BN"> |
90 |
<antcall target="gvSIG-import-build-number"/> |
91 |
</target>
|
92 |
|
93 |
<target name="compile-sources" description="compile the source" > |
94 |
<!-- Compile the Java code from ${src} to ${build} -->
|
95 |
<mkdir dir="${build}" /> |
96 |
<loadEclipseClasspath project="${basedir}"/> |
97 |
<gvSIG-javac
|
98 |
classpath="${eclipseClasspath}" |
99 |
/>
|
100 |
<!--<javac srcdir="${src}"
|
101 |
destdir="${build}"
|
102 |
source="1.4"
|
103 |
target="1.4"
|
104 |
debug="${debug}"
|
105 |
debuglevel="${debuglevel}"
|
106 |
classpath="${compile-classpath}"/>-->
|
107 |
</target>
|
108 |
|
109 |
<target name="compile" description="compile the source" depends="import_BN,compile-sources"/> |
110 |
|
111 |
<target name="create-jar" |
112 |
description="Creates the plugin jar"> |
113 |
<mkdir dir="${dist}"/> |
114 |
|
115 |
<!-- Jar de la extensión - ->
|
116 |
<jar jarfile="${dist}/${jarName}" basedir="${build}"
|
117 |
includes="org/gvsig/symbology/*.class,org/gvsig/symbology/gui/**/**"
|
118 |
excludes="org/gvsig/symbology/labeling/**/**"
|
119 |
/>
|
120 |
|
121 |
|
122 |
<jar jarfile="${dist}/${jarName}" basedir="${build}"
|
123 |
includes="org/gvsig/symbology/gui/**/**" update="yes"
|
124 |
/>
|
125 |
-->
|
126 |
|
127 |
<!-- Jar de FMap - ->
|
128 |
<jar jarfile="${fmapRTJar}" basedir="${build}"
|
129 |
excludes="org/gvsig/symbology/*,org/gvsig/symbology/gui/**/**"
|
130 |
includes="org/gvsig/symbology/**/**"
|
131 |
/>
|
132 |
|
133 |
-->
|
134 |
|
135 |
<!-- Jar de la extensión -->
|
136 |
|
137 |
|
138 |
<jar jarfile="${dist}/${jarName}" basedir="${build}" |
139 |
includes="org/gvsig/symbology/**,org/gvsig/symbology/gui/**/**,com/iver/cit/gvsig/project/documents/view/**/**" |
140 |
excludes="org/gvsig/symbology/fmap/**"/> |
141 |
|
142 |
<!-- Jar de FMap -->
|
143 |
<jar jarfile="${fmapRTJar}" basedir="${build}" |
144 |
includes="org/gvsig/symbology/fmap/**"/> |
145 |
|
146 |
<jar jarfile="${dist}/${jarRSerName}" basedir="${build}" |
147 |
includes="org/gvsig/remoteClient/sld/**/**" |
148 |
/>
|
149 |
|
150 |
</target>
|
151 |
|
152 |
|
153 |
<target name="label-expression-parser-jar" |
154 |
description="This target builds the label expression parser jar. It requires Javacc to be installed"> |
155 |
<!-- build the parser -->
|
156 |
|
157 |
<property name="srcdir-lab" value="${generated-src}/src/${labelparserpackage}"/> |
158 |
<property name="destdir-lab" value="${generated-src}/bin/${labelparserpackage}"/> |
159 |
<mkdir dir="${srcdir-lab}"/> |
160 |
<javacc javacchome="${javacchome}" |
161 |
target="${src}/${labelparserpackage}/LabelExpressionParser.jj" |
162 |
outputdirectory="${srcdir-lab}" |
163 |
static="false" |
164 |
lookahead="2" |
165 |
/>
|
166 |
|
167 |
<!-- Jar de LabelExpressionParser -->
|
168 |
<mkdir dir="${destdir-lab}"/> |
169 |
<echo>javac -classpath=${fmapRTJar}:${gdbms-jar}:${log4j-jar} ${generated-src}/bin"</echo> |
170 |
<gvSIG-javac srcdir="${srcdir-lab}" classpath="${gdbms-jar}:${log4j-jar}:${fmapJar}" sourcepath="./src" destdir="${generated-src}/bin"/> |
171 |
<!--
|
172 |
<jar jarfile="${dist}/${LabelParserJar}.jar" basedir="${generated-src}/bin" includes="${labelparserpackage}/**/**"
|
173 |
/>
|
174 |
<move file="${dist}/${LabelJarParserName}" todir="${fmapLibs}"/>-->
|
175 |
<copy todir="${src}/${labelparserpackage}/"> |
176 |
<fileset dir="${generated-src}/src/${labelparserpackage}" includes="*.java"/> |
177 |
</copy>
|
178 |
<deltree dir="${generated-src}"/> |
179 |
</target>
|
180 |
|
181 |
<target name="filter-expression-parser-jar" |
182 |
description="This target builds the filter expression parser jar. It requires Javacc to be installed"> |
183 |
<!-- build the parser -->
|
184 |
|
185 |
<property name="srcdir-filt" value="${generated-src}/src/${filterexprparserpackage}"/> |
186 |
<property name="destdir-filt" value="${generated-src}/bin/${filterexprparserpackage}"/> |
187 |
<mkdir dir="${srcdir-filt}"/> |
188 |
<javacc javacchome="${javacchome}" |
189 |
target="${src}/${filterexprparserpackage}/ExpressionParser.jj" |
190 |
outputdirectory="${srcdir-filt}" |
191 |
static="false" |
192 |
|
193 |
/>
|
194 |
|
195 |
<!-- Jar de FilterExpressionParser -->
|
196 |
<mkdir dir="${destdir-filt}"/> |
197 |
<echo>javac -classpath=${fmapRTJar}:${gdbms-jar}:${log4j-jar}:${fmapJar} ${generated-src}/bin"</echo> |
198 |
<gvSIG-javac srcdir="${srcdir-filt}" classpath="${gdbms-jar}:${log4j-jar}:${fmapJar}" sourcepath="./src" destdir="${generated-src}/bin"/> |
199 |
<!--
|
200 |
<jar jarfile="${dist}/${FilterExprJarParserName}.jar" basedir="${generated-src}/bin" includes="${filterparserpackage}/**/**"
|
201 |
/>
|
202 |
<move file="${dist}/${FilterExprJarParserName}" todir="${fmapLibs}"/>-->
|
203 |
<copy todir="${src}/${filterexprparserpackage}/"> |
204 |
<fileset dir="${generated-src}/src/${filterexprparserpackage}" includes="*.java"/> |
205 |
</copy>
|
206 |
<deltree dir="${generated-src}"/> |
207 |
</target>
|
208 |
|
209 |
<target name="copy-data-files"> |
210 |
<copy file="config/config.xml" todir="${dist}"/> |
211 |
<copy todir="${dist}"> |
212 |
<fileset dir="config" includes="text*.properties"/> |
213 |
</copy>
|
214 |
<copy todir="${dist}/images"> |
215 |
<fileset dir="images/" includes="*"/> |
216 |
</copy>
|
217 |
<copy todir="${dist}/docs"> |
218 |
<fileset dir="docs/" includes="*"/> |
219 |
</copy>
|
220 |
|
221 |
<copy todir="${dist}/default_symbology"> |
222 |
<fileset dir="${default_symbols_dir}" includes="**"/> |
223 |
</copy>
|
224 |
</target>
|
225 |
|
226 |
<target name="move-to-andami"> |
227 |
<move file="${fmapRTJar}" todir="${extensionsDir}/com.iver.cit.gvsig/lib/"/> |
228 |
<move file="${dist}/${jarRSerName}" todir="${extensionsDir}/com.iver.cit.gvsig/lib/"/> |
229 |
<move todir="${extensionsDir}/${plugin}/"> |
230 |
<fileset dir="${dist}" includes="**/**"/> |
231 |
</move>
|
232 |
</target>
|
233 |
|
234 |
<target name="copy-to-fmap"> |
235 |
<copy file="${fmapRTJar}" todir="${fmapLibs}"/> |
236 |
<copy file="${dist}/${jarRSerName}" todir="${fmapLibs}"/> |
237 |
|
238 |
</target>
|
239 |
|
240 |
<target name="clean" |
241 |
description="clean up" > |
242 |
<!-- Delete the ${build} and ${dist} directory trees -->
|
243 |
<delete dir="${dist}"/> |
244 |
<delete dir="${build}"/> |
245 |
</target>
|
246 |
|
247 |
<target name="uninstall" |
248 |
description="Desinstala de gvSIG la extensión" > |
249 |
<delete file="${extensionsDir}/com.iver.cit.gvsig/lib/gvsig.extended-symbology.jar"/> |
250 |
<delete file="${extensionsDir}/com.iver.cit.gvsig/lib/fmap.extended-symbology.jar"/> |
251 |
</target>
|
252 |
|
253 |
<target name="run-tests" depends="batch-build,compile-tests"> |
254 |
<antcall target="generic-run-tests"> |
255 |
<param name="TestSuite.Name" value="org.gvsig.symbology.AllTests"/> |
256 |
</antcall>
|
257 |
</target>
|
258 |
</project>
|
259 |
|