Back to Posts

FlashDevelop with ASC2 compiler

Konstantinos Egkarchos / February 16, 2013

In case you haven’t heard Adobe has released a new compiler for Flash and ActionScript. The new compiler does exactly what the legacy does, and mostly without any changes, but faster and better. Or at least that’s what it is supposed to do, but it’s still in Beta. So far you could only try it with Flash Builder 4.7 but thankfully there is a workaround for flashdevelop.

This post is based from this one by Alama, so in case you know French go on and prefer his guide.

What to Download

  • Adobe AIR SDK 3.6 with the new compiler – link
  • Patched fdbuild.exe for FlashDevelop – link, link2

Decompress the AIR SDK to a folder. I prefer creating an SDKs folder in C: drive, from there create a folder AIR3.6ASC2.0 and uncompress the AIR SDK there but feel free to uncopress it wherever you want, you’ll only need the link to that folder.

Installation

In case you have FlashDevelop open, close it.

Go to your installation folder of FlashDevelop then FlashDevelop>Tools>fdbuild and rename the current fdbuild.exe in order to keep it as a backup. Then uncompress the new fdbuild file you downloaded and put it there.

FlashDevelop requires from the SDK folder a flex-sdk-description.xml . You don’t need to have Flex by itself if you don’t use it. So let’s copy the one FlashDevelop already has. Go to FlashDevelop>Tools>flexsdk and copy flex-sdk-description.xml to your new SDK folder that you created before. Copy xml

Do the same for the file fcsh.jar in FlashDevelop>Tools>flexsdk>lib and put it to the lib folder.

The SDK is ready. Open FlashDevelop. Open a project that you want to test, open Project Properties from the Project Manager panel, go to SDK tab and in the Custom SDK path add the path to the new SDK that you have created. By hitting Apply your project will now compile by using the new compiler. There are more permanent ways to do that instead of adding it to each project, but I prefer an official version of FlashDevelop that supports it. Copy xml

You may encounter this error

C:\SDKs\AIR3.6ASC2.0\frameworks\flex-config.xml:47
Error: unable to open 'C:\SDKs\AIR3.6ASC2.0\frameworks\libs\player\11.4\playerglobal.swc'.
C:\SDKs\AIR3.6ASC2.0\frameworks\flex-config.xml (line: 47)
</external-library-path>

Build halted with errors (mxmlc).

In that case you’ll need to copy from FlashDevelop>Tools>flexsdk>frameworks>libs>player the missing folders to your new SDK. These contain the playerglobal.swc’s files for each version of flash that your new SDK is missing (mostly previous versions that FlashDevelop requires). Projects will now compile normally :)

You will notice smaller compile times and smaller final swf sizes. That’s it. Thanks to @Alama for his awesome guide.