Gaia Build System


(Alastair Pharo) #1

Hi there,

I’ve spent some time looking through the Gaia build system code trying to understand bug 1263308, which prevents files from being installed to a profile when DEBUG=1 is specified. I gather from this that Gaia has a completely distinct JS+Python-based build system that can run on either NodeJS or Mozilla’s XPCShell runtime. It may be that I am just unfamiliar with the codebase, but the build system struck me as quite complicated.

I am guessing that dispensing with packaged webapps has probably made the requirements for the build system setup much simpler than previously. As such, what I would like to ask is whether those in the know about this system think about the direction that the community ought to take with this. Do people think that given the changed requirements and the limited volunteer resources available, that maintaining a separate build system for Gaia still makes sense? Could there be benefits to switching to something like Grunt, Gulp, etc. (or just Make perhaps), or are there things that the current build system accomplishes that those systems would not be able to support?

Also, as far as I can tell, this build system is not used by any other Mozilla project, and was not used by the Project Tablet team (at least, I cannot find any of the same files in the folder I link to there … maybe I’m wrong about that). Assuming I’m right about that, does anyone from Project Tablet have advice on what might be the best way forward with this? Could any work from that project be used to give Gaia a simpler build process?

Thanks in advance!


(Ben Francis) #2

Hi,

The main function of the Gaia build system was to build a collection of packaged apps and pre-populate the apps registry and prefs database into a Gecko profile to flash onto a device. Now that the app runtime and packaged apps are no more, I agree there’s a lot less need for the Gaia build system. I think we could probably get rid of it altogether like we tried with the tablet project.

As you say though, the build system is quite complicated so in order to replace it we need to figure out everything that it does! It has lots of other functions like localisation, automated testing and assembling the optimal resolution of image assets for a given device (among others I’m probably not aware of).

A good start might be to start to list everything it does, and find alternative solutions using web standard solutions where possible and otherwise taking an approach as close to Firefox as possible.

Ben