Since 01.01.2011 Adobe has stopped support for Flex Builder 3 alpha on Linux. After this date the plugin effectively stopped working even if you had a valid, payed license as it was my case. This was a very sad news since I do a lot of flex development. I don’t need much of the Builder since I use ant for the compilation but at least code completion in .as and .mxml files is a must. As such I will try to describe here how to install the fb4 on linux with some success. Even if this describes the setup for 32 bit java on a 64 bit machine you can skip the 32 bit libraries part and install 64bit java.

I run 64 ubuntu Maverick Meerkat but since there is no gain, but only memory loss, in using eclipse 64 bit I will describe the install on 32 bit java. Everything is based on the fb4linux project. Most of the info here is based on the install document by adding some information which was missing.

  • system: java 1.6.32 – 32 bit, eclipse 3.5. Note: you will require the “classic” version. I was used to download the “java” version because it’s lighter and searched for minutes a menu option which does not exist
  • download the fb4linux parts, combine them and extract the archive:

cat FB4Linux* >FB4Linux.tar.bz2
tar xvfz FB4Linux.tar.bz2
  • in eclipse go to window -> preferences -> general -> capabilities and enable classic update (does not exist in “java” version of eclipse)
  • go to help -> software updates -> manage configuration and register the path where you extracted FB4linux as an extension location
  • restart eclipse, you will probably get a lot of errors
  • install 32 bit utils which will allow to have the required 32 bit libs and some libs
apt-get install ia32-libs getlibs
getlibs -l libatk-bridge.so
getlibs -l libgvfsdbus.so
  • after that you will be able to start eclipse without so many errors but if you start playing with the interface you will notice in console an error about a missing libswt-mozilla-gtk-3550.so. The solution (see http://code.google.com/p/fb4linux/wiki/HowToFixedFB4Frozen) consist to download the libswf from here and copy it to /usr/lib32. You will also have to install some libs:
getlibs -p xulrunner-1.9.2
getlibs -l libxcb-atom.so.1
getlibs -l libxcb-event.so.1
getlibs -l libxcb-aux.so.0
getlibs -l libstartup-notification-1.so.0
getlibs -l libhunspell-1.2.so.0
  • there is no need to actually link the libswf in java lib because the LD_LIBRARY_PATH will take care of that
  • here is the content of a script eclipse.sh I created in the eclipse directory which sets all the paths required
#!/bin/bash
export JAVA_HOME=/opt/jdk1.6.0_23/
export PATH=$JAVA_HOME/bin:$PATH
export GDK_NATIVE_WINDOWS=1
export MOZILLA_FIVE_HOME=/usr/lib32/xulrunner-1.9.2
export LD_LIBRARY_PATH=/usr/lib32:/usr/lib32/xulrunner-1.9.2.13:/usr/lib32/gio/modules/
$(dirname $0)/eclipse
  • now fb4 runs ok with the exception that CTRL+SHIFT+R does not work. The solution consist to go to Window -> Customize Perspective -> Command Groups Availability and uncheck Flash Navigation. This has to be done for all perspectives you are using (java, flex, etc.)

Now the editors are usable but there are a few remaining problems which I haven’t solved yet:

  • on mxml editor there is no line number in the status bar which is a bit frustrating
  • eclipse does not exit properly. I have to do a pkill eclipse at the end. I assume this is related to the following error:
/usr/lib/gio/modules/libgvfsdbus.so: wrong ELF class: ELFCLASS64
Failed to load module: /usr/lib/gio/modules/libgvfsdbus.so

which is strange because the library exists in lib32. I assume it has something to do with some code using a full path to search for this library. This bug seems to be related to ia32-libs package and there are several issues open in launchpad.

Comments:

FlashBuilder4 for Linux « Pedro Lopes Research -

[…] Also suggest to read: http://www.len.ro/2011/01/fb4-on-linux/ […]