Statistics
| Revision:

root / trunk / extensions / extgvSIGPiloto-Raster / build.xml @ 9462

History | View | Annotate | Download (4.28 KB)

1 9019 nacho
<project name="extgvSIGPiloto-Raster" default="generate-without-source" basedir=".">
2 8999 nacho
    <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="andami" location="../_fwAndami"/>
10
  <property name="extensionsDir" location="${andami}/gvSIG/extensiones"/>
11 9019 nacho
  <property name="mainplugin" value="com.iver.cit.gvsig"/>
12
  <property name="lib-dir" location="${extensionsDir}/${mainplugin}/lib"/>
13 9045 nacho
  <property name="drivers-dir" location="${extensionsDir}/${mainplugin}/drivers" />
14 8999 nacho
15
  <!--Plugins-->
16
  <property name="plugin" value="com.iver.cit.gvsig.pilotoraster"/>
17
  <property name="jarName" value="${plugin}.jar"/>
18
19
  <target name="init">
20
    <!-- Create the time stamp -->
21
    <tstamp/>
22
23
        <echo>
24
                Compiling ${ant.project.name}...</echo>
25
    <!-- Create the build directory structure used by compile -->
26
    <mkdir dir="${dist}"/>
27
          <!-- Creamos un fichero con el timeStamp para que lo lea el FPanelAbout -->
28
          <!-- <buildnumber/> -->
29
  </target>
30
31 9045 nacho
  <target name="raw" depends="" description="Genera el driver del raw">
32
        <mkdir dir="${drivers-dir}/raw" />
33
        <jar jarfile="${drivers-dir}/raw/raw.jar" basedir="./bin" includes="org/gvsig/rasterTools/raw/**" />
34
  </target>
35
36 8999 nacho
  <target name="generate-without-source"
37 9045 nacho
                  description="generate the distribution without the source file"
38
                  depends="raw">
39 8999 nacho
40
    <!-- Create the distribution directory -->
41
    <mkdir dir="${dist}"/>
42
43
    <!-- Jars de las extensiones -->
44
    <jar jarfile="${dist}/${jarName}" basedir="${build}"
45 9045 nacho
            includes="com/iver/cit/gvsig/**,org/gvsig/rasterTools/**"/>
46 8999 nacho
47
          <!-- Instala extensión salvar a raster -->
48
    <move todir="${extensionsDir}/${plugin}/">
49
            <fileset dir="${dist}" includes="${jarName}"/>
50
    </move>
51 9045 nacho
          <copy file="config/config.xml" todir="${extensionsDir}/${plugin}" overwrite="yes"/>
52
          <copy file="config/plugin.dtd" todir="${extensionsDir}/${plugin}" overwrite="yes"/>
53 9095 nacho
          <copy file="config/palettes.xml" todir="${user.home}/gvSIG" overwrite="no"/>
54 9045 nacho
    <copy file="lib/gvsig-ui.jar" todir="${lib-dir}" overwrite="yes"/>
55
    <copy file="lib/cms.jar" todir="${lib-dir}" overwrite="yes"/>
56 9019 nacho
    <copy file="lib/jcommon-1.0.0.jar" todir="${lib-dir}"/>
57
    <copy file="lib/jfreechart-1.0.1.jar" todir="${lib-dir}"/>
58
    <copy file="lib/jfreechart-1.0.1-demo.jar" todir="${lib-dir}"/>
59 8999 nacho
          <copy todir="${extensionsDir}/${plugin}">
60
                      <fileset dir="config" includes="text*.properties"/>
61
          </copy>
62 9019 nacho
63 8999 nacho
  </target>
64
65
        <target name="batch-build"
66
                        description="compile the sources, create the jar file"
67
                        depends="init,compile,create-jar,copy-data-files,move-to-andami">
68
        </target>
69
70
        <target name="compile" description="compile the source" >
71
                <!-- Compile the Java code from ${src} to ${build} -->
72
                <mkdir dir="${build}" />
73
                <javac  srcdir="${src}"
74
                        destdir="${build}"
75
                        source="1.4"
76
                        target="1.4"
77
                        debug="${debug}"
78
                        debuglevel="${debuglevel}"
79
                        classpath="${compile-classpath}"/>
80
        </target>
81
82
        <target name="create-jar"
83
                        description="Creates the plugin jar">
84
                <mkdir dir="${dist}"/>
85
            <jar jarfile="${dist}/${jarName}" basedir="${build}"
86 9045 nacho
                    includes="com/iver/cit/gvsig/**,org/gvsig/rasterTools/**"/>
87 8999 nacho
        </target>
88
89
        <target name="copy-data-files">
90 9045 nacho
            <copy file="config/config.xml" todir="${dist}" overwrite="yes"/>
91
                  <copy file="config/plugin.dtd" todir="${dist}" overwrite="yes"/>
92 9095 nacho
                <copy file="config/palettes.xml" todir="${user.home}/gvSIG" overwrite="no"/>
93 9045 nacho
            <copy file="lib/gvsig-ui.jar" todir="${lib-dir}" overwrite="yes"/>
94
            <copy file="lib/cms.jar" todir="${lib-dir}" overwrite="yes"/>
95 9019 nacho
                <copy file="lib/jcommon-1.0.0.jar" todir="${lib-dir}"/>
96
            <copy file="lib/jfreechart-1.0.1.jar" todir="${lib-dir}"/>
97
            <copy file="lib/jfreechart-1.0.1-demo.jar" todir="${lib-dir}"/>
98 8999 nacho
                <copy todir="${dist}">
99
                        <fileset dir="config" includes="text*.properties"/>
100
                </copy>
101
        </target>
102
103
        <target name="move-to-andami">
104
            <move todir="${extensionsDir}/${plugin}/">
105
                    <fileset dir="${dist}" includes="**/**"/>
106
            </move>
107
        </target>
108
109
  <target name="clean"
110
        description="clean up" >
111
    <!-- Delete the ${build} and ${dist} directory trees -->
112
    <delete dir="${dist}"/>
113
    <delete dir="${build}"/>
114
  </target>
115
</project>