Change Qt qmake order to allow -config qmake args to be passed correctly
authorShabe Razvi <shaber@symbian.org>
Wed, 26 May 2010 13:46:40 +0100
changeset 1047 ee03efed9e3c
parent 1046 871bdf0d7610
child 1048 f3a459ab2cfe
Change Qt qmake order to allow -config qmake args to be passed correctly
common/templates/run-qmake.ant.xml.ftl
--- a/common/templates/run-qmake.ant.xml.ftl	Tue May 25 20:30:36 2010 +0100
+++ b/common/templates/run-qmake.ant.xml.ftl	Wed May 26 13:46:40 2010 +0100
@@ -76,7 +76,7 @@
     <#list data["//unit/@proFile/.."] as unit>
             <sequential>
 
-          <#if (unit.@proFile!="hb.pro")>
+          <#if (unit.@proFile!="projects.pro" && unit.@proFile!="hb.pro")>
 
                 <echo>Running qmake for ${unit.@bldFile}/${unit.@proFile}</echo>
                 <if>
@@ -105,6 +105,32 @@
     </#list>
         </parallel>
 
+            <sequential>
+    <#list data["//unit/@proFile/.."] as unit>
+          <#if (unit.@proFile="projects.pro")>
+                <echo>Running qmake 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="qmake"/>
+                            <!-- arg value="-listgen"/ -->
+                            <#if unit.@qmakeArgs[0]??>
+                            <arg line="${unit.@qmakeArgs?xml}"/>
+                            <#else>
+                            <arg line="${ant['qt.qmake.default.args']?xml}"/>
+                            </#if>
+                            <arg value="${unit.@proFile?xml}"/>
+                        </exec>
+                    </then>
+                    <else>
+                       <echo message="ERROR: Directory ${r'$'}{build.drive}/${unit.@bldFile} doesn't exist."/>
+                    </else>
+                </if>          
+	  </#if>
+    </#list>
+            </sequential>
     </target>
     
 </project>