87 <reference refid="sf.spec.tools.system.definition.files" torefid="system.definition.files" /> |
87 <reference refid="sf.spec.tools.system.definition.files" torefid="system.definition.files" /> |
88 </antcall> |
88 </antcall> |
89 |
89 |
90 </target> |
90 </target> |
91 |
91 |
92 <target name="sf-package-binary"> |
92 <target name="sf-create-manifest"> |
|
93 |
|
94 <!-- turn comma separated list into sbs friendly -c list, and _ separated list for friendly log names --> |
|
95 <propertyregex property="i.sf.spec.sbs.config.expanded" override="true" input="${sf.spec.sbs.config}" regexp="(,)" replace=" -c " defaultValue="${sf.spec.sbs.config}" global="true" casesensitive="false"/> |
|
96 <propertyregex property="i.sf.spec.sbs.config.expanded.logname" override="true" input="${sf.spec.sbs.config}" regexp="(,)" replace="_" defaultValue="${sf.spec.sbs.config}" global="true" casesensitive="false"/> |
|
97 |
|
98 <echo message="INFO Creating WHAT output for target : ${i.sf.spec.sbs.config.expanded}"/> |
|
99 <echo message="INFO Logname: ${i.sf.spec.sbs.config.expanded.logname} + Config: ${sf.spec.sysdef.configurations.list}"/> |
|
100 |
|
101 <!-- define sbs args, log name etc --> |
|
102 <exec executable="cmd" dir="${build.drive}" failonerror="false" output="${build.drive}/manifest_binaries_${sf.spec.job.name}.txt"> |
|
103 <arg line="/c sbs.bat"/> |
|
104 <arg line="-c ${i.sf.spec.sbs.config.expanded}"/> |
|
105 <arg line="-s ${build.drive}\output\build\canonical_system_definition.xml"/> |
|
106 <arg line="${sf.spec.sbs.options}"/> |
|
107 <arg line="--what"/> |
|
108 <!-- output only what is found on disk --> |
|
109 <arg line=" | perl -pe "while ($line=<STDIN>) { my $orig =$line; chomp $line; print $orig if (-e "$line"); };""/> |
|
110 <arg line=" | perl -pe "s/^${build.drive}\\//; s/\\/\//g; ""/> <!-- remove drive and backslash to fwdslash--> |
|
111 <arg line=" | findstr /B /V tools"/> <!-- ignore raptor exports into root of drive--> |
|
112 </exec> |
|
113 |
|
114 </target> |
|
115 |
|
116 <target name="sf-package-binary" depends="sf-create-manifest"> |
93 |
117 |
94 <exec executable="7z" dir="${build.drive}" output="${build.log.dir}/zip_${build.id}_binaries_${sf.spec.job.name}.log"> |
118 <exec executable="7z" dir="${build.drive}" output="${build.log.dir}/zip_${build.id}_binaries_${sf.spec.job.name}.log"> |
95 <arg value="a"/> |
119 <arg value="a"/> |
96 <arg value="-t${sf.spec.package.zip.format}"/> |
120 <arg value="-t${sf.spec.package.zip.format}"/> |
97 <arg value="-x@${build.log.dir}/listdir_${build.id}_bootstrap.log"/> |
121 <arg value="-i@${build.drive}/manifest_binaries_${sf.spec.job.name}.txt"/> |
98 <arg value="-x!epoc32\build"/> |
|
99 <arg value="-x!sf"/> |
|
100 <arg value="${build.drive}/output/zips/release/binaries_${sf.spec.job.name}.zip"/> |
122 <arg value="${build.drive}/output/zips/release/binaries_${sf.spec.job.name}.zip"/> |
101 <arg value="epoc32\"/> |
123 <arg value="manifest_binaries_${sf.spec.job.name}.txt"/> |
102 </exec> |
|
103 |
|
104 <!-- create a manifest in the root of the build drive --> |
|
105 <exec executable="perl" dir="${build.drive}" output="${build.log.dir}/manifest_binaries_${sf.spec.job.name}.txt"> |
|
106 <arg value="${sf.common.config.dir}/tools/7z_list_to_manifest.pl"/> |
|
107 <arg value="${build.drive}\output\zips\release\binaries_${sf.spec.job.name}.zip"/> |
|
108 <arg value="-z"/> |
|
109 </exec> |
|
110 |
|
111 <!-- add manifest to zip and update release meta data --> |
|
112 <exec executable="7z" dir="${build.drive}"> |
|
113 <arg value="a"/> |
|
114 <arg value="-t${sf.spec.package.zip.format}"/> |
|
115 <arg value="${build.drive}/output/zips/release/binaries_${sf.spec.job.name}.zip"/> |
|
116 <arg value="${build.log.dir}/manifest_binaries_${sf.spec.job.name}.txt"/> |
|
117 </exec> |
124 </exec> |
118 |
125 |
119 <antcall target="sf-zip-content"> |
126 <antcall target="sf-zip-content"> |
120 <param name="zip.config.file" value="${temp.build.dir}/zip.cfg.xml.ftl"/> |
127 <param name="zip.config.file" value="${temp.build.dir}/zip.cfg.xml.ftl"/> |
121 <param name="zip.target.name" value="bin-${sf.spec.job.name}-metadata" /> |
128 <param name="zip.target.name" value="bin-${sf.spec.job.name}-metadata" /> |