Bug 1020152 - Generate pre_installed_collections.json in build time.

I suggest using `directory.split('/')` and append them to `getFile()` to ensure it works on Windows, so it will look like:
```js
utils.getFile.apply(null, [config.GAIA_DIR, ...directory.split('\n'), appName])
```
`...` is new syntax for [ES6](http://ariya.ofilabs.com/2013/03/es6-and-spread-operator.html).