Sometimes an eyeOS developer may need to use a Qooxdoo contrib, or to update Qooxdoo, or to fix anything. For instance, contribs extend the library and let the hacker have more backend features, widgets, themes, etc. There is a manual that helps Qooxdoo applications developers, but in eyeOS things might turn a bit tricky.
The first part of this article explains the standard method. The second part, the patches that sometimes are required.
To include a contrib, you have to ‘compile’ Qooxdoo. That is, Qooxdoo needs to resolve dependencies and to be compressed.
When is this article useful?
- Contribs — you want to use a Qooxdoo contrib
- Core modifications — If you modified qx.* or aristo.Aristo or a dependency declared in the config file.
- Debugging — If your face turned green fixing a bug.
- Deployment — generate files to deploy eyeOS.
Getting the big picture
Edit eyeOS config file. This file differs a bit from Qooxdoo’s in order to include the Aristo theme and to adapt paths to libraries. Run the generate.py script.
Where ‘build’ is a job defined in config.json. In eyeOS you can use ‘debug’ as well, but it won”t work most times.
This file defines what to include, what to exclude, where to find the libraries… In eyeOS two jobs are declared: ‘build’ and ‘debug’. In the ‘build’ job you’ll find a line to declare your libraries. If you need to use a contrib, add it there.
"include": ["qx.*", "aristo.Aristo", "svg.*"]
Right beneath this line you’ll have to tell Qooxdoo where to find the code you’re including:
"manifest" : "/home/edu/svg/Manifest.json"
All contribs contain a Manifest.json. Just extract all the files of the contrib anywhere (e.g /home/edu/mycontrib). They’ll be copied and compressed to the source/ folder of your Qooxdoo application.
Adapt all other paths. You may need to download the Aristo theme and edit the path in this file so the “compiler” finds it, like you did for the contrib and the “manifest” field 30 seconds before.
If you’re using a Qooxdoo version older than 1.4.1 and GNU/Linux, you might see ‘global name ‘WindowsError’ is not defined’. There’s a very quick fix available explained in bug 5273.