Skip to content
This repository has been archived by the owner on Mar 7, 2023. It is now read-only.

Move prebuild system to prebuildify and node-gyp-build #154

Open
mcous opened this issue Oct 20, 2021 · 3 comments
Open

Move prebuild system to prebuildify and node-gyp-build #154

mcous opened this issue Oct 20, 2021 · 3 comments
Labels
enhancement prebuild Issues related to missing and broken prebuilt binaries when installing (`prebuild` npm package)

Comments

@mcous
Copy link
Contributor

mcous commented Oct 20, 2021

The prebuild-install dependency now advocates against its own use:

Instead of prebuild paired with prebuild-install, we recommend prebuildify paired with node-gyp-build.

The benefits touted by prebuildify and node-gyp-build seem like useful upgrades to the build system that could meaningfully reduce the number of issues faced by Electron users of this library (e.g. #153). I'm not sure, but it looks like there's a chance it could also make it easier / possible to start shipping a universal macOS prebuilt binary to resolve #141.

With prebuildify, all prebuilt binaries are shipped inside the package that is published to npm, which means there's no need for a separate download step like you find in prebuild. The irony of this approach is that it is faster to download all prebuilt binaries for every platform when they are bundled than it is to download a single prebuilt binary as an install script.

(Aside: I'm about to go on several weeks of vacation, and I intend to look into this when I'm back. Until that time, though, if someone else picked this ticket up, I would not be disappointed!)

@MadLittleMods MadLittleMods added prebuild Issues related to missing and broken prebuilt binaries when installing (`prebuild` npm package) enhancement labels Oct 20, 2021
@MadLittleMods
Copy link
Owner

Thanks for the background and details here @mcous! The plan to migrate seems good to me 👍

Have a good vacation 🏖🏞

@thegecko
Copy link
Contributor

thegecko commented Nov 23, 2021

We recently ported node-usb to prebuildify using prebuildify-cross, it may serve as inspiration.

Coupled with a port to node-addon-api it should fix most platform issues and future proof the library.

Shout if you want some help

@Julusian
Copy link
Contributor

I would be concerned about how big a nan based package would end up being. It produces a rather long list of targets, which will only get worse if adding prebuildify-cross to the mix

I really need to finish up that node-api rewrite I started...

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
enhancement prebuild Issues related to missing and broken prebuilt binaries when installing (`prebuild` npm package)
Projects
None yet
Development

No branches or pull requests

4 participants