Statistics
| Revision:

root / trunk / extensions / extWCS / build.xml @ 38571

History | View | Annotate | Download (4.86 KB)

1 1877 luisw
<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 13309 jmvivo
  <import file="../binaries/ant/utilities.xml"/>
7 1877 luisw
  <property name="src" location="src"/>
8
  <property name="build" location="bin"/>
9 13484 cesar
  <property name="src-test" location="src-test"/>
10
  <property name="build-test" location="bin-test"/>
11 1877 luisw
  <property name="dist"  location="dist"/>
12
  <property name="mainplugin" value="com.iver.cit.gvsig"/>
13 4505 jaume
  <property name="plugin" value="com.iver.cit.gvsig.wcs"/>
14
  <property name="gvsiglibjar" value="gvsig-wcs"/>
15
  <property name="fmapjar" value="fmap-wcs"/>
16 1877 luisw
  <property name="driverjar" value="wcs"/>
17 5644 cesar
        <property name="andami" location="../_fwAndami" />
18
        <property name="extensionsDir" location="../_fwAndami/gvSIG/extensiones"/>
19
        <property name="drivers-dir" location="${extensionsDir}/${mainplugin}/drivers" />
20
        <property name="lib-dir" location="${extensionsDir}/${mainplugin}/lib"/>
21
        <property name="fmapLibs" location="../libFMap/lib" />
22
        <property name="remoteclientjar" value="${fmapLibs}/remote-clients.jar"/>
23
        <property name="andamiLibs" location="${andami}/lib" />
24
        <property name="andamiJar" location="${andami}/andami.jar"/>
25 9629 cesar
        <property name="fmapJar" location="../libFMap/dist/lib/fmap.jar" />
26 5644 cesar
        <property name="gvsigJar" location="${extensionsDir}/${mainplugin}/lib/${mainplugin}.jar"/>
27 13309 jmvivo
28
29 1877 luisw
  <target name="init">
30
    <!-- Create the time stamp -->
31
    <tstamp/>
32
    <!-- Create the build directory structure used by compile -->
33
    <mkdir dir="${build}"/>
34
    <mkdir dir="${dist}"/>
35 13309 jmvivo
36 1877 luisw
  </target>
37
38
  <target name="generate-without-source"
39 1885 luisw
                  description="generate the distribution without the source file">
40 1877 luisw
    <!-- Create the distribution directory -->
41
    <mkdir dir="${dist}"/>
42 13309 jmvivo
43 1877 luisw
    <!-- Put everything in ${build} into the MyProject-${DSTAMP}.jar file -->
44 4505 jaume
    <jar jarfile="${dist}/${plugin}.jar" basedir="${build}" includes="com/iver/cit/gvsig/**"
45
            excludes="com/iver/cit/gvsig/fmap/**"
46
    />
47 1877 luisw
          <jar jarfile="${dist}/${fmapjar}.jar" basedir="${build}"
48 4505 jaume
                            includes="com/iver/cit/gvsig/fmap/**" />
49
<!--                            excludes="com/iver/cit/gvsig/fmap/drivers/wcs/**" />-->
50 1877 luisw
          <copy file="config/config.xml" todir="${dist}"/>
51 10187 jmvivo
          <copy file="build.number" todir="${dist}"/>
52 1877 luisw
    <copy todir="${dist}">
53 4505 jaume
            <fileset dir="config" includes="text*.properties"/>
54 1877 luisw
    </copy>
55 4505 jaume
          <!--copy todir="${dist}/images">
56
                      <fileset dir="images/" includes="*"/>
57
          </copy>
58
          <copy todir="${lib-dir}">
59 1877 luisw
            <fileset dir="./lib" includes="*.jar,*.zip"/>
60
            <fileset dir="." includes=".keystore"/>
61 4505 jaume
    </copy-->
62 5644 cesar
          <move todir="${extensionsDir}/${mainplugin}/lib">
63 1877 luisw
                  <fileset dir="${dist}" includes="${gvsiglibjar}.jar"/>
64 4505 jaume
                <fileset dir="${dist}" includes="${fmapjar}.jar"/>
65 5644 cesar
                <fileset dir="${dist}" includes="${remoteclientjar}"/>
66 1877 luisw
         </move>
67 5644 cesar
    <move todir="${extensionsDir}/${plugin}/">
68 1877 luisw
            <fileset dir="${dist}" includes="**/**"/>
69
    </move>
70
  </target>
71 5644 cesar
72
73
        <target name="batch-build"
74
                        description="compile the sources, create the jar file"
75
                        depends="compile,create-jar,copy-data-files,copy-libs,move-to-andami">
76
        </target>
77
78
        <target name="compile" description="compile the source" >
79
                <!-- Compile the Java code from ${src} to ${build} -->
80 13309 jmvivo
                <antcall target="gvSIG-import-build-number"/>
81 5644 cesar
                <mkdir dir="${build}" />
82 13309 jmvivo
                <loadEclipseClasspath project="${basedir}"/>
83
                <gvSIG-javac
84
                        classpath="${eclipseClasspath}"/>
85 5644 cesar
        </target>
86 13309 jmvivo
87 5644 cesar
        <target name="create-jar"
88
                        description="Creates the plugin jar">
89
                <mkdir dir="${dist}/lib"/>
90 5662 cesar
            <jar jarfile="${dist}/${plugin}.jar" basedir="${build}" includes="com/iver/cit/gvsig/**"
91 5644 cesar
                    excludes="com/iver/cit/gvsig/fmap/**"
92
            />
93
                  <jar jarfile="${dist}/${fmapjar}.jar" basedir="${build}"
94
                                    includes="com/iver/cit/gvsig/fmap/**" />
95
        </target>
96
97 34510 fdiaz
        <target name="copy-data-files" depends="make-package-info">
98 5644 cesar
            <copy file="config/config.xml" todir="${dist}"/>
99 10187 jmvivo
                <copy file="build.number" todir="${dist}"/>
100 34510 fdiaz
                <copy file="package.info" todir="${dist}"/>
101 5644 cesar
                <copy todir="${dist}">
102
                        <fileset dir="config" includes="text*.properties"/>
103
                </copy>
104
        </target>
105 13309 jmvivo
106 5644 cesar
        <target name="copy-libs">
107
                  <copy todir="${extensionsDir}/${mainplugin}/lib">
108
                        <fileset file="${remoteclientjar}"/>
109
                 </copy>
110
        </target>
111 13309 jmvivo
112 5644 cesar
        <target name="move-to-andami">
113
                  <move todir="${extensionsDir}/${mainplugin}/lib">
114
                        <fileset dir="${dist}" includes="${fmapjar}.jar"/>
115
                  </move>
116
            <move todir="${extensionsDir}/${plugin}/">
117
                    <fileset dir="${dist}" includes="**/**"/>
118
            </move>
119
        </target>
120
121 13309 jmvivo
122 5644 cesar
        <target name="clean"
123
                description="clean up" >
124 4505 jaume
            <!-- Delete the ${build} and ${dist} directory trees -->
125 5644 cesar
                <delete dir="${dist}"/>
126
                <delete dir="${build}"/>
127
        </target>
128 13479 cesar
129
        <target name="run-tests" depends="batch-build,compile-tests">
130
                <antcall target="generic-run-tests">
131
                        <param name="TestSuite.Name" value="com.iver.cit.gvsig.wcs.AllTests"/>
132
                </antcall>
133
        </target>
134 1877 luisw
</project>