flocore-node/bin/get-tarball-name.js
Chris Kleeschulte 4894f1abec Enable Cross-Compiling support
1. To use this feature, set CC and CXX env variables to the appropriate cross compiler
2. Example, for cross compiling to ARM, use: CC=arm-linux-gnueabihf-gcc-4.9 CXX=arm-linux-gnueabihf-g++-4.9 npm install
3. You can still compile without setting CC and CXX, you can still just run npm install
2016-02-11 10:25:22 -05:00

20 lines
579 B
JavaScript

'use strict';
var execSync = require('child_process').execSync;
function getTarballName() {
var packageRoot = __dirname + '/..';
var version = require(packageRoot + '/package.json').version;
var platform = process.platform;
var arch = execSync(packageRoot + '/bin/variables.sh arch').toString();
var abi = process.versions.modules;
var tarballName = 'libbitcoind-' + version + '-node' + abi + '-' + platform + '-' + arch + '.tgz';
return tarballName;
}
if (require.main === module) {
process.stdout.write(getTarballName());
}
module.exports = getTarballName;