Statistics
| Revision:

svn-gvsig-desktop / tags / v1_1_2_1_Build_1046 / install / CD_ROM / buildCD.xml @ 43300

History | View | Annotate | Download (5.35 KB)

1
<project name="CD_gvSIG" default="main">
2

    
3
        <property file="buildCD.properties"/>
4
        <property file="../../_fwAndami/gvSIG/extensiones/com.iver.cit.gvsig/build.number"/>
5
    <!--<property file="../build.properties" prefix="install."/>
6
        <property name="OUTPUT_DIR" value="${install.OUTPUT_DIR}"/>-->
7
        <property name="OUTPUT_DIR" value="/tmp/versiones/v${version}_${build.number}"/>
8

    
9
        <propertyfile file="temp.properties">
10
                <entry key="bversion" value="${version}"/>
11
        </propertyfile>
12

    
13
        <property name="JRE_Zip" value="./JRE.zip"/>
14
        <property name="Extructure_Zip" value="./CD_extructure.zip"/>
15
        <property name="Andami" location="../../_fwAndami"/>
16
  <property name="binaries" location="../../binaries"/>
17
        <property name="base.dir" location="cd_gvSIG"/>
18
        <property name="nombreISO" value="gvSIG"/>
19

    
20
        <replace file="temp.properties" token="." value="_"/>
21
        <property file="temp.properties"/>
22

    
23
        <property name="Etiqueta" value="gvSIG-${bversion}_Build_${build.number}" />
24

    
25
  <available file="${OUTPUT_DIR}/gvSIG-${bversion}-src.zip" property="src.present"/> <!--Verificar que los fuentes esten con los instalables -->
26

    
27
        <condition property="we.linux">
28
                <os family="unix"/>
29
        </condition>
30

    
31
        <target name="main" depends="FilesCopy,detectSRC,FilesReplace,moveInstalables,makeISO"> <!-- el target makeInstalables no se realiza por defecto-->
32
                <delete file="temp.properties"/>
33
                <echo message="*******************************"/>
34
                <echo message="*******      DONE      ********"/>
35
                <echo message="*******************************"/>
36

    
37
        </target>
38
        <target name="FilesCopy">
39
                <delete dir="${base.dir}"/>
40
                <mkdir dir="${base.dir}"/>
41
                <unzip src="${JRE_Zip}" dest="${base.dir}"/>
42
                <unzip src="${Extructure_Zip}" dest="${base.dir}"/>
43
                <copy todir="${base.dir}/gvSIG/bin" file="${Andami}/andami.jar"/>
44
                <copy todir="${base.dir}/gvSIG/bin" file="${Andami}/castor.properties"/>
45
                <copy todir="${base.dir}/gvSIG/bin" file="${Andami}/schemas/andami-config.xml"/>
46

    
47
                <copy todir="${base.dir}/gvSIG/bin/lib" >
48
                        <fileset dir="${Andami}/lib"/>
49
                </copy>
50
                <copy todir="${base.dir}/gvSIG/bin/gvSIG" >
51
                        <fileset dir="${Andami}/gvSIG"/>
52
                </copy>
53
                <copy todir="${base.dir}/cachedir">
54
                        <fileset dir="${Andami}/cachedir"/>
55
                </copy>
56

    
57
                <copy todir="${base.dir}/gvSIG/cachedir">
58
                        <fileset dir="${Andami}/cachedir"/>
59
                </copy>
60
                <copy todir="${base.dir}/gvSIG/bin/cachedir">
61
                        <fileset dir="${Andami}/cachedir"/>
62
                </copy>
63

    
64

    
65
                <move file="${base.dir}/r_0.txt" tofile="${base.dir}/r_${build.number}.txt"/>
66

    
67
        </target>
68

    
69

    
70
        <target name="detectSRC" depends="withSRC,noSRC">
71
        </target>
72

    
73
        <target name="withSRC" if="src.present">
74
                <move file="${base.dir}/leeme_conSRC.htm" tofile="${base.dir}/leeme.htm"/>
75
                <move file="${base.dir}/readme_conSRC.htm" tofile="${base.dir}/readme.htm"/>
76
                <delete file="${base.dir}/leeme_sinSRC.htm"/>
77
                <delete file="${base.dir}/readme_sinSRC.htm"/>
78

    
79
        </target>
80

    
81
        <target name="noSRC" unless="src.present">
82
                <move file="${base.dir}/leeme_sinSRC.htm" tofile="${base.dir}/leeme.htm"/>
83
                <move file="${base.dir}/readme_sinSRC.htm" tofile="${base.dir}/readme.htm"/>
84
                <delete file="${base.dir}/leeme_conSRC.htm"/>
85
                <delete file="${base.dir}/readme_conSRC.htm"/>
86
        </target>
87

    
88
        <target name="FilesReplace">
89

    
90

    
91
                                <replace file="${base.dir}/r_${build.number}.txt" token="%VERSION%" value="${version}"/>
92
                                <replace file="${base.dir}/r_${build.number}.txt" token="%BVERSION%" value="${bversion}"/>
93
                                <replace file="${base.dir}/r_${build.number}.txt" token="%BUILDNUMBER%" value="${build.number}"/>
94

    
95
                                <replace file="${base.dir}/autorun.inf" token="%VERSION%" value="${bversion}"/>
96
                                <replace file="${base.dir}/autorun.inf" token="%BVERSION%" value="${bversion}"/>
97
                                <replace file="${base.dir}/autorun.inf" token="%BUILDNUMBER%" value="${build.number}"/>
98

    
99
                                <replace file="${base.dir}/leeme.htm" token="%VERSION%" value="${version}"/>
100
                                <replace file="${base.dir}/leeme.htm" token="%BVERSION%" value="${bversion}"/>
101
                                <replace file="${base.dir}/leeme.htm" token="%BUILDNUMBER%" value="${build.number}"/>
102

    
103
                                <replace file="${base.dir}/readme.htm" token="%VERSION%" value="${version}"/>
104
                                <replace file="${base.dir}/readme.htm" token="%BVERSION%" value="${bversion}"/>
105
                                <replace file="${base.dir}/readme.htm" token="%BUILDNUMBER%" value="${build.number}"/>
106

    
107

    
108
        </target>
109

    
110

    
111
        <target name="makeInstalables">
112

    
113
                <ant antfile="build.xml" dir="../" /> <!--Esto de momento en el branch no se usa-->
114

    
115
        </target>
116
        <target name="moveInstalables">
117
<!--                 Se debe pensar si se mantienen esos instalabes que se acaban de generar o se borran -->
118

    
119
                <copy todir="${base.dir}/instalar">
120
                        <fileset dir="${OUTPUT_DIR}" includes="*.bin,*.exe,*mac*.zip"/>
121
                </copy>
122

    
123
                <chmod dir="${base.dir}/instalar" perm="ugo+rx"
124
                       includes="*.bin"/>
125
                <chmod dir="${base.dir}/gvSIG.sh" perm="ugo+rx" />
126
                <chmod dir="${base.dir}/gvSIG/bin/gvSIG.sh" perm="ugo+rx" />
127
                <chmod dir="${base.dir}/gvSIG/JRE/linux/bin/java" perm="ugo+rx" />
128

    
129
        </target>
130

    
131
        <target name="makeISO" depends="makeISO_LIN,makeISO_WIN">
132
                <echo message="CD GENERATOR DONE" />
133
        </target>
134

    
135
        <target name="makeISO_LIN" if="we.linux">
136
                <exec executable="mkisofs">
137
                        <arg line="-udf -r -J -T -hide-joliet-trans-tbl -hide-rr-moved -V ${Etiqueta} -o ${nombreISO}-${bversion}_Build_${build.number}.iso ${base.dir}"/>
138
                </exec>
139

    
140
        </target>
141

    
142
        <target name="makeISO_WIN" unless="we.linux">
143
                <echo message="El sistema operativo no es Linux, se deberá generar un iso de la carpeta ${base.dir}"/>
144
        </target>
145

    
146

    
147
</project>