Skip to content

Commit

Permalink
Run the node-pre-gyp fix for the rebuilt native node-inspector modules
Browse files Browse the repository at this point in the history
  • Loading branch information
enlight committed Sep 15, 2016
1 parent 85d31b0 commit 54efea5
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions src/rebuild.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,10 +16,15 @@ export async function rebuild(
let modulesDir = path.join(__dirname, '../node_modules');
console.log(`Rebuilding native node-inspector modules for Electron ${version}`);
await installNodeHeaders(version, null, null, arch);
console.log(`Rebuilding in ${modulesDir}`);
console.log(`Rebuilding ${modulesDir}/v8-profiler`);
await rebuildNativeModules(version, modulesDir, 'v8-profiler', null, arch);
// `node-inspector` will be launched in a "run as node" Electron process,
// so `node-pre-gyp` will be looking for a `node-vXX-platform-arch` directory
await preGypFixRun(path.join(modulesDir, 'v8-profiler'), true, executablePath);
console.log(`Rebuilding ${modulesDir}/v8-debug`);
await rebuildNativeModules(version, modulesDir, 'v8-debug', null, arch);
console.log(`Rebuild complete`);
await preGypFixRun(path.join(modulesDir, 'v8-debug'), true, executablePath);
console.log(`Done.`);
}

// Export the type of the function so that it can be referenced without actually requiring this
Expand Down

0 comments on commit 54efea5

Please sign in to comment.