svn-gvsig-desktop / trunk / extensions / extJDBC / build.xml @ 7140
History | View | Annotate | Download (4.84 KB)
1 |
<project name="Generar extension en Andami" 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="mainplugin" value="com.iver.cit.gvsig"/> |
10 |
<property name="plugin" value="com.iver.cit.gvsig.jdbc_spatial"/> |
11 |
<!-- <property name="drivers-src" value="com.iver.cit.gvsig.fmap.drivers.jdbc"/> -->
|
12 |
<property name="gvsiglibjar" value="gvsig-jdbcspatial"/> |
13 |
<property name="fmapjar" value="fmap-jdbcspatial"/> |
14 |
<property name="driverjar" value="jdbc_spatial"/> |
15 |
<property name="andami" location="../_fwAndami"/> |
16 |
<property name="extensionsDir" location="${andami}/gvSIG/extensiones"/> |
17 |
<property name="drivers-dir" location="${extensionsDir}/${mainplugin}/drivers/jdbc_spatial" /> |
18 |
|
19 |
<property name="lib-dir" location="${extensionsDir}/${mainplugin}/lib"/> |
20 |
<property name="fmapLibs" location="../libFMap/lib" /> |
21 |
<property name="andamiLibs" location="${andami}/lib" /> |
22 |
<property name="andamiJar" location="${andami}/andami.jar"/> |
23 |
<property name="gvsigJar" location="${extensionsDir}/${mainplugin}/lib/${mainplugin}.jar"/> |
24 |
<property name="compile-classpath" value="${andamiJar}:${gvsigJar}:${andamiLibs}/beans.jar:${fmapLibs}/cms.jar:${fmapLibs}/driver-manager-1.1.jar:${fmapLibs}/fmap.jar:${fmapLibs}/gdbms-0.8-SNAPSHOT.jar:${andamiLibs}/iver-utiles.jar:${fmapLibs}/jts-1.7.jar:${andamiLibs}/log4j-1.2.8.jar:${fmapLibs}/mysql-connector-java-3.1.7-bin.jar:${fmapLibs}/postgis-jdbc-driver.jar:${fmapLibs}/postgresql-74.213.jar" /> |
25 |
|
26 |
<target name="init"> |
27 |
<!-- Create the time stamp -->
|
28 |
<tstamp/> |
29 |
<!-- Create the build directory structure used by compile -->
|
30 |
<mkdir dir="${build}"/> |
31 |
<mkdir dir="${dist}"/> |
32 |
|
33 |
</target>
|
34 |
|
35 |
<target name="generate-without-source" |
36 |
description="generate the distribution without the source file"> |
37 |
<!-- Create the distribution directory -->
|
38 |
<mkdir dir="${dist}"/> |
39 |
<mkdir dir="${drivers-dir}" /> |
40 |
<jar jarfile="${drivers-dir}/${driverjar}.jar" basedir="${build}" |
41 |
includes="com/iver/cit/gvsig/fmap/drivers/jdbc/*.class com/iver/cit/gvsig/fmap/drivers/jdbc/postgis/** com/iver/cit/gvsig/fmap/drivers/jdbc/mysql/**" |
42 |
/>
|
43 |
|
44 |
<!-- Put everything in ${build} into the MyProject-${DSTAMP}.jar file -->
|
45 |
<jar jarfile="${dist}/${plugin}.jar" basedir="${build}" |
46 |
includes="com/iver/cit/gvsig/** "/> |
47 |
<copy file="config/config.xml" todir="${dist}"/> |
48 |
<copy todir="${dist}"> |
49 |
<fileset dir="config" includes="text*.properties"/> |
50 |
</copy>
|
51 |
<copy todir="${dist}/images"> |
52 |
<fileset dir="images/" includes="*"/> |
53 |
</copy>
|
54 |
<move todir="${extensionsDir}/${mainplugin}/lib"> |
55 |
<fileset dir="${dist}" includes="${gvsiglibjar}.jar"/> |
56 |
<fileset dir="${dist}" includes="${fmapjar}.jar"/> |
57 |
</move>
|
58 |
<move todir="${extensionsDir}/${plugin}/"> |
59 |
<fileset dir="${dist}" includes="**/**"/> |
60 |
</move>
|
61 |
</target>
|
62 |
|
63 |
<target name="batch-build" |
64 |
description="compile the sources, create the jar file" |
65 |
depends="compile,create-jar,copy-data-files,move-to-andami"> |
66 |
</target>
|
67 |
|
68 |
<target name="compile" description="compile the source" > |
69 |
<!-- Compile the Java code from ${src} to ${build} -->
|
70 |
<mkdir dir="${build}" /> |
71 |
<javac srcdir="${src}" |
72 |
destdir="${build}" |
73 |
debug="${debug}" |
74 |
debuglevel="${debuglevel}" |
75 |
classpath="${compile-classpath}"/> |
76 |
</target>
|
77 |
|
78 |
<target name="create-jar" |
79 |
description="Creates the plugin jar"> |
80 |
<mkdir dir="${dist}"/> |
81 |
<mkdir dir="${drivers-dir}" /> |
82 |
<jar jarfile="${dist}/${plugin}.jar" basedir="${build}" includes="com/iver/cit/gvsig/**" |
83 |
excludes="com/iver/cit/gvsig/fmap/drivers/**" |
84 |
/>
|
85 |
<jar jarfile="${dist}/${driverjar}.jar" basedir="${build}" |
86 |
includes="com/iver/cit/gvsig/fmap/drivers/jdbc/*.class com/iver/cit/gvsig/fmap/drivers/jdbc/postgis/** com/iver/cit/gvsig/fmap/drivers/jdbc/mysql/**" |
87 |
/>
|
88 |
</target>
|
89 |
|
90 |
<target name="copy-data-files"> |
91 |
<copy file="config/config.xml" todir="${dist}"/> |
92 |
<copy todir="${dist}"> |
93 |
<fileset dir="config" includes="text*.properties"/> |
94 |
</copy>
|
95 |
<copy todir="${dist}/images"> |
96 |
<fileset dir="images/" includes="*"/> |
97 |
</copy>
|
98 |
</target>
|
99 |
|
100 |
<target name="move-to-andami"> |
101 |
<move todir="${drivers-dir}"> |
102 |
<fileset dir="${dist}" includes="${driverjar}.jar"/> |
103 |
</move>
|
104 |
<!-- <move todir="${extensionsDir}/${mainplugin}/lib">
|
105 |
<fileset dir="${dist}" includes="${gvsiglibjar}.jar"/>
|
106 |
<fileset dir="${dist}" includes="${fmapjar}.jar"/>
|
107 |
</move> -->
|
108 |
<move todir="${extensionsDir}/${plugin}/"> |
109 |
<fileset dir="${dist}" includes="**/**"/> |
110 |
</move>
|
111 |
</target>
|
112 |
|
113 |
<target name="clean" |
114 |
description="clean up" > |
115 |
<!-- Delete the ${build} and ${dist} directory trees -->
|
116 |
<delete dir="${dist}"/> |
117 |
<delete dir="${build}"/> |
118 |
</target>
|
119 |
</project>
|
120 |
|