common/build.xml
changeset 111 5b0bc2f89660
parent 109 cb16ca6483d9
child 114 585c31b1dac6
equal deleted inserted replaced
110:6c981bc63bab 111:5b0bc2f89660
   143         
   143         
   144         <if>
   144         <if>
   145             <istrue value="${sf.spec.sourcesync.enable}" />
   145             <istrue value="${sf.spec.sourcesync.enable}" />
   146             <then>
   146             <then>
   147                 <runtarget target="sf-get-source"/>
   147                 <runtarget target="sf-get-source"/>
   148                 <runtarget target="sf-merge-epoc32"/>
       
   149                 
   148                 
   150                 <if><istrue value="${sf.spec.package.src.enable}"/>
   149                 <if><istrue value="${sf.spec.package.src.enable}"/>
   151                 <then>
   150                 <then>
   152                     <echo message="INFO Packaging Source"/>
   151                     <echo message="INFO Packaging Source"/>
   153                     <runtarget target="sf-package-source"/>
   152                     <runtarget target="sf-package-source"/>
   154                 </then>
   153                 </then>
   155                 </if>
   154                 </if>
       
   155                 
       
   156                 <runtarget target="sf-unpack-rnd"/>
   156             </then>
   157             </then>
   157             <else>
   158             <else>
   158                 <!-- record fact that no sources.csv used. required by diamondize-bom  -->
   159                 <!-- record fact that no sources.csv used. required by diamondize-bom  -->
   159                 <touch file="${build.log.dir}/BOM/sources.csv"/> 
   160                 <touch file="${build.log.dir}/BOM/sources.csv"/> 
   160             </else>
   161             </else>
   362             <param name="zip.config.file" value="${sf.common.config.dir}/generated/zip.cfg.xml.ftl"/>
   363             <param name="zip.config.file" value="${sf.common.config.dir}/generated/zip.cfg.xml.ftl"/>
   363             <param name="zip.target.name" value="src" />
   364             <param name="zip.target.name" value="src" />
   364         </antcall>
   365         </antcall>
   365     </target>
   366     </target>
   366     
   367     
   367     <target name="sf-package-binary" depends="sf-preprocess-package-config">
   368     <target name="sf-package-binary" depends="sf-preprocess-package-config,sf-package-postbuild-rnd">
   368         <!--antcall target="sf-zip-content">
   369         <!--antcall target="sf-zip-content">
   369             <param name="zip.config.file" value="${sf.common.config.dir}/generated/zip.cfg.xml.ftl"/>
   370             <param name="zip.config.file" value="${sf.common.config.dir}/generated/zip.cfg.xml.ftl"/>
   370             <param name="zip.target.name" value="bin" />
   371             <param name="zip.target.name" value="bin" />
   371         </antcall-->
   372         </antcall-->
   372 
   373 
   373         <if><available file="${build.drive}/rnd/internal/initial" type="dir" />
   374         <if><available file="${build.drive}/rnd_excludefile.txt" />
   374         <then>
   375         <then>
   375             <!-- get listing of rnd location for exclude later -->
       
   376             <antcall target="sf-list-dir" inheritAll="false">
       
   377                 <param name="sf.list.name" value="rnd_binaries"/>
       
   378                 <param name="sf.dir.location" value="${build.drive}/rnd/internal/initial"/>
       
   379             </antcall>
       
   380             <echo message="Packaging with exclude list"/>
   376             <echo message="Packaging with exclude list"/>
   381             <exec executable="7za" dir="${build.drive}" output="${build.log.dir}/zip_${build.id}_binaries_epoc32.log">
   377             <exec executable="7za" dir="${build.drive}" output="${build.log.dir}/zip_${build.id}_binaries_epoc32.log">
   382             <arg value="a"/>
   378             <arg value="a"/>
   383             <arg value="-tzip"/>
   379             <arg value="-tzip"/>
   384             <arg value="-x@${build.log.dir}/listdir_${build.id}_rnd_binaries.log"/> <!-- excludes -->
   380             <arg value="-x@${build.drive}/rnd_excludefile.txt"/> <!-- excludes -->
   385             <arg value="-x!epoc32\build"/> 
   381             <arg value="-x!epoc32\build"/> 
   386             <arg value="-xr!*.sym"/> 
   382             <arg value="-xr!*.sym"/> 
   387             <arg value="binaries_epoc.zip"/> 
   383             <arg value="binaries_epoc.zip"/> 
   388             <arg value="epoc32\"/>
   384             <arg value="epoc32\"/>
   389             </exec>
   385             </exec>
       
   386             <move file="${build.drive}/rnd_excludefile.txt" todir="${build.log.dir}/"/>
   390         </then>
   387         </then>
   391         <else>
   388         <else>
   392             <echo message="Packaging without exclude list"/>
   389             <echo message="Packaging without exclude list"/>
   393             <exec executable="7za" dir="${build.drive}" output="${build.log.dir}/zip_${build.id}_binaries_epoc32.log">
   390             <exec executable="7za" dir="${build.drive}" output="${build.log.dir}/zip_${build.id}_binaries_epoc32.log">
   394             <arg value="a"/>
   391             <arg value="a"/>
   402         </if>
   399         </if>
   403         <if><available file="${build.drive}/binaries_epoc.zip"/>
   400         <if><available file="${build.drive}/binaries_epoc.zip"/>
   404         <then><move file="${build.drive}/binaries_epoc.zip" todir="${build.drive}/output/zips/"/></then>
   401         <then><move file="${build.drive}/binaries_epoc.zip" todir="${build.drive}/output/zips/"/></then>
   405         </if>
   402         </if>
   406     </target>
   403     </target>
       
   404 
       
   405     <target name="sf-package-postbuild-rnd" depends="sf-preprocess-package-config">
       
   406 
       
   407         <!-- zip any RnD _includefile.txt files generated during source packaging -->
       
   408         <exec executable="perl" dir="${build.drive}/" failonerror="false" output="${build.log.dir}/zip_postbuild.log">
       
   409             <arg value="${sf.common.config.dir}/tools/zip_includefiles.pl"/>
       
   410         </exec>
       
   411         <!-- cleanup my moving includefiles to logs and zips to zips\postbuild -->
       
   412         <move todir="${build.log.dir}">
       
   413            <fileset dir="${build.drive}"><include name="*_includefile.txt"/></fileset>
       
   414         </move>
       
   415         <move todir="${build.drive}/output/zips/postbuild">
       
   416            <fileset dir="${build.drive}"><include name="bin_rnd_*.zip"/></fileset>
       
   417         </move>
       
   418         <!-- TODO: merge with release_metadata.xml ? -->
       
   419     </target>
       
   420 
   407     <!-- unpack rnd zips if available -->
   421     <!-- unpack rnd zips if available -->
   408     <target name="sf-merge-epoc32">
   422     <target name="sf-unpack-rnd">
   409         <echo message="Unpacking any available RnD binaries"/>
   423         <echo message="Unpacking any available RnD binaries"/>
   410         <exec executable="7za" dir="${build.drive}" output="${build.log.dir}/unzip_${build.id}_binaries_rnd.log">
   424         <exec executable="7za" dir="${build.drive}" output="${build.log.dir}/unzip_${build.id}_binaries_rnd.log">
   411         <arg value="x"/>
   425         <arg value="x"/>
   412         <arg value="${build.drive}/output/zips/bin_rnd*.zip"/>
   426         <arg value="${build.drive}/output/zips/bin_rnd*.zip"/>
   413         </exec>
   427         </exec>