Ce billet existe aussi en français

This is the first post of a series about how to package a XULRunner application.

1 - Preamble

Purpose: you have made a nice XULRunner application, that you want to distribute as friendly for all platforms supported by XULRunner.

This is a small piece of code, you don't want to distribute XULRunner itself with your application (*).

I will share with you the result of some of my experiments and web researches, to package it and resolve some platform specificities.

We will see how to create a launcher, sometime based on Firefox with the -app argument (which can be used as a XULRunner runtime), and how to create common installers, deb and rpm for Linux, a nsis installer for Windows, an application bundle and a dmg for Mac OSX.

We will use the 'Hello World' application as example, from developer.mozilla.org. And all of this will be performed from Linux.

All comments and feedback will be really welcome ;) , if something seems wrong to you, please comment.

(*) Note: but if you embed XULRunner into your application, this information should be still useful ;) .

Here's the complete incoming plan:

Distribute your XULRunner app

  • 1 Preamble
  • 2 Linux
    • 2.1 Linux common
      • 2.1.1 Generalities
      • 2.1.2 Create a launcher
      • 2.1.3 Icons for our windows
      • 2.1.4 Desktop integration
      • 2.1.5 Distribute a tar.gz
    • 2.2 Package as deb
      • 2.2.1 Synopsis
      • 2.2.2 Debian files
      • 2.2.3 Create the deb
    • 2.3 Special case : deb for Maemo
      • 2.3.1 Maemo generalities
      • 2.3.2 Adapt the launcher
      • 2.3.3 A new file system organization - Where place our app
      • 2.3.4 Additions to the .desktop file
      • 2.3.5 Changes to the Debian files
      • 2.3.6 Create the deb
    • 2.4 Package as rpm
      • 2.4.1 Prerequisites
      • 2.4.2 RPM files
      • 2.4.3 Create the rpm
  • 3 Windows
    • 3.1 Icons for Windows
    • 3.2 Create a launcher (batch or C)
    • 3.3 Create a NSIS script
    • 3.4 Create the installer
  • 4 Mac OSX
    • 4.1 Icons for Mac OSX
    • 4.2 Create a launcher
    • 4.3 Some Mac specificities
    • 4.4 Create a Application Bundle
    • 4.5 Package as tar.gz and dmg
  • 5 Synthesis - all platforms
    • 5.1 Changes to the app
    • 5.2 Added data
    • 5.3 Created installers
    • 5.4 A global and reusable script
    • 5.5 Conclusions
  • 6 Annexe - related links

Nicolas Martin