actionscript-3flashantterminalcompc

Error: unable to open AIRSDK/frameworks/libs/player/11.1/playerglobal.swc


I get the following error intermittently when compiling a swc using compc:

[exec] Using AIR SDK: /Applications/Adobe Flash Builder 4.7/eclipse/plugins/com.adobe.flash.compiler_4.7.0.349722/AIRSDK
[exec] Loading configuration: /Applications/Adobe Flash Builder 4.7/eclipse/plugins/com.adobe.flash.compiler_4.7.0.349722/AIRSDK/frameworks/flex-config.xml
[exec] 
[exec] /Applications/Adobe Flash Builder 4.7/eclipse/plugins/com.adobe.flash.compiler_4.7.0.349722/AIRSDK/frameworks/flex-config.xml:47
[exec] Error: unable to open '/Applications/Adobe Flash Builder 4.7/eclipse/plugins/com.adobe.flash.compiler_4.7.0.349722/AIRSDK/frameworks/libs/player/11.1/playerglobal.swc'.
[exec] /Applications/Adobe Flash Builder 4.7/eclipse/plugins/com.adobe.flash.compiler_4.7.0.349722/AIRSDK/frameworks/flex-config.xml (line: 47)
[exec]         </external-library-path>
[exec] 
[exec] 

I can't seem to find any reason why this would happen. The directory /Applications/Adobe Flash Builder 4.7/eclipse/plugins/com.adobe.flash.compiler_4.7.0.349722/AIRSDK is setup as AIR SDK 3.7 and as I said the error is intermittent, if I keep building it will eventually go away.

Another thing that seems weird is this:

[exec] Loading configuration: /Applications/Adobe Flash Builder 4.7/eclipse/plugins/com.adobe.flash.compiler_4.7.0.349722/AIRSDK/frameworks/flex-config.xml

So I am baffled why it would ever attempt to look for 11.1/playerglobal.swc. As it works sometimes, it seems like everything is setup correctly but I haven't been able to figure out what causes the script to wig out.

This step is from an ant script. The ant script is as follows:

<exec executable="${COMPC}" failonerror="true">
    <env key="FLEX_HOME" value="${FLEX_HOME}"/>
    <env key="AIR_SDK_HOME" value="${AIR_SDK_HOME}"/>
    <arg line="-source-path ${SRC_DIR}"/>
    <arg line="-output ${BIN_DIR}/${OUTPUT_FILENAME}"/>
    <arg line="-swf-version ${SWF_VERSION}"/>
    <arg line="-external-library-path+=&quot;${FLEX_HOME}/frameworks/libs/air/airglobal.swc&quot;"/>
    <arg line="-define+=CONFIG::LOGLEVEL,4"/>
    <arg line="--keep-as3-metadata+=TypeHint,EditorData,Embed,Inject,PostInject"/>
    <arg line="-inline"/>
    <arg line="-include-classes ${classes}"/>
</exec>

-swf-version is being passed in as 20, I have an echo right before this task executes to verify it doesn't change.

The AIR_SDK_HOME and FLEX_HOME values are being set as such:

<property name="FLEX_HOME" value="/Applications/Adobe Flash Builder 4.7/eclipse/plugins/com.adobe.flash.compiler_4.7.0.349722/AIRSDK" />
<property name="AIR_SDK_HOME" value="${FLEX_HOME}" />

ADDITIONAL NOTES:

Usually when this error happens it continues to happen until the terminal window is closed and restarted.

Another thing I am starting to notice is that it happens more frequently (or perhaps only happens) immediately after a failed build within the same terminal window.

Any help or advice is appreciated! Thanks!


Solution

  • I resolved this problem such a way: - manualy create folder: AIRSDK_HOME\frameworks\libs\player\11.1\ - copy actual version 'playerglobal.swc' ( I have from AIRSDK_HOME\frameworks\libs\player\15.0\ to AIRSDK_HOME\frameworks\libs\player\11.1\ )