Repository: flex-sdk Updated Branches: refs/heads/feature/build-without-pre-existing-sdk [created] fc75cfcd2
- Refactored the way the blazeds jar is included (downloaded from Maven Central instead of copying from BLAZEDS_HOME) - Refactroed the fontkit retrieval to download the 4 fontkit jars instead of downloading the flex-sdk 4.6 and unpacking them from there Project: http://git-wip-us.apache.org/repos/asf/flex-sdk/repo Commit: http://git-wip-us.apache.org/repos/asf/flex-sdk/commit/fc75cfcd Tree: http://git-wip-us.apache.org/repos/asf/flex-sdk/tree/fc75cfcd Diff: http://git-wip-us.apache.org/repos/asf/flex-sdk/diff/fc75cfcd Branch: refs/heads/feature/build-without-pre-existing-sdk Commit: fc75cfcd279359c6562cd26c2fa715e9879670e8 Parents: f661863 Author: Christofer Dutz <[email protected]> Authored: Tue Sep 29 15:50:11 2015 +0200 Committer: Christofer Dutz <[email protected]> Committed: Tue Sep 29 15:50:11 2015 +0200 ---------------------------------------------------------------------- .gitignore | 2 - build.xml | 62 +----------------- frameworks/downloads.xml | 96 ++++++++++++++------------- modules/build.xml | 7 +- modules/compiler/build.xml | 3 + modules/downloads.xml | 24 ++++++- modules/flex-messaging-common/build.xml | 98 ---------------------------- 7 files changed, 78 insertions(+), 214 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/flex-sdk/blob/fc75cfcd/.gitignore ---------------------------------------------------------------------- diff --git a/.gitignore b/.gitignore index 03d57dc..865d742 100644 --- a/.gitignore +++ b/.gitignore @@ -14,7 +14,6 @@ # building target -[Bb]uild/ null tmp temp @@ -79,7 +78,6 @@ airsdk.xml *.sdf ipch/ obj/ -[Bb]in [Dd]ebug*/ !debugger/ modules/debugger/classes/ http://git-wip-us.apache.org/repos/asf/flex-sdk/blob/fc75cfcd/build.xml ---------------------------------------------------------------------- diff --git a/build.xml b/build.xml index d16dd24..6e6b579 100644 --- a/build.xml +++ b/build.xml @@ -70,31 +70,6 @@ property="TLF_HOME" value="${FLEX_HOME}/frameworks/projects" /> - <available file="${FLEX_HOME}/../flex-blazeds/modules/remoting" - type="dir" - property="BLAZEDS_HOME" - value="${FLEX_HOME}/../flex-blazeds" /> - - <available file="${FLEX_HOME}/../flex-blazeds/remoting" - type="dir" - property="BLAZEDS_HOME" - value="${FLEX_HOME}/../flex-blazeds" /> - - <available file="${FLEX_HOME}/../blazeds/modules/remoting" - type="dir" - property="BLAZEDS_HOME" - value="${FLEX_HOME}/../blazeds" /> - - <available file="${env.BLAZEDS_HOME}" - type="dir" - property="BLAZEDS_HOME" - value="${env.BLAZEDS_HOME}"/> - - <available file="${FLEX_HOME}/modules/flex-messaging-common/common/src" - type="dir" - property="BLAZEDS_HOME" - value="${FLEX_HOME}/modules/flex-messaging-common/common/src" /> - <tstamp> <format property="build.number.date" pattern="yyyyMMdd" /> </tstamp> @@ -188,7 +163,7 @@ <target name="prebuild" depends="check-compile-env,thirdparty-downloads,create-description" description="Stuff that needs to be done before any builds." /> - <target name="check-compile-env" depends="check-playerglobal-home,check-air-home,check-tlf-home,check-blazeds-home" + <target name="check-compile-env" depends="check-playerglobal-home,check-air-home,check-tlf-home" description="Check for the required environment variables for compilation."> <echo>OS: ${os.name} / ${os.version} / ${os.arch}</echo> <echo>VM: ${java.vm.name} / ${java.vm.version}</echo> @@ -254,21 +229,6 @@ </target> - <target name="check-blazeds-home" unless="BLAZEDS_HOME" - description="Check BLAZEDS_HOME is a directory."> - - <echo message="BLAZEDS_HOME is ${env.BLAZEDS_HOME}"/> - - <available file="${env.BLAZEDS_HOME}" - type="dir" - property="BLAZEDS_HOME" - value="${env.BLAZEDS_HOME}"/> - - <fail message="BLAZEDS_HOME must be set correctly for a release build" - unless="BLAZEDS_HOME"/> - - </target> - <target name="check-adobe-extension-manager-env" unless="ADOBE_EXTENSION_MANAGER.set" description="Check ADOBE_EXTENSION_MANAGER is a directory."> @@ -631,9 +591,6 @@ <!-- modules --> <antcall target="stage-modules"/> - <!-- blazeds --> - <antcall target="stage-blazeds"/> - <!-- asdoc --> <copy todir="${basedir}/temp/asdoc" includeEmptyDirs="false"> <fileset dir="${basedir}/asdoc"> @@ -759,23 +716,6 @@ </copy> </target> - <!-- blazeds --> - <target name="stage-blazeds"> - <copy todir="${basedir}/temp/modules/flex-messaging-common/common" includeEmptyDirs="false"> - <fileset dir="${BLAZEDS_HOME}/modules/common"> - <include name="**/**"/> - <exclude name="target/**"/> - <exclude name="classes/**"/> - </fileset> - </copy> - <copy todir="${basedir}/temp/modules/flex-messaging-common" includeEmptyDirs="false"> - <fileset dir="${BLAZEDS_HOME}"> - <include name="LICENSE"/> - <include name="NOTICE"/> - </fileset> - </copy> - </target> - <target name="stage-bin"> <copy todir="${basedir}/temp/bin" includeEmptyDirs="false"> <fileset dir="${basedir}/bin"> http://git-wip-us.apache.org/repos/asf/flex-sdk/blob/fc75cfcd/frameworks/downloads.xml ---------------------------------------------------------------------- diff --git a/frameworks/downloads.xml b/frameworks/downloads.xml index 17e4894..5d09c39 100644 --- a/frameworks/downloads.xml +++ b/frameworks/downloads.xml @@ -31,8 +31,11 @@ <!-- See note in modules/download.xml about this property. --> <property name="lib.opt.dir" value="${FLEX_HOME}/lib/external/optional"/> - <property name="adobe.flex.dir" value="adobe_flex_sdk_4.6"/> - <property name="adobe.flex.zip.file" value="flex_sdk_4.6.0.23201B.zip"/> + <property name="flex-deps.dir" value="flex_deps"/> + <property name="adobe.afe.file" value="afe.jar"/> + <property name="adobe.aglj40.file" value="aglj40.jar"/> + <property name="adobe.rideau.file" value="rideau.jar"/> + <property name="adobe.flex-fontkit.file" value="flex-fontkit.jar"/> <property name="pixelbender.url" value="http://www.apache.org/dyn/mirrors/mirrors.cgi" /> <property name="pixelbender.folder" value="flex/pixelbender/1.0/binaries" /> <property name="pixelbender.bin.zip" value="apache-flex-sdk-pixel-bender-1.0.0-bin.zip" /> @@ -75,7 +78,6 @@ </delete> <delete includeEmptyDirs="true" failonerror="false"> <fileset dir="${download.dir}"> - <include name="${adobe.flex.zip.file}"/> <include name="OSMF*/**"/> <include name="osmf*/**"/> <include name="swfobject*/**"/> @@ -216,7 +218,7 @@ <!-- Prompt before downloading. --> <target name="ask-font" unless="font.donot.ask" - description="Prompt the user before downloading BlaseDS"> + description="Prompt the user before downloading Fontkit libraries"> <property name="font.prompt.text" value="Apache Flex can optionally integrate with Adobe's embedded font support. @@ -239,59 +241,63 @@ <target name="get-font-jars" depends="ask-font" if="do.font.install"> - <available file="${download.dir}/${adobe.flex.dir}" type="dir" - property="adobe.flex.sdk.exists"/> - - <antcall target="get-adobe-flex-sdk"/> - + <antcall target="get-adobe-flex-dependencies"/> + <copy todir="${lib.opt.dir}" verbose="true"> - <fileset dir="${download.dir}/${adobe.flex.dir}/lib"> + <fileset dir="${download.dir}"> <include name="afe.jar" /> <include name="aglj40.jar" /> <include name="flex-fontkit.jar" /> <include name="rideau.jar" /> </fileset> </copy> - - <copy file="${download.dir}/${adobe.flex.dir}/license-adobesdk.htm" - tofile="${lib.opt.dir}/flex-fontkit-LICENSE.htm" verbose="true"/> - <copy file="${download.dir}/${adobe.flex.dir}/license-adobesdk.htm" - tofile="${lib.opt.dir}/afe-LICENSE.htm" verbose="true"/> - <copy file="${download.dir}/${adobe.flex.dir}/license-adobesdk.htm" - tofile="${lib.opt.dir}/aglj40-LICENSE.htm" verbose="true"/> - <copy file="${download.dir}/${adobe.flex.dir}/license-adobesdk.htm" - tofile="${lib.opt.dir}/rideau.jar-LICENSE.htm" verbose="true"/> </target> - <target name="get-adobe-flex-sdk" unless="adobe.flex.sdk.exists" - description="Downloads the Adobe Flex 4.6 SDK"> - - <available file="${download.dir}/${adobe.flex.zip.file}" type="file" - property="adobe.flex.sdk.download.exists"/> - - <antcall target="download-adobe-flex-sdk" /> - - <unzip src="${download.dir}/${adobe.flex.zip.file}" - dest="${download.dir}/${adobe.flex.dir}"> - <patternset> - <include name="license-adobesdk.htm"/> - <include name="lib/flex-messaging-common.jar"/> - <include name="lib/afe.jar" /> - <include name="lib/aglj40.jar" /> - <include name="lib/flex-fontkit.jar" /> - <include name="lib/rideau.jar" /> - </patternset> - </unzip> + <target name="get-adobe-flex-dependencies" + description="Making sure the Adobe Flex Dependencies ar available"> + + <available file="${download.dir}/${adobe.afe.file}" type="file" + property="adobe.afe.download.exists"/> + <available file="${download.dir}/${adobe.aglj40.file}" type="file" + property="adobe.aglj40.download.exists"/> + <available file="${download.dir}/${adobe.rideau.file}" type="file" + property="adobe.rideau.download.exists"/> + <available file="${download.dir}/${adobe.flex-fontkit.file}" type="file" + property="adobe.flex-fontkit.download.exists"/> + + <antcall target="download-afe" /> + <antcall target="download-aglj40" /> + <antcall target="download-rideau" /> + <antcall target="download-flex-fontkit" /> + </target> - - <target name="download-adobe-flex-sdk" unless="adobe.flex.sdk.download.exists" > - <mkdir dir="${download.dir}"/> - <get src="http://fpdownload.adobe.com/pub/flex/sdk/builds/flex4.6/${adobe.flex.zip.file}" - dest="${download.dir}/${adobe.flex.zip.file}"/> + + <target name="download-afe" unless="adobe.afe.download.exists" > + <mkdir dir="${download.dir}"/> + <get src="http://sourceforge.net/adobe/flexsdk/code/HEAD/tree/trunk/lib/afe.jar?format=raw" + dest="${download.dir}/${adobe.afe.file}"/> </target> - + + <target name="download-aglj40" unless="adobe.aglj40.download.exists" > + <mkdir dir="${download.dir}"/> + <get src="http://sourceforge.net/adobe/flexsdk/code/HEAD/tree/trunk/lib/aglj40.jar?format=raw" + dest="${download.dir}/${adobe.aglj40.file}"/> + </target> + + <target name="download-rideau" unless="adobe.rideau.download.exists" > + <mkdir dir="${download.dir}"/> + <get src="http://sourceforge.net/adobe/flexsdk/code/HEAD/tree/trunk/lib/rideau.jar?format=raw" + dest="${download.dir}/${adobe.rideau.file}"/> + </target> + + <target name="download-flex-fontkit" unless="adobe.flex-fontkit.download.exists" > + <mkdir dir="${download.dir}"/> + <get src="http://sourceforge.net/adobe/flexsdk/code/HEAD/tree/trunk/lib/flex-fontkit.jar?format=raw" + dest="${download.dir}/${adobe.flex-fontkit.file}"/> + </target> + <target name="clean-adobe-flex-sdk"> - <delete dir="${download.dir}/${adobe.flex.dir}"/> + <delete dir="${download.dir}/${flex-deps.dir}"/> </target> <target name="get_from_mirror"> http://git-wip-us.apache.org/repos/asf/flex-sdk/blob/fc75cfcd/modules/build.xml ---------------------------------------------------------------------- diff --git a/modules/build.xml b/modules/build.xml index 73a8351..73117be 100644 --- a/modules/build.xml +++ b/modules/build.xml @@ -83,7 +83,6 @@ <ant dir="${basedir}/antTasks" target="clean"/> <ant dir="${basedir}/asc/build/java" target="clean"/> <ant dir="${basedir}/thirdparty/xerces-patch" target="clean"/> - <ant dir="${basedir}/flex-messaging-common" target="clean"/> <delete includeemptydirs="true" failonerror="false"> <fileset dir="${FLEX_LIB}"> <include name="*" /> @@ -96,7 +95,7 @@ Build Java module JARs. --> - <target name="modules" depends="thirdparty,asc,swfutils,fxgutils,compiler,debugger,antTasks,flex-messaging-common" description="Full build of all JARs"/> + <target name="modules" depends="thirdparty,asc,swfutils,fxgutils,compiler,debugger,antTasks" description="Full build of all JARs"/> <!-- dev does not do a clean first and the batik and velocity libraries are not rebuilt. @@ -153,10 +152,6 @@ <ant dir="${basedir}/antTasks" target="dev"/> </target> - <target name="flex-messaging-common" description="build BlazeDS flex-messaging-common.jar"> - <ant dir="${basedir}/flex-messaging-common"/> - </target> - <target name="thirdparty" depends="xerces-patch,batik,velocity" /> <target name="xerces-patch" description="Build xercesPatch.jar based on xerces 2.9.1" > http://git-wip-us.apache.org/repos/asf/flex-sdk/blob/fc75cfcd/modules/compiler/build.xml ---------------------------------------------------------------------- diff --git a/modules/compiler/build.xml b/modules/compiler/build.xml index 5f42f25..1291c42 100644 --- a/modules/compiler/build.xml +++ b/modules/compiler/build.xml @@ -170,6 +170,9 @@ <!-- Copy the flex-tool-api jar --> <copy file="${lib.in.dir}/flex-tool-api.jar" todir="${lib.dir}"/> + <!-- Copy the blazeds jar --> + <copy file="${lib.in.dir}/flex-messaging-common.jar" todir="${lib.dir}"/> + <echo message="Building lib/mxmlc.jar"/> <jar file="${module.jar}" basedir="${module.classes}" includes="**/*.properties,flex2/compiler/**/*,flex2/license/**/*,flex2/linker/**/*,flex2/tools/*,flex2/tools/oem/Message.class,flex2/tools/oem/ProgressMeter.class,flex2/tools/oem/Component.class,flex2/tools/oem/Script.class,flash/**/*,flex/**/*" http://git-wip-us.apache.org/repos/asf/flex-sdk/blob/fc75cfcd/modules/downloads.xml ---------------------------------------------------------------------- diff --git a/modules/downloads.xml b/modules/downloads.xml index 92cf276..908453f 100644 --- a/modules/downloads.xml +++ b/modules/downloads.xml @@ -46,7 +46,9 @@ <property name="maven.search.url" value="https://search.maven.org/remotecontent?filepath="/> <property name="flexToolApi.name" value="flex-tool-api"/> <property name="flexToolApi.version" value="1.0.0"/> - + <property name="blazeds.name" value="flex-messaging-common"/> + <property name="blazeds.version" value="4.7.1"/> + <!-- Notes: For Apache, the JARS must be removed from the repository. @@ -86,7 +88,7 @@ they are each downloaded only if they don't already exist. --> - <target name="main" depends="batik-jars, commons-jars, javacc-jar, saxon9-jar, velocity-jars, xalan-jar, xerces-jars, flex-tool-api-jar" + <target name="main" depends="batik-jars, commons-jars, javacc-jar, saxon9-jar, velocity-jars, xalan-jar, xerces-jars, flex-tool-api-jar, blazeds-jar" description="Downloads all the required thirdparty JARs"/> <!-- @@ -608,4 +610,22 @@ <copy file="${download.dir}/flex-tool-api.jar" toDir="${lib.ext.dir}" verbose="true"/> </target> + <!-- + blazeds + --> + + <target name="blazeds-jar-check" description="Checks if flex-messaging-common.jar is in lib directory."> + <available file="${lib.ext.dir}/flex-messaging-common.jar" property="blazeds.jar.exists"/> + </target> + + <target name="blazeds-jar" depends="blazeds-jar-check" unless="blazeds.jar.exists" + description="Downloads and copies flex-messaging.jar to the lib directory."> + + <get src="${maven.search.url}/org/apache/flex/blazeds/${blazeds.name}/${blazeds.version}/${blazeds.name}-${blazeds.version}.jar" + dest="${download.dir}/flex-messaging-common.jar" + verbose="false"/> + + <copy file="${download.dir}/flex-messaging-common.jar" toDir="${lib.ext.dir}" verbose="true"/> + </target> + </project> http://git-wip-us.apache.org/repos/asf/flex-sdk/blob/fc75cfcd/modules/flex-messaging-common/build.xml ---------------------------------------------------------------------- diff --git a/modules/flex-messaging-common/build.xml b/modules/flex-messaging-common/build.xml deleted file mode 100644 index d7d7a47..0000000 --- a/modules/flex-messaging-common/build.xml +++ /dev/null @@ -1,98 +0,0 @@ -<!-- - - Licensed to the Apache Software Foundation (ASF) under one or more - contributor license agreements. See the NOTICE file distributed with - this work for additional information regarding copyright ownership. - The ASF licenses this file to You under the Apache License, Version 2.0 - (the "License"); you may not use this file except in compliance with - the License. You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - - Unless required by applicable law or agreed to in writing, software - distributed under the License is distributed on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - See the License for the specific language governing permissions and - limitations under the License. - ---> - -<project name="flex-messaging-common" default="main" basedir="."> - <property name="FLEX_HOME" location="${basedir}/../.."/> - - <property file="${FLEX_HOME}/env.properties"/> - <property environment="env"/> - <property file="${FLEX_HOME}/local.properties"/> - <property file="${FLEX_HOME}/build.properties"/> - - <property name="output.file" value="${FLEX_HOME}/lib/flex-messaging-common.jar"/> - <property name="flexTasks.location" value="${FLEX_HOME}/lib/flexTasks.jar"/> - <property name="project.uri" value="library://ns.adobe.com/flashx/textLayout"/> - - <available file="${FLEX_HOME}/../flex-blazeds/modules/remoting" - type="dir" - property="BLAZEDS_HOME" - value="${FLEX_HOME}/../flex-blazeds" /> - - <available file="${FLEX_HOME}/../blazeds/modules/remoting" - type="dir" - property="BLAZEDS_HOME" - value="${FLEX_HOME}/../blazeds" /> - - <available file="${basedir}/common/src" - type="dir" - property="src.folder.exists"/> - - <available file="${basedir}/common/src" - type="dir" - property="BLAZEDS_HOME" - value="${basedir}/common" /> - - <target name="main" depends="check-blazeds-home,clean,compile,compile.external" description="Clean build of flex-messaging-common.jar"> - </target> - - <target name="check-blazeds-home" unless="BLAZEDS_HOME" - description="Check BLAZEDS_HOME is a directory."> - - <echo message="BLAZEDS_HOME is ${env.BLAZEDS_HOME}"/> - - <available file="${env.BLAZEDS_HOME}" - type="dir" - property="BLAZEDS_HOME" - value="${env.BLAZEDS_HOME}"/> - - <fail message="BLAZEDS_HOME must be set correctly for a release build" - unless="BLAZEDS_HOME"/> - - </target> - - - <target name="clean" depends="check-blazeds-home,clean-external" description="Deletes the jar"> - <delete failonerror="false"> - <fileset dir="${FLEX_HOME}/lib"> - <include name="flex-messaging-common.jar"/> - </fileset> - </delete> - </target> - - <target name="compile" description="Compiles flex-messaging-common.jar" if="src.folder.exists"> - <ant dir="${basedir}/common"> - <property name="lib.dir" value="${FLEX_HOME}/lib" /> - <property name="module.dir" value="${basedir}/common" /> - <property name="license.file" value="${basedir}/LICENSE" /> - <property name="notice.file" value="${basedir}/NOTICE" /> - </ant> - </target> - - <target name="compile.external" description="Compile flex-messaging-common.jar in flex-blazeds repo" unless="src.folder.exists"> - <ant dir="${BLAZEDS_HOME}" target="common"> - <property name="lib.dir" value="${FLEX_HOME}/lib" /> - </ant> - </target> - - <target name="clean-external" description="clean in flex-blazeds repo" unless="src.folder.exists"> - <echo message="cleaning ${BLAZEDS_HOME}" /> - <ant dir="${BLAZEDS_HOME}" target="clean"/> - </target> - -</project>
