Closed Bug 959629 Opened 9 years ago Closed 9 years ago

Gaia integration need new NodeJS module


(Release Engineering :: General, defect, P1)



(Not tracked)



(Reporter: hub, Assigned: hub)



(Whiteboard: [c=automation p=2 s= u=])

Gaia integration need new NodeJS module: we need exec-sync that require a native compilation to install.

See 917717 comment 47

Blocks: 917717
I mean see bug 917717 comment 47
Why can't we add it to package.json ?
(In reply to Julien Wajsberg [:julienw] from comment #2)
> Why can't we add it to package.json ?

Here it the full log of the failure:

tl;dr if you need a native module compilation it won't install by itself on TBPL
Yeah, and locally I needed "npm install -d" with my npm 0.8.
The important module that need compilation is actually "ffi". "exec-sync" does not require native code.
Hi Hub,

A few points for cla

1. I think releng can give you access to ubuntu 32 and 64 bit machines that you may use to precompile the modules yourself (by doing something similar to, but my guess is that they won't build them for you?

2. Since npm tries to compile modules during |npm install| that have .gyp files, you'll need to do something like in the repo for the native module (which also probably involves forking and publishing a non-native version of the module in question). The purpose of this is to check for a compiler (ie g++) and then failover to copying existing binaries into the build output directory if a compiler isn't detected.

Does this make a bit more sense?
Flags: needinfo?(hub)
and how do I publish it so npm finds it?
Flags: needinfo?(hub)
Flags: needinfo?(gaye)
If you have exec-sync which depends on ffi, you could:

1. Fork ffi, change the name to something like ffi-non-native, modify it to use precompiled binaries if no g++, and publish it

2. Fork exec-sync and change the name to something like exec-sync-non-native, depend on ffi-non-native instead of ffi, and publish it

3. In the marionette perf package, depend on exec-sync-non-native instead of exec-sync

Does that make sense?
Flags: needinfo?(gaye)
Assignee: nobody → hub
Whiteboard: [c=automation p=2 s= u=]
Depends on: 960742
Solution is as follow:

I will fork ffi, rename it ffi-prebuilt

Then I will add the *generated* .js from exec-sync to our source tree (original is written in CoffeeScript anyway). MIT licensed and depend on that ffi-prebuilt.

Longer term, bug 959241 should make all that pain obsolete.
Use ffi-prebuilt. It is available on npm and will pull proper dependencies, prebuilt.
Closed: 9 years ago
Priority: -- → P1
Resolution: --- → FIXED
Component: General Automation → General
You need to log in before you can comment on or make changes to this bug.