Closed Bug 905096 Opened 11 years ago Closed 11 years ago

Build script modularization

Categories

(Firefox OS Graveyard :: Gaia, defect)

x86_64
Linux
defect
Not set
normal

Tracking

(Not tracked)

RESOLVED FIXED

People

(Reporter: yurenju, Assigned: yurenju)

References

Details

Attachments

(1 file, 3 obsolete files)

for now we use xpcshell to execute javascript in GAIA_DIR/build/, we should use module pattern for those scripts to help developer can reuse those scripts to customize build process.

I would like to use commonjs pattern to encapsulate each script in GAIA_DIR into a module. to do that, I need to use commonjs/toolkit/loader.js to define require to solve dependency issue.
Attached patch wip.patch (obsolete) — Splinter Review
today WIP, now we can use sdk/io/fs! :D
Hi Alex, Could you give some feedback for xpcshell-commonjs.js in attachment 790732 [details] [diff] [review]? it works but it would be great if you can take a look to it :)

you also can read it on github: https://github.com/yurenju/gaia/blob/82a9e37c556d9be5da1af27f9ecbfe6bb0869c1b/build/xpcshell-commonjs.js
Flags: needinfo?(poirot.alex)
Attached patch wip2.patch (obsolete) — Splinter Review
now we can |make reset-gaia| with xpcshell modules! wooooow!

I'm working on cleaning code and test build/*.js one by one to check everything is okay.
Attachment #790732 - Attachment is obsolete: true
Attached patch wip2.patch (obsolete) — Splinter Review
I forgot adding files when commit, update to new patch.
Attachment #792695 - Attachment is obsolete: true
This pull request is ready to review,I tested each script on xpcshell and everthing looks good. Since changes of build system is easy to get failed on TBPL, I would like to get two r+ to land it.

Tim and Alex, could you review this PR? thanks!
Attachment #792723 - Attachment is obsolete: true
Attachment #793928 - Flags: review?(timdream)
Attachment #793928 - Flags: review?(poirot.alex)
Flags: needinfo?(poirot.alex)
Comment on attachment 793928 [details] [review]
github PR: https://github.com/mozilla-b2g/gaia/pull/11693

Splendid! You should feedback? :lightsofapollo too IMHO.
Attachment #793928 - Flags: review?(timdream) → review+
Comment on attachment 793928 [details] [review]
github PR: https://github.com/mozilla-b2g/gaia/pull/11693

James, could you give some feedback for this? thanks!
Attachment #793928 - Flags: feedback?(jlal)
Comment on attachment 793928 [details] [review]
github PR: https://github.com/mozilla-b2g/gaia/pull/11693

Looks good! I did some basic sanity testing too and everything in my daily workflow works well.
Attachment #793928 - Flags: feedback?(jlal) → feedback+
Comment on attachment 793928 [details] [review]
github PR: https://github.com/mozilla-b2g/gaia/pull/11693

since Alex looks very busy, I'll land this commit first only with r=timdream after verified this commit on windows.
Attachment #793928 - Flags: review?(poirot.alex)
pull request was updated for Windows.
merged. 
https://github.com/mozilla-b2g/gaia/commit/4abecf9578f5a6f58ea1c69c19b53a8f45bc650a
Status: NEW → RESOLVED
Closed: 11 years ago
Resolution: --- → FIXED
Depends on: 910694
Attachment mime type: text/plain → text/x-github-pull-request
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: