Saturday 24 October 2009

Flexbuilder on Linux

After migrating my desktop to ubuntu, biggest hurdle was of setting up flex builder on it. This was really an ordeal but the good news is that thanks to google, at last its done!!!

I will try to recapture what all I did to achieve this milestone....
1. Get Eclipse Europa, which is pretty easy. One can use later versions of Eclipse as well
2. Download Flex builder for linux (http://labs.adobe.com/downloads/flexbuilder_linux.html), again easy step
3. Follow the instructions available at Adobe Labs site (http://labs.adobe.com/technologies/flex/flexbuilder_linux/) these are very straight forward.. no issues till now.
4. Everything so far is fun, and flexbuilder is running hooray....

First thing after installation is to set up flex debugger... ooops.. after bit of googling it came down to..
1. Uninstall currently installed flashplayer.
2. Download most recent debug flashplayer for linux form http://www.adobe.com/support/flashplayer/downloads.html.
3. install the debug player and we are done.

Now comes AIR, how to do this one....
1. I tried to run/debug an AIR application using sfk 3.0.0 as bundled with flex builder ... "This application requires a version of the Adobe Integrated Runtime (AIR) which is no longer supported. Please contact the application author for an updated version."
2. Googled it and I reached http://labs.adobe.com/technologies/flex/flexbuilder_linux/releasenotes.html#air.
3. It asked me to download the latest air sdk from http://www.adobe.com/cfusion/entitlement/index.cfm?e=airsdk
4. Followed the instruction as they were word by word... previous error was gone but now you get "flex_sdk_3/bin/adl_lin: 1: Syntax error: word unexpected (expecting ")") "
5. There is a bug on for the same (https://bugs.adobe.com/jira/browse/FBE-323)
6. After much googling I resolved the problem by renaming adl and adt to adl_lin and adt_lin and placing it in sdk/3.0.0/bin.

So here are my steps to upgrade AIR SDK
Follow these simple steps to upgrade the SDK used by Flex Builder Linux on your machine:

* Download latest Adobe AIR SDK.
* Go to the sdks/3.0.0/ folder (in the Flex Builder installation directory).
* Delete the "runtimes" folder.
* Extract the latest Adobe AIR SDK and copy its contents into sdks/3.0.0/, overwriting existing files.
* Go to latest AIRSDK bin folder and rename adl and adt as adl_lin and adt_lin, copy these files to sdks/3.0.0/bin/.
* Go to sdks/3.0.0/runtimes/air/ and create a symlink "Linux" pointing to the "linux" folder in the same directory.


At last AIR ran, what a relief. I also encountered air runtime exception "invocation forwarded to primary instance", To resolve this just kill adl process.