Skip to content

Commit

Permalink
Skip prebuilt binaries for musl >=1.2.0 #2570
Browse files Browse the repository at this point in the history
  • Loading branch information
lovell committed Feb 20, 2021
1 parent 0c1075c commit 9f2f920
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
2 changes: 1 addition & 1 deletion docs/install.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ Ready-compiled sharp and libvips binaries are provided for use with
Node.js v10+ on the most common platforms:

* macOS x64 (>= 10.13)
* Linux x64 (glibc >= 2.17, musl >= 1.1.24)
* Linux x64 (glibc >= 2.17, musl >=1.1.24 <1.2.0)
* Linux ARM64 (glibc >= 2.29)
* Windows x64
* Windows x86
Expand Down
5 changes: 5 additions & 0 deletions install/libvips.js
Original file line number Diff line number Diff line change
Expand Up @@ -82,6 +82,11 @@ try {
throw new Error(`Use with glibc ${detectLibc.version} requires manual installation of libvips >= ${minimumLibvipsVersion}`);
}
}
if (detectLibc.family === detectLibc.MUSL && detectLibc.version) {
if (!semver.satisfies(detectLibc.version, '>=1.1.24 <1.2.0')) {
throw new Error(`Use with musl ${detectLibc.version} requires manual installation of libvips >= ${minimumLibvipsVersion}`);
}
}

const supportedNodeVersion = process.env.npm_package_engines_node || require('../package.json').engines.node;
if (!semver.satisfies(process.versions.node, supportedNodeVersion)) {
Expand Down

0 comments on commit 9f2f920

Please sign in to comment.