mozilla-b2g/gaia — pull request #3162 by ochameau (2012-08-04 09:34:32+00:00)
Title: Share xpcshell code

A bunch of code was duplicated between each xpcshell build scripts.
Here is a patch to factorise this code.
I'm wondering if we should include:
```
// If BUILD_APP_NAME isn't `*`, we only accept one webapp
if (BUILD_APP_NAME != '*' && webappSrcDirName != BUILD_APP_NAME)
return;
```
In utils.js: Gaia.webapps.forEach?
Same question for external-apps folder?

In its current state BUILD_APP_NAME env variable and external-apps are only used in webapp manifest code, but not preferences nor permission code.
If you think it would be helpfull, I'd prefer doing this in a followup patch!