root / trunk / extensions / extAddEventTheme / build.xml @ 9628
History | View | Annotate | Download (5.51 KB)
1 | 7815 | cesar | <project name="extAddEventTheme" default="generate-without-source" basedir="."> |
---|---|---|---|
2 | 3525 | caballero | <description>
|
3 | Instala el plugin de AƱadir tema de eventos en Andami. |
||
4 | </description>
|
||
5 | 4916 | cesar | <!-- set global properties for this build -->
|
6 | <property name="lib-dir" location="../_fwAndami/gvSIG/extensiones/com.iver.cit.gvsig/lib" /> |
||
7 | <property name="src" location="src"/> |
||
8 | <property name="build" location="bin"/> |
||
9 | <property name="doc" location="doc"/> |
||
10 | <property name="dist" location="dist"/> |
||
11 | <property name="without_src" location="without_src"/> |
||
12 | <property name="plugin" value="com.iver.gvsig.addeventtheme"/> |
||
13 | <property name="andami" value="../_fwAndami"/> |
||
14 | <property name="extensionsDir" location="${andami}/gvSIG/extensiones"/> |
||
15 | <property name="andamiJar" location="${andami}/andami.jar"/> |
||
16 | 5606 | cesar | <property name="mainplugin" value="com.iver.cit.gvsig" /> |
17 | <property name="gvsigJar" location="${extensionsDir}/${mainplugin}/lib/${mainplugin}.jar"/> |
||
18 | 9628 | cesar | <property name="fmapJar" location="../libFMap/dist/lib/fmap.jar"/> |
19 | 4916 | cesar | <property name="andamiLibs" location="${andami}/lib"/> |
20 | <property name="fmapLibs" location="../libFMap/lib" /> |
||
21 | 9628 | cesar | <property name="compile-classpath" value="${gvsigJar}:${andamiJar}:${andamiLibs}/beans.jar:${fmapLibs}/cms.jar:${fmapLibs}/driver-manager-1.1.jar:${fmapJar}:${fmapLibs}/gdbms-0.8-SNAPSHOT.jar:${andamiLibs}/iver-utiles.jar"/> |
22 | 7815 | cesar | |
23 | 4916 | cesar | <target name="init"> |
24 | <!-- Create the time stamp -->
|
||
25 | <tstamp/> |
||
26 | 7815 | cesar | <echo>
|
27 | Compiling ${ant.project.name}... |
||
28 | </echo>
|
||
29 | 4916 | cesar | </target>
|
30 | 3525 | caballero | |
31 | <target name="dist" depends="init" |
||
32 | description="generate the distribution" > |
||
33 | <!-- Remove previous distribution directory -->
|
||
34 | <delete dir="${dist}"/> |
||
35 | <!-- Create the distribution directory structure -->
|
||
36 | <mkdir dir="${dist}"/> |
||
37 | 6891 | fjp | <!-- <mkdir dir="${dist}/src"/> -->
|
38 | <!-- <mkdir dir="${dist}/doc"/> -->
|
||
39 | 3525 | caballero | <mkdir dir="${dist}/bin"/> |
40 | <mkdir dir="${dist}/bin/com"/> |
||
41 | <mkdir dir="${dist}/bin/com/iver"/> |
||
42 | <mkdir dir="${dist}/bin/com/iver/gvsig"/> |
||
43 | <mkdir dir="${dist}/bin/com/iver/gvsig/addeventtheme"/> |
||
44 | <mkdir dir="${dist}/bin/com/iver/gvsig/addeventtheme/images"/> |
||
45 | <mkdir dir="${dist}/images"/> |
||
46 | <mkdir dir="${dist}/config"/> |
||
47 | <!-- Copy necessary distribution files to dist dir -->
|
||
48 | <copy todir="${dist}/src"> |
||
49 | <fileset dir="${src}"/> |
||
50 | </copy>
|
||
51 | 6891 | fjp | <!-- <copy todir="${dist}/doc">
|
52 | 3525 | caballero | <fileset dir="${doc}"/>
|
53 | 6891 | fjp | </copy> -->
|
54 | 3525 | caballero | <copy todir="${dist}/images"> |
55 | <fileset dir="images"/> |
||
56 | </copy>
|
||
57 | <copy file="config/config.xml" todir="${dist}/config"/> |
||
58 | <copy file="build.xml" todir="${dist}"/> |
||
59 | <copy todir="${dist}"> |
||
60 | 5611 | cesar | <fileset dir="config" includes="text*.properties"/> |
61 | 3525 | caballero | </copy>
|
62 | <copy todir="${dist}/bin/com/iver/gvsig/addeventtheme"> |
||
63 | 5611 | cesar | <fileset dir="config" includes="text*.properties"/> |
64 | 3525 | caballero | </copy>
|
65 | 4916 | cesar | <jar jarfile="${dist}/bin/com/iver/gvsig/addeventtheme/${plugin}.jar" basedir="${build}"/> |
66 | 3525 | caballero | <copy file="config/config.xml" todir="${dist}/bin/com/iver/gvsig/addeventtheme"/> |
67 | <copy todir="${dist}/bin/com/iver/gvsig/addeventtheme/images"> |
||
68 | <fileset dir="images"/> |
||
69 | </copy>
|
||
70 | <!-- Zip distribution -->
|
||
71 | <zip destfile="${dist}/gvSIGAddEventThemePlugin.zip" |
||
72 | basedir="${dist}" |
||
73 | update="true" |
||
74 | />
|
||
75 | </target>
|
||
76 | |||
77 | 4916 | cesar | <target name="generate-without-source" depends="clean-orig" description="generate the distribution without the source file" > |
78 | 3525 | caballero | <!-- Create the distribution directory -->
|
79 | <mkdir dir="${without_src}"/> |
||
80 | |||
81 | <!-- Put everything in ${build} into the MyProject-${DSTAMP}.jar file -->
|
||
82 | 4916 | cesar | <jar jarfile="${without_src}/${plugin}.jar" basedir="${build}"/> |
83 | 3525 | caballero | <copy file="config/config.xml" todir="${without_src}"/> |
84 | <copy todir="${without_src}"> |
||
85 | 5611 | cesar | <fileset dir="config" includes="text*.properties"/> |
86 | 3525 | caballero | </copy>
|
87 | <copy todir="${without_src}/images"> |
||
88 | <fileset dir="images/" includes="*"/> |
||
89 | </copy>
|
||
90 | <!-- jar file must be in gvSIG/lib directory -->
|
||
91 | 8265 | jmvivo | <move file="${without_src}/${plugin}.jar" todir="${lib-dir}"/> |
92 | 4916 | cesar | <move todir="${extensionsDir}/${plugin}/"> |
93 | 3525 | caballero | <fileset dir="${without_src}" includes="**/**"/> |
94 | </move>
|
||
95 | </target>
|
||
96 | 4916 | cesar | |
97 | <target name="batch-build" |
||
98 | description="compile the sources, create the jar file" |
||
99 | 7816 | cesar | depends="init,compile,create-jar,copy-data-files,move-to-andami"> |
100 | 4916 | cesar | </target>
|
101 | 3525 | caballero | |
102 | 4916 | cesar | <target name="compile" description="compile the source" > |
103 | <!-- Compile the Java code from ${src} to ${build} -->
|
||
104 | <mkdir dir="${build}" /> |
||
105 | <javac srcdir="${src}" |
||
106 | destdir="${build}" |
||
107 | classpath="${compile-classpath}" |
||
108 | 7786 | cesar | source="1.4" |
109 | target="1.4" |
||
110 | 6296 | cesar | debug="${debug}" |
111 | debuglevel="${debuglevel}" |
||
112 | 4916 | cesar | excludes="test/**"/> |
113 | </target>
|
||
114 | |||
115 | <target name="create-jar" |
||
116 | description="Creates the plugin jar"> |
||
117 | <mkdir dir="${dist}"/> |
||
118 | <jar jarfile="${dist}/${plugin}.jar" basedir="${build}"/> |
||
119 | </target>
|
||
120 | |||
121 | <target name="copy-data-files"> |
||
122 | <copy file="config/config.xml" todir="${dist}"/> |
||
123 | <copy todir="${dist}"> |
||
124 | 5611 | cesar | <fileset dir="config" includes="text*.properties"/> |
125 | 4916 | cesar | </copy>
|
126 | <copy todir="${dist}/images"> |
||
127 | <fileset dir="images/" includes="*"/> |
||
128 | </copy>
|
||
129 | </target>
|
||
130 | |||
131 | <target name="move-to-andami"> |
||
132 | <!-- jar file must be in gvSIG/lib directory -->
|
||
133 | 8265 | jmvivo | <move file="${dist}/${plugin}.jar" todir="${lib-dir}"/> |
134 | 4916 | cesar | <move todir="${extensionsDir}/${plugin}/"> |
135 | <fileset dir="${dist}" includes="**/**"/> |
||
136 | </move>
|
||
137 | </target>
|
||
138 | |||
139 | <target name="clean" |
||
140 | description="clean up"> |
||
141 | <!-- Delete the ${build} and ${dist} directory trees -->
|
||
142 | <delete dir="${build}" /> |
||
143 | <delete dir="${dist}" /> |
||
144 | </target>
|
||
145 | |||
146 | 6891 | fjp | <target name="clean-orig" |
147 | 4916 | cesar | description="clean dist directory" > |
148 | <!-- Clean the distribution directory -->
|
||
149 | 6891 | fjp | <delete dir="${dist}"/> |
150 | 4916 | cesar | </target>
|
151 | 3525 | caballero | </project> |