Statistics
| Revision:

root / trunk / extensions / extNormalization / build.xml @ 39572

History | View | Annotate | Download (3.41 KB)

1 39392 fpuga
<project name="extNormalization" default="create-dist" basedir=".">
2 22677 jsanz
3
        <!-- set global properties for this build -->
4
        <property name="src" location="src" />
5
        <property name="src-test" location="src-test" />
6
        <property name="build-test" location="bin-test" />
7
        <property name="build" location="bin" />
8
        <property name="dist" location="dist" />
9 26217 vsanjaime
        <property name="lib" value="lib" />
10 22677 jsanz
        <property name="plugin" value="org.gvsig.normalization" />
11
        <property name="extension-dir" location="../_fwAndami/gvSIG/extensiones" />
12
13 39392 fpuga
        <target name="batch-build" depends="init, compile, copy-data-files, move-andami">
14
        </target>
15
16
        <target name="create-dist" depends="init, create-jar, copy-data-files, move-andami">
17
        </target>
18
19
        <target name="init" depends="clean">
20
                <mkdir dir="${build}" />
21
                <mkdir dir="${dist}" />
22
                <mkdir dir="${dist}/${plugin}" />
23
                <mkdir dir="${dist}/${plugin}/images" />
24
                <mkdir dir="${dist}/${plugin}/lib" />
25
                <mkdir dir="${dist}/${plugin}/about" />
26
        </target>
27 22677 jsanz
28 39392 fpuga
        <target name="compile">
29
                <loadEclipseClasspath project="${basedir}"/>
30
                <gvSIG-javac classpath="${eclipseClasspath}" />
31
        </target>
32
33
        <target name="create-jar">
34 26217 vsanjaime
                <jar jarfile="${dist}/${plugin}/${lib}/${plugin}.jar" basedir="${build}" />
35 39392 fpuga
        </target>
36 26217 vsanjaime
37 39392 fpuga
        <target name="copy-data-files">
38
                <copy file="config/config.xml" todir="${dist}/${plugin}/" />
39 26217 vsanjaime
                <copy todir="${dist}/${plugin}/">
40 22677 jsanz
                        <fileset dir="config" includes="text*.properties" />
41
                </copy>
42 31796 vsanjaime
                <copy todir="${dist}/${plugin}/">
43
                        <fileset dir="." includes="gpl.txt" />
44
                </copy>
45 26217 vsanjaime
46
                <copy todir="${dist}/${plugin}/${lib}">
47
                        <fileset dir="${lib}" includes="**/**" />
48 22677 jsanz
                </copy>
49 26217 vsanjaime
                <copy todir="${dist}/${plugin}/images">
50
                        <fileset dir="images/" includes="**/**" />
51 26212 vsanjaime
                </copy>
52 26217 vsanjaime
                <copy todir="${dist}/${plugin}/about">
53
                        <fileset dir="about/" includes="**/**" />
54
                </copy>
55 22677 jsanz
        </target>
56 39392 fpuga
57
        <target name="move-andami">
58
                        <copy todir="${extension-dir}/">
59
                                <fileset dir="${dist}" includes="**/**" />
60
                        </copy>
61
        </target>
62 22677 jsanz
63 39392 fpuga
64 26217 vsanjaime
        <target name="create-dist-bn" depends="build-number,create-dist" description="generate the distribution without the source file with BN">
65
                <echo>Changing de Build Number</echo>
66 22677 jsanz
67 26217 vsanjaime
                <delete dir="${dist}/${plugin}/about" />
68
                <mkdir dir="${dist}/${plugin}/about" />
69 31796 vsanjaime
70 26217 vsanjaime
                <mkdir dir="${dist}/tmp" />
71 22677 jsanz
72 26217 vsanjaime
                <copy todir="${dist}/tmp">
73
                        <fileset dir="about" includes="**" />
74
                </copy>
75 22677 jsanz
76 26217 vsanjaime
                <loadproperties srcFile="build.number" />
77
                <replace casesensitive="true" file="${dist}/tmp/normabout.htm" token="#build.number#" value="${build.number}" />
78
79
                <copy todir="${dist}/${plugin}/about">
80
                        <fileset dir="${dist}/tmp" includes="**" />
81 22677 jsanz
                </copy>
82 26217 vsanjaime
83 31796 vsanjaime
                <copy file="build.number" todir="${dist}/${plugin}" />
84
85 26217 vsanjaime
                <delete dir="${dist}/tmp" />
86
87 22677 jsanz
        </target>
88
89 39392 fpuga
90
91 22677 jsanz
92 39392 fpuga
93 26217 vsanjaime
        <target name="build-number" description="up build number">
94
                <propertyfile file="build.number" comment="Build number for ANT. Do not edit!">
95
                        <entry key="build.number" default="0" type="int" operation="+" />
96
                </propertyfile>
97
                <property file="build.number" />
98 22677 jsanz
        </target>
99
100 39392 fpuga
101 26217 vsanjaime
        <target name="clean" description="clean up">
102
                <echo>Delete dist folder</echo>
103
                <delete dir="${dist}" />
104 22677 jsanz
        </target>
105
106 39392 fpuga
107
108
109 26217 vsanjaime
        <target name="generate-installer" depends="create-dist-bn" description="generate the extension installer for win, linux and mac">
110
                <ant antfile="install/buildExt.xml" target="init">
111
                        <property name="basedir" location="install" />
112
                </ant>
113
        </target>
114
115
116 22677 jsanz
</project>