Developing AIR applications on Ubuntu Part 1

I've recently been looking at developing a cross-platform application on my Linux system for eventual use on Windows and Macintosh.  AIR became an obvious choice, because it's solid on Windows and Macintosh, and supports Linux pretty well as well. I'm still in the midst of development, but I thought I'd post some of my original thoughts on JS/HTML AIR development on Linux.

After deciding to develop on Linux, and on AIR, the first point that came up was whether to develop in HTML/JS or to use Flex.  Unfortunately, Adobe has made the decision not to support Flex Builder 3 fully on Linux, and the prospects for Flash Builder 4 don't look good either, so the main reason to use Flex over HTML/JavaScript (namely, a kick ass development environment) isn't really there in Linux.  I did check out the Flex SDK version 3 and 4 using Ant (and I'll post some thoughts on that later) but overall, without Flex Builder, Flex Development on Linux is just less appealing.   Given that there's some really good tooling out there in Linux for building HTML/JavaScript applications, I've decided to use that for my current project.

The first step to developing an AIR application is of course to download the AIR SDK from Adobe.  This is available as a download for Linux.  Extracting files from a tarball is probably pretty familiar to Linux users, but in case you aren't familiar with it, I'll give a short instruction set here.

  • Download the file to your home directory (/home/)
  • Unzip the directory to your temp directory (mkdir /tmp/air/; cd /tmp/air; tar xvjf /home//AdobeAIRSDK.tbz2)
  • Copy the AIR SDK to the "/opt" directory. (sudo mkdir /opt/air-sdk; sudo cp -r /tmp/air /opt/air-sdk/1.5.2)
  • Create a symbolic link to the "current" AIR SDK (sudo ln -s /opt/air-sdk/1.5.2 /opt/air/current)
  • Create a script to add the environment variables.

    export PATH=/opt/air-sdk/1.5.2/bin:$PATH
  • Setup your environment for your main username.  Basically, add to the end of your .profile file "source /opt/air-sdk/current/"

At this point, you should verify (by opening a command window and typing "source ~/.profile") that your profile is working.  If it's not, fix it and try again.  Once you've got it working, log all the way out of your linux account, and log back in again.  This should make sure that any terminals you launch will have access to the AIR tools (ADL and ADT).


ADL is the primary debugging tool that you'll use when developing an AIR application.  adl is a Java program, and takes as an argument the Application descriptor XML for an AIR application.


ADT is the primary packaging and package signing tool that you will use when "compiling" and "distributing" your AIR application.  The adt tool uses the same application xml descriptor as adl, and requires an SSL certificate.  You may generate your own "Self Signed" certificate, but it will be less trusted than a real SSL certificate. Finally, when packaging an application using adt you MUST be connected to the internet.  ADT verifies the current date with several known timeservers to validate that the certificate is current and not expired.  If you are not connected to the internet, ADT WILL fail.

Next time I will get into a description of my project structure, and how to work with the HTML and JavaScript files that make up the AIR application.