You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@flex.apache.org by cf...@apache.org on 2012/05/03 20:42:36 UTC

svn commit: r1333581 [2/2] - in /incubator/flex/trunk: ./ frameworks/ frameworks/projects/advancedgrids/ frameworks/projects/airframework/ frameworks/projects/airspark/ frameworks/projects/authoringsupport/ frameworks/projects/automation/ frameworks/pr...

Modified: incubator/flex/trunk/frameworks/projects/rpc/build.xml
URL: http://svn.apache.org/viewvc/incubator/flex/trunk/frameworks/projects/rpc/build.xml?rev=1333581&r1=1333580&r2=1333581&view=diff
==============================================================================
--- incubator/flex/trunk/frameworks/projects/rpc/build.xml (original)
+++ incubator/flex/trunk/frameworks/projects/rpc/build.xml Thu May  3 18:42:34 2012
@@ -21,16 +21,19 @@
 
 <project name="rpc" default="main" basedir=".">
 	<property name="FLEX_HOME" location="${basedir}/../../.."/>
-	<property name="locale" value="en_US"/>
+	
+    <property environment="env"/>
+    <property file="${FLEX_HOME}/env.properties"/>
 	<property file="${FLEX_HOME}/build.properties"/>
 
-    <!-- If you change this, update <target-player/> in the <compc/> tasks. -->
-    <property name="local.playerglobal.version" value="11.1"/>
-	
+	<property name="locale" value="en_US"/>
+
 	<macrodef name="bundle">
 		<attribute name="locale"/>
 		<sequential>
 		<echo message="Compiling frameworks/locale/@{locale}/rpc_rb.swc"/>
+		<echo message="Using ${env.PLAYERGLOBAL_HOME}/playerglobal.swc" level="info"/>
+
 		<!-- Load the <compc> task. We can't do this at the <project> level -->
 		<!-- because targets that run before flexTasks.jar gets built would fail. -->
 		<taskdef resource="flexTasks.tasks" classpath="${FLEX_HOME}/lib/flexTasks.jar"/>
@@ -52,8 +55,10 @@
 			<source-path path-element="${FLEX_HOME}/frameworks/projects/framework/bundles/@{locale}"/>
 			<include-libraries/>
 			<library-path/>
+			<external-library-path dir="${env.PLAYERGLOBAL_HOME}">
+                <include name="playerglobal.swc"/>
+            </external-library-path>
 			<external-library-path dir="${FLEX_HOME}/frameworks/libs">
-                <include name="player/${local.playerglobal.version}/playerglobal.swc"/>
                 <include name="framework.swc"/>
 			</external-library-path>
 		</compc>
@@ -170,6 +175,8 @@
 	<target name="compile" description="Compiles rpc.swc">
 		<echo file="${FLEX_HOME}/frameworks/version.properties" append="false">build=${build.number}</echo>
 		<echo message="Compiling frameworks/libs/rpc.swc"/>
+		<echo message="Using ${env.PLAYERGLOBAL_HOME}/playerglobal.swc" level="info"/>
+
 		<!-- Load the <compc> task. We can't do this at the <project> level -->
 		<!-- because targets that run before flexTasks.jar gets built would fail. -->
 		<taskdef resource="flexTasks.tasks" classpath="${FLEX_HOME}/lib/flexTasks.jar"/>
@@ -190,7 +197,6 @@
 		<compc fork="true"
 			   output="${FLEX_HOME}/frameworks/libs/rpc.swc"
                resource-bundle-list="${basedir}/bundles.properties">
-            <!-- If you change this, update ${local.playerglobal.version} above. -->
             <target-player>11.1</target-player>
 			<jvmarg line="${compc.jvm.args}"/>
 			<namespace uri="library://ns.adobe.com/flex/mx" manifest="${basedir}/manifest.xml"/>
@@ -199,8 +205,10 @@
 			<include-classes>RPCClasses</include-classes>
 			<source-path path-element="${basedir}/src"/>
 			<library-path/>
+			<external-library-path dir="${env.PLAYERGLOBAL_HOME}">
+                <include name="playerglobal.swc"/>
+            </external-library-path>
 			<external-library-path dir="${FLEX_HOME}/frameworks/libs">
-                <include name="player/${local.playerglobal.version}/playerglobal.swc"/>
 				<include name="framework.swc"/>
                 <include name="textLayout.swc"/>
 			</external-library-path>

Modified: incubator/flex/trunk/frameworks/projects/spark/build.xml
URL: http://svn.apache.org/viewvc/incubator/flex/trunk/frameworks/projects/spark/build.xml?rev=1333581&r1=1333580&r2=1333581&view=diff
==============================================================================
--- incubator/flex/trunk/frameworks/projects/spark/build.xml (original)
+++ incubator/flex/trunk/frameworks/projects/spark/build.xml Thu May  3 18:42:34 2012
@@ -21,13 +21,19 @@
 
 <project name="spark" default="main" basedir=".">
 	<property name="FLEX_HOME" location="${basedir}/../../.."/>
+
+        <property environment="env"/>
+    <property file="${FLEX_HOME}/env.properties"/>
 	<property file="${FLEX_HOME}/build.properties"/>
+
 	<property name="locale" value="en_US"/>
     
     <macrodef name="bundle">
 		<attribute name="locale"/>
 		<sequential>
 			<echo message="Compiling frameworks/locale/@{locale}/spark_rb.swc"/>
+			<echo message="Using ${env.PLAYERGLOBAL_HOME}/playerglobal.swc" level="info"/>
+
 			<!-- Load the <compc> task. We can't do this at the <project> level -->
 			<!-- because targets that run before flexTasks.jar gets built would fail. -->
 			<taskdef resource="flexTasks.tasks" classpath="${FLEX_HOME}/lib/flexTasks.jar"/>
@@ -52,8 +58,10 @@
 				<source-path path-element="${FLEX_HOME}/frameworks/projects/spark/src"/>
 				<include-libraries/>
 				<library-path/>
+                <external-library-path dir="${env.PLAYERGLOBAL_HOME}">
+                    <include name="playerglobal.swc"/>
+                </external-library-path>
 				<external-library-path dir="${FLEX_HOME}/frameworks/libs">
-					<include name="player/${global.playerglobal.version}/playerglobal.swc"/>
 					<include name="framework.swc"/>
 				</external-library-path>
 			</compc>
@@ -180,6 +188,8 @@
 	<target name="compile" depends="prepare" description="Compiles spark.swc">
 		<echo file="${FLEX_HOME}/frameworks/version.properties" append="false">build=${build.number}</echo>
 		<echo message="Compiling frameworks/libs/spark.swc"/>
+		<echo message="Using ${env.PLAYERGLOBAL_HOME}/playerglobal.swc" level="info"/>
+
 		<!-- Load the <compc> task. We can't do this at the <project> level -->
 		<!-- because targets that run before flexTasks.jar gets built would fail. -->
 		<taskdef resource="flexTasks.tasks" classpath="${FLEX_HOME}/lib/flexTasks.jar"/>
@@ -204,8 +214,10 @@
 			<include-classes>SparkClasses</include-classes>
 			<source-path path-element="${basedir}/src"/>
 			<library-path />
+			<external-library-path dir="${env.PLAYERGLOBAL_HOME}">
+                <include name="playerglobal.swc"/>
+            </external-library-path>
 			<external-library-path dir="${FLEX_HOME}/frameworks/libs">
-                <include name="player/${global.playerglobal.version}/playerglobal.swc"/>
 				<include name="framework.swc"/>
 				<include name="mx/mx.swc"/>
                 <include name="osmf.swc"/>

Modified: incubator/flex/trunk/frameworks/projects/spark_dmv/build.xml
URL: http://svn.apache.org/viewvc/incubator/flex/trunk/frameworks/projects/spark_dmv/build.xml?rev=1333581&r1=1333580&r2=1333581&view=diff
==============================================================================
--- incubator/flex/trunk/frameworks/projects/spark_dmv/build.xml (original)
+++ incubator/flex/trunk/frameworks/projects/spark_dmv/build.xml Thu May  3 18:42:34 2012
@@ -21,6 +21,9 @@
 
 <project name="spark_dmv" default="main" basedir=".">
 	<property name="FLEX_HOME" location="${basedir}/../../.."/>
+	
+    <property environment="env"/>
+    <property file="${FLEX_HOME}/env.properties"/>
 	<property file="${FLEX_HOME}/build.properties"/>
 		
 	<target name="main" depends="clean,compile" description="Clean build of spark_dmv.swc and en_US"/>
@@ -40,6 +43,8 @@
 	<target name="compile" description="Compiles spark_dmv.swc">
 		<echo file="${FLEX_HOME}/frameworks/version.properties" append="false">build=${build.number}</echo>
 		<echo message="Compiling frameworks/libs/spark_dmv.swc"/>
+		<echo message="Using ${env.PLAYERGLOBAL_HOME}/playerglobal.swc" level="info"/>
+
 		<!-- Load the <compc> task. We can't do this at the <project> level -->
 		<!-- because targets that run before flexTasks.jar gets built would fail. -->
 		<taskdef resource="flexTasks.tasks" classpath="${FLEX_HOME}/lib/flexTasks.jar"/>
@@ -64,8 +69,10 @@
 			<include-classes>SparkDmvClasses</include-classes>
 			<source-path path-element="${basedir}/src"/>
 			<library-path />
+            <external-library-path dir="${env.PLAYERGLOBAL_HOME}">
+                <include name="playerglobal.swc"/>
+            </external-library-path>
 			<external-library-path dir="${FLEX_HOME}/frameworks/libs">
-			<include name="player/${global.playerglobal.version}/playerglobal.swc"/>
 				<include name="framework.swc"/>
 				<include name="spark.swc"/>
 				<include name="mx/mx.swc"/>

Modified: incubator/flex/trunk/frameworks/projects/sparkskins/build.xml
URL: http://svn.apache.org/viewvc/incubator/flex/trunk/frameworks/projects/sparkskins/build.xml?rev=1333581&r1=1333580&r2=1333581&view=diff
==============================================================================
--- incubator/flex/trunk/frameworks/projects/sparkskins/build.xml (original)
+++ incubator/flex/trunk/frameworks/projects/sparkskins/build.xml Thu May  3 18:42:34 2012
@@ -22,12 +22,11 @@
 <project name="sparkskins" default="main" basedir=".">
 
 	<property name="FLEX_HOME" location="${basedir}/../../.."/>
-
+	
+    <property environment="env"/>
+    <property file="${FLEX_HOME}/env.properties"/>
 	<property file="${FLEX_HOME}/build.properties"/>
 
-    <!-- If you change this, update <target-player/> in the <compc/> tasks. -->
-    <property name="local.playerglobal.version" value="11.1"/>
-
 	<target name="main" depends="clean,compile" description="Clean build of sparkskins.swc"/>
 
 	<target name="clean">
@@ -42,6 +41,8 @@
 
 	<target name="compile" description="Compiles sparkskins.swc">
 		<echo message="Compiling frameworks/libs/sparkskins.swc"/>
+		<echo message="Using ${env.PLAYERGLOBAL_HOME}/playerglobal.swc" level="info"/>
+
 		<!-- Load the <compc> task. We can't do this at the <project> level -->
 		<!-- because targets that run before flexTasks.jar gets built would fail. -->
 		<taskdef resource="flexTasks.tasks" classpath="${FLEX_HOME}/lib/flexTasks.jar"/>
@@ -61,14 +62,15 @@
 		<compc fork="true" 
 			   output="${FLEX_HOME}/frameworks/libs/sparkskins.swc"
 			   resource-bundle-list="${basedir}/bundles.properties">
-            <!-- If you change this, update ${local.playerglobal.version} above. -->
             <target-player>11.1</target-player>
 			<jvmarg line="${compc.jvm.args}"/>
 			<include-classes>SparkSkinsClasses</include-classes>
 			<source-path path-element="${basedir}/src"/>
 			<library-path/>
+            <external-library-path dir="${env.PLAYERGLOBAL_HOME}">
+                <include name="playerglobal.swc"/>
+            </external-library-path>
             <external-library-path dir="${FLEX_HOME}/frameworks/libs">
-                <include name="player/${local.playerglobal.version}/playerglobal.swc"/>
 				<include name="framework.swc"/>
 				<include name="spark.swc" />
                 <include name="textLayout.swc"/>
@@ -99,9 +101,9 @@
 		<asdoc output="${FLEX_HOME}/tempDoc" lenient="true" failonerror="true" keep-xml="true" skip-xsl="true" >
 		    <compiler.source-path path-element="${basedir}/src"/>
 		    <doc-classes class="SparkSkinsClasses"/>
-		    <external-library-path dir="${FLEX_HOME}/frameworks/libs/player/${local.playerglobal.version}">
-		    	<include name="playerglobal.swc" />
-		    </external-library-path>
+            <external-library-path dir="${env.PLAYERGLOBAL_HOME}">
+                <include name="playerglobal.swc"/>
+            </external-library-path>
 		    <external-library-path dir="${FLEX_HOME}/frameworks/libs">
 		    	<include name="framework.swc" />
 				<include name="spark.swc" />

Modified: incubator/flex/trunk/frameworks/projects/textLayout/build.xml
URL: http://svn.apache.org/viewvc/incubator/flex/trunk/frameworks/projects/textLayout/build.xml?rev=1333581&r1=1333580&r2=1333581&view=diff
==============================================================================
--- incubator/flex/trunk/frameworks/projects/textLayout/build.xml (original)
+++ incubator/flex/trunk/frameworks/projects/textLayout/build.xml Thu May  3 18:42:34 2012
@@ -19,8 +19,11 @@
 
 <project name="combined" default="main" basedir=".">
 	<property name="FLEX_HOME" location="${basedir}/../../.."/>
+	
+    <property environment="env"/>
+    <property file="${FLEX_HOME}/env.properties"/>
 	<property file="${FLEX_HOME}/build.properties"/>
-	<property name="local.playerglobal.version" value="11.1"/>
+
 	<property name="output.file" value="${FLEX_HOME}/frameworks/libs/textLayout.swc"/>
 	<property name="output.docs" value="${FLEX_HOME}/tempDoc"/>
 	<property name="flexTasks.location" value="${FLEX_HOME}/lib/flexTasks.jar"/>
@@ -37,6 +40,8 @@
 		<attribute name="locale"/>
 		<sequential>
 			<echo message="Compiling frameworks/locale/@{locale}/textLayout_rb.swc"/>
+			<echo message="Using ${env.PLAYERGLOBAL_HOME}/playerglobal.swc" level="info"/>
+
 			<!-- Load the <compc> task. We can't do this at the <project> level -->
 			<!-- because targets that run before flexTasks.jar gets built would fail. -->
 			<taskdef resource="flexTasks.tasks" classpath="${FLEX_HOME}/lib/flexTasks.jar"/>
@@ -51,8 +56,10 @@
 				<source-path path-element="${basedir}/bundles/@{locale}"/>
 				<include-libraries/>
 				<library-path/>
+				<external-library-path dir="${env.PLAYERGLOBAL_HOME}">
+					<include name="playerglobal.swc"/>
+				</external-library-path>
 				<external-library-path dir="${FLEX_HOME}/frameworks/libs">
-					<include name="player/${local.playerglobal.version}/playerglobal.swc"/>
 					<include name="framework.swc"/>
 				</external-library-path>
 			</compc>

Modified: incubator/flex/trunk/frameworks/projects/wireframe/build.xml
URL: http://svn.apache.org/viewvc/incubator/flex/trunk/frameworks/projects/wireframe/build.xml?rev=1333581&r1=1333580&r2=1333581&view=diff
==============================================================================
--- incubator/flex/trunk/frameworks/projects/wireframe/build.xml (original)
+++ incubator/flex/trunk/frameworks/projects/wireframe/build.xml Thu May  3 18:42:34 2012
@@ -22,12 +22,11 @@
 <project name="wireframe" default="main" basedir=".">
 
 	<property name="FLEX_HOME" location="${basedir}/../../.."/>
-
+	
+    <property environment="env"/>
+    <property file="${FLEX_HOME}/env.properties"/>
 	<property file="${FLEX_HOME}/build.properties"/>
 
-    <!-- If you change this, update <target-player/> in the <compc/> tasks. -->
-    <property name="local.playerglobal.version" value="11.1"/>
-
 	<target name="main" depends="clean,compile" description="Clean build of wireframe.swc"/>
 
 	<target name="clean">
@@ -42,6 +41,8 @@
 
 	<target name="compile" description="Compiles wireframe.swc">
 		<echo message="Compiling frameworks/themes/Wireframe/wireframe.swc"/>
+		<echo message="Using ${env.PLAYERGLOBAL_HOME}/playerglobal.swc" level="info"/>
+
 		<!-- Load the <compc> task. We can't do this at the <project> level -->
 		<!-- because targets that run before flexTasks.jar gets built would fail. -->
 		<taskdef resource="flexTasks.tasks" classpath="${FLEX_HOME}/lib/flexTasks.jar"/>
@@ -61,14 +62,15 @@
 		<compc fork="true"
 			   output="${FLEX_HOME}/frameworks/themes/Wireframe/wireframe.swc"
 			   resource-bundle-list="${basedir}/bundles.properties">
-            <!-- If you change this, update ${local.playerglobal.version} above. -->
             <target-player>11.1</target-player>
 			<jvmarg line="${compc.jvm.args}"/>
 			<include-classes>WireframeClasses</include-classes>
 			<source-path path-element="${basedir}/src"/>
 			<library-path/>
+            <external-library-path dir="${env.PLAYERGLOBAL_HOME}">
+                <include name="playerglobal.swc"/>
+			</external-library-path>
             <external-library-path dir="${FLEX_HOME}/frameworks/libs">
-                <include name="player/${local.playerglobal.version}/playerglobal.swc"/>
 				<include name="framework.swc"/>
 				<include name="mx/mx.swc"/>
 				<include name="spark.swc"/>
@@ -105,9 +107,9 @@
 		<asdoc output="${FLEX_HOME}/tempDoc" lenient="true" failonerror="true" keep-xml="true" skip-xsl="true" fork="true">
 			<compiler.source-path path-element="${basedir}/src"/>
 			<doc-classes class="WireframeClasses"/>
-			<external-library-path dir="${FLEX_HOME}/frameworks/libs/player/${local.playerglobal.version}">
-				<include name="playerglobal.swc" />
-			</external-library-path>
+            <external-library-path dir="${env.PLAYERGLOBAL_HOME}">
+                <include name="playerglobal.swc"/>
+            </external-library-path>
 			<external-library-path dir="${FLEX_HOME}/frameworks/libs">
 				<include name="framework.swc" />
 				<include name="mx/mx.swc"/>

Modified: incubator/flex/trunk/modules/compiler/src/java/flex2/compiler/common/CompilerConfiguration.java
URL: http://svn.apache.org/viewvc/incubator/flex/trunk/modules/compiler/src/java/flex2/compiler/common/CompilerConfiguration.java?rev=1333581&r1=1333580&r2=1333581&view=diff
==============================================================================
--- incubator/flex/trunk/modules/compiler/src/java/flex2/compiler/common/CompilerConfiguration.java (original)
+++ incubator/flex/trunk/modules/compiler/src/java/flex2/compiler/common/CompilerConfiguration.java Thu May  3 18:42:34 2012
@@ -64,6 +64,7 @@ public class CompilerConfiguration imple
 	public static final String LOCALE_TOKEN = "{locale}";
     public static final String TARGET_PLAYER_MAJOR_VERSION_TOKEN = "{targetPlayerMajorVersion}";
     public static final String TARGET_PLAYER_MINOR_VERSION_TOKEN = "{targetPlayerMinorVersion}";
+    public static final String PLAYERGLOBAL_HOME_TOKEN = "{playerglobalHome}";
     
     // this is passed as the list of soft prerequisites for options like
     // library-path, source-path which need to have {locale}, etc., set already
@@ -129,6 +130,9 @@ public class CompilerConfiguration imple
         // {targetPlayerMajorVersion}, {targetPlayerMinorVersion}
         pathlist = expandTargetPlayerToken(pathlist, parentConfiguration);
         
+        // {playerglobalHome}
+        pathlist = expandPlayerglobalToken(pathlist);
+        
         // {locale}
         return expandLocaleToken(pathlist, locales, cv);
     }
@@ -155,7 +159,29 @@ public class CompilerConfiguration imple
             processed[i] = StringUtils.substitute(processed[i], 
             	TARGET_PLAYER_MINOR_VERSION_TOKEN, targetPlayerMinorVersion);
         }
-    
+
+        return processed;
+    }
+
+    /**
+     * Replaces instances of {playerglobalHome} with the environment variable
+     * PLAYERGLOBAL_HOME.  Doesn't turn the paths into VirtualFiles (yet, 
+     * @see expandLocaleToken()). 
+     */
+    private static String[] expandPlayerglobalToken(String[] pathlist)
+    {
+        final String[] processed = new String[pathlist.length];
+        
+        String playerglobalHome = System.getenv("PLAYERGLOBAL_HOME");
+        if (playerglobalHome == null)
+            playerglobalHome = "";
+
+        for (int i = 0; i < pathlist.length; i++)
+        {
+            processed[i] = StringUtils.substitute(pathlist[i], 
+            	PLAYERGLOBAL_HOME_TOKEN, playerglobalHome);
+        }
+
         return processed;
     }
 

Modified: incubator/flex/trunk/mustella/build.xml
URL: http://svn.apache.org/viewvc/incubator/flex/trunk/mustella/build.xml?rev=1333581&r1=1333580&r2=1333581&view=diff
==============================================================================
--- incubator/flex/trunk/mustella/build.xml (original)
+++ incubator/flex/trunk/mustella/build.xml Thu May  3 18:42:34 2012
@@ -36,7 +36,7 @@
     <property name="excludes_done" value="true" />
 
 	
-<property name="HOMEPATH" value="${env.HOMEDRIVE}${env.HOMEPATH}" />
+    <property name="HOMEPATH" value="${env.HOMEDRIVE}${env.HOMEPATH}" />
 
     <pathconvert property="mustella.dir" dirsep="/" >
        <path location="${basedir}" />
@@ -82,7 +82,7 @@
     <property name="aschartspath" value="."/>
     <property name="frameworks.dir1" value="${frameworks}" />
     <property name="librarypath" value="${frameworks.dir1}/libs/framework.swc,${frameworks.dir1}/libs/charts.swc,${frameworks.dir1}/libs/rpc.swc"/>
-    <property name="external.librarypath" value="libs/playerglobal.swc"/>
+    <property name="external.librarypath" value="${env.PLAYERGLOBAL_HOME}/playerglobal.swc"/>
     <property name="rsl" value="" />
 
     <property name="coach" value="true" />
@@ -2799,14 +2799,14 @@ we could have pmd_doler do the dir split
 	</target>
 		
     <target name="compilemustellaswc" if="do_mustellaswc_compile" >
-            	<exec  executable="${compc.dir}/${compc.exe}" >
+            <exec  executable="${compc.dir}/${compc.exe}" >
         	<!-- output swc name    -->
         	<arg value="-output=${mustella.swc.dir}/${mustella.swc.name}" />
         	<!-- include path -->
         	<arg value="-source-path=${mustella.dir}/as3/src/mustella" />
             <!-- clear library path -->
             <arg value="-library-path="/>
-            <arg value="-external-library-path=${sdk.dir}/frameworks/libs/air,${sdk.dir}/frameworks/libs,${sdk.dir}/frameworks/libs/mx" />
+            <arg value="-external-library-path=${env.AIR_HOME}/frameworks/libs/air,${sdk.dir}/frameworks/libs,${sdk.dir}/frameworks/libs/mx" />
         	<arg value="ApolloFilePath"/>
         	<arg value="Assert"/>
         	<arg value="AssertError"/>