Skip to content. | Skip to navigation

Personal tools
Log in
You are here: Home Blog Run, xul, run

Run, xul, run

Posted by Manuel Reinhardt at Sep 12, 2012 05:10 PM |

My eclipse/birt installation has been giving me a headache lately, spontaneously crashing with some reports when I tried to open the preview or the report viewer. With the latter I got the error message

No more handles [Could not detect registered XULRunner to use]

Investigating, I found that ubuntu does not supply a xulrunner package any more. I tried getting xulrunner from mozilla, but eclipse does not support the latest xulrunner versions. Of course, older versions only come in 32 bit flavour. I tried a 32 bit version of eclipse but didn't get it working (later I discovered that was because I set the XULRunnerPath vmarg incorrectly - it mostly works now, except for lots of "wrong ELF class" messages).

So I grabbed the xulrunner source, checked the XULRunner tutorial, and after much cursing managed to compile the bugger.

In addition to the prerequisites mentioned in the tutorial, I had to install some more packages:

sudo apt-get install libxt-dev libidl-dev gcc-4.4 g++-4.4

I set the following environment variables:


Also, at some point make complained about a missing file curl/types.h, referenced from toolkit/crashreporter/google-breakpad/src/common/linux/ It turned out that curl/types.h has become obsolete, so I just deleted the line

#include <curl/types.h>

from Another missing file was I crossed my fingers and tried

cp security/coreconf/ security/coreconf/

...and it worked!

This is my .mozconfig:

mk_add_options MOZ_CO_PROJECT=xulrunner
mk_add_options MOZ_MAKE_FLAGS="-j4"
ac_add_options --enable-application=xulrunner
ac_add_options --disable-tests

and this an excerpt from my eclipse.ini:

-vmargs -Dosgi.requiredJavaVersion=1.5 -Dhelp.lucene.tokenizer=standard -XX:MaxPermSize=256m -Dorg.eclipse.swt.browser.XULRunnerPath=/opt/mozilla-1.9.2/obj-x86_64-unknown-linux-gnu/dist/bin -Xms40m -Xmx512m

(I only added the -Dorg.eclipse.swt.browser.XULRunnerPath line)

I'm using eclipse-reporting-juno-linux-gtk-x86_64 on ubuntu precise (12.04.1), and apart from the "Preview" tab it works fine at the moment.