common/templates/run-qmake.ant.xml.ftl
changeset 1028 11f25704ec27
parent 1025 a370015021c1
child 1047 ee03efed9e3c
--- a/common/templates/run-qmake.ant.xml.ftl	Tue May 11 16:57:09 2010 +0100
+++ b/common/templates/run-qmake.ant.xml.ftl	Wed May 12 12:56:34 2010 +0100
@@ -2,8 +2,75 @@
 <project name="run-qmake-${ant['sysdef.configuration']}" default="all">
 
     <target name="all">
-    <if><available file="${r'$'}{build.drive}/epoc32/tools/qmake.bat" type="file"/>
-    <then>
+
+	        <sequential>
+
+	<#list data["//unit/@bldFile/.."] as unit>
+          <#if (unit.@bldFile=="/sf/mw/qt/src/s60installs/deviceconfiguration")>
+                <echo>INFO: Building and configuring qmake for ${unit.@bldFile}</echo>
+                <if>
+                    <available file="${r'$'}{build.drive}/${unit.@bldFile}" type="dir"/>
+                    <then>
+                        <exec executable="cmd" dir="${r'$'}{build.drive}/${unit.@bldFile}" failonerror="false">
+                            <arg value="/C"/>
+                            <arg line="sbs -c tools2 -j 4 --logfile=${r'$'}{build.drive}/output/logs/${ant['build.id']}_compile_qmake.log"/>
+                        </exec>
+                    </then>
+                    <else>
+                       <echo message="ERROR: Directory ${r'$'}{build.drive}/${unit.@bldFile} doesn't exist."/>
+                       <fail message="Unit /sf/mw/qt/src/s60installs/deviceconfiguration is in the model, but not present on disk. Cannot build qmake!"/>
+                    </else>
+                </if>          
+	      </#if>
+    </#list>			
+			</sequential>
+
+	        <sequential>
+
+	<#list data["//unit/@bldFile/.."] as unit>
+          <#if (unit.@bldFile=="/sf/mw/qtextensions/group")>
+                <echo>INFO: Configuring qtextensions for ${unit.@bldFile}</echo>
+                <if>
+                    <available file="${r'$'}{build.drive}/${unit.@bldFile}" type="dir"/>
+                    <then>
+                        <exec executable="cmd" dir="${r'$'}{build.drive}/${unit.@bldFile}" failonerror="false">
+                            <arg value="/C"/>
+                            <arg line="sbs -c tools2 -j 4 --logfile=${r'$'}{build.drive}/output/logs/${ant['build.id']}_compile_qtextensions.log"/>
+                        </exec>
+                    </then>
+                    <else>
+                       <echo message="ERROR: Directory ${r'$'}{build.drive}/${unit.@bldFile} doesn't exist."/>
+                    </else>
+                </if>          
+	      </#if>
+    </#list>			
+			</sequential>
+			
+            <sequential>
+    <#list data["//unit/@proFile/.."] as unit>
+          <#if (unit.@proFile=="hb.pro")>
+                <echo>Running configure.py for ${unit.@bldFile}/${unit.@proFile}</echo>
+                <if>
+                    <available file="${r'$'}{build.drive}/${unit.@bldFile}" type="dir"/>
+                    <then>
+                        <exec executable="cmd" dir="${r'$'}{build.drive}/${unit.@bldFile}" failonerror="false">
+                            <arg value="/C"/>
+                            <arg value="python"/>
+                            <arg line ="configure.py --qmake-bin=\epoc32\tools\qmake.bat --qmake-spec=symbian-sbsv2 --platform=symbian --qmake-options=MMP_RULES+=EXPORTUNFROZEN"/>
+                        </exec>
+                    </then>
+                    <else>
+                       <echo message="ERROR: Directory ${r'$'}{build.drive}/${unit.@bldFile} doesn't exist."/>
+                    </else>
+                </if>
+                <echo>INFO: Exporting Orbit mkspecs to epoc32\tools for ${unit.@bldFile}/${unit.@proFile}</echo>
+
+                <copy file="${r'$'}{build.drive}/${unit.@bldFile}/hb_install.prf" todir="${r'$'}{build.drive}/epoc32/tools/qt/mkspecs/features" overwrite="true"/>
+                <copy file="${r'$'}{build.drive}/${unit.@bldFile}/hb.prf"         todir="${r'$'}{build.drive}/epoc32/tools/qt/mkspecs/features" overwrite="true"/>
+	  </#if>
+    </#list>
+
+            </sequential>
 
         <parallel threadCount="${r'$'}{number.of.threads}">
     <#list data["//unit/@proFile/.."] as unit>
@@ -30,24 +97,7 @@
                     <else>
                        <echo message="ERROR: Directory ${r'$'}{build.drive}/${unit.@bldFile} doesn't exist."/>
                     </else>
-                </if>
-          <#else>
-
-                <echo>Running configure.py for ${unit.@bldFile}/${unit.@proFile}</echo>
-                <if>
-                    <available file="${r'$'}{build.drive}/${unit.@bldFile}" type="dir"/>
-                    <then>
-                        <exec executable="cmd" dir="${r'$'}{build.drive}/${unit.@bldFile}" failonerror="false">
-                            <arg value="/C"/>
-                            <arg value="python"/>
-                            <arg line ="configure.py --qmake-bin=\epoc32\tools\qmake.bat --qmake-spec=symbian-sbsv2 --platform=symbian --qmake-options=MMP_RULES+=EXPORTUNFROZEN"/>
-                        </exec>
-                    </then>
-                    <else>
-                       <echo message="ERROR: Directory ${r'$'}{build.drive}/${unit.@bldFile} doesn't exist."/>
-                    </else>
-                </if>
-          
+                </if>          
 	  </#if>
 
 
@@ -55,8 +105,6 @@
     </#list>
         </parallel>
 
-    </then>
-    </if>
     </target>
     
 </project>