14 lines
420 B
JavaScript
14 lines
420 B
JavaScript
try {
|
|
module.exports = require('./index.node');
|
|
} catch {
|
|
const isLinux = process.platform === 'linux';
|
|
|
|
if (isLinux && process.arch === 'x64') {
|
|
module.exports = require('./index-x86_64-unknown-linux-gnu.node');
|
|
} else if (isLinux && process.arch === 'arm64') {
|
|
module.exports = require('./index-aarch64-unknown-linux-gnu.node');
|
|
} else {
|
|
throw new Error('Bliss: unsupported architecture');
|
|
}
|
|
}
|