Use qt.qmake.ant.template property for custom qmake template
authorShabe Razvi <shaber@symbian.org>
Thu, 15 Apr 2010 16:54:31 +0100
changeset 971 35d8126bcf87
parent 970 ac316618673b
child 972 608adae327af
Use qt.qmake.ant.template property for custom qmake template
common/build.xml
common/templates/run-qmake.ant.xml.ftl
--- a/common/build.xml	Wed Apr 14 14:12:43 2010 +0100
+++ b/common/build.xml	Thu Apr 15 16:54:31 2010 +0100
@@ -60,7 +60,8 @@
     <property name="ccm.user.password" value="set_to_any_value_to_skip_scm_checks__for_helium_5"/>
     <property name="ats.drive" value="${sf.spec.ats_worker.drive}"/>
     <property name="skip.sbs.layer.generation" value="true"/> <!-- helium 7: needs to be predefined before hlm import -->
-
+    <property name="qt.qmake.ant.template" value="${sf.common.config.dir}/templates/run-qmake.ant.xml.ftl"/> <!-- override helium default to use our own template -->
+    
     <!-- override helium 7 defaults to operate like helium 5.
        *.log.dir props dont exist yet so need to be set now, otherwise they 
        become immutable after helium.ant.xml import -->
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/common/templates/run-qmake.ant.xml.ftl	Thu Apr 15 16:54:31 2010 +0100
@@ -0,0 +1,33 @@
+<?xml version="1.0"?>
+<project name="run-qmake-${ant['sysdef.configuration']}" default="all">
+
+    <target name="all">
+        <parallel threadCount="${r'$'}{number.of.threads}">
+    <#list data["//unit/@proFile/.."] as unit>
+            <sequential>
+                <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>
+            </sequential>
+    </#list>
+        </parallel>
+    </target>
+    
+</project>