Some checks failed
CI / go (push) Waiting to run
CI / docker (push) Waiting to run
CI / lint-go (push) Waiting to run
CI / lint-docs (push) Waiting to run
CI / check-paperclip (push) Waiting to run
Deploy static site / Deploy to GitHub Pages (push) Has been cancelled
Deploy static site / Deploy via Docker to hatch.surf (push) Has been cancelled
Resolved conflicts by taking GitHub versions for: - .dockerignore, .gitignore, Dockerfile, README.md, docker-compose.yml Kept deploy.sh updated to: - Pull from GitHub (primary source) - Push to Gitea (push-mirror) - Build from site/ directory (GitHub structure) Co-Authored-By: Paperclip <noreply@paperclip.ing>
39 lines
882 B
JavaScript
39 lines
882 B
JavaScript
/*!
|
|
Copyright 2013 Lovell Fuller and others.
|
|
SPDX-License-Identifier: Apache-2.0
|
|
*/
|
|
|
|
const {
|
|
useGlobalLibvips,
|
|
globalLibvipsVersion,
|
|
log,
|
|
spawnRebuild,
|
|
} = require('../lib/libvips');
|
|
|
|
log('Attempting to build from source via node-gyp');
|
|
log('See https://sharp.pixelplumbing.com/install#building-from-source');
|
|
|
|
try {
|
|
const addonApi = require('node-addon-api');
|
|
log(`Found node-addon-api ${addonApi.version || ''}`);
|
|
} catch (_err) {
|
|
log('Please add node-addon-api to your dependencies');
|
|
process.exit(1);
|
|
}
|
|
try {
|
|
const gyp = require('node-gyp');
|
|
log(`Found node-gyp ${gyp().version}`);
|
|
} catch (_err) {
|
|
log('Please add node-gyp to your dependencies');
|
|
process.exit(1);
|
|
}
|
|
|
|
if (useGlobalLibvips(log)) {
|
|
log(`Detected globally-installed libvips v${globalLibvipsVersion()}`);
|
|
}
|
|
|
|
const status = spawnRebuild();
|
|
if (status !== 0) {
|
|
process.exit(status);
|
|
}
|