Reputation: 903
I am trying to install aerospike npm module v 1.0.21 using npm install [email protected]
however I get a semi-cryptic error message. I have tried installing multiple versions of the Aerospike C Library, and multiple versions of node (ranging from 0.10.22 to 0.10.38 to latest) with no luck. This is on os x 10.9. Every thread suggested installing lua or using different versions of the Aaerospike C Library.
isaacs-computer:Desktop isaac$ npm install [email protected]
/
> [email protected] install /Users/isaac/Desktop/node_modules/aerospike
> node-gyp rebuild
ACTION binding_gyp_aerospike_client_c_target_run_scripts_aerospike_client_c_sh aerospike-client-c/lib/libaerospike.a
info: downloading 'http://www.aerospike.com/download/client/c/latest/artifact/mac' to '/Users/isaac/Desktop/node_modules/aerospike/aerospike-client-c/package/aerospike-client-c.tgz'
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 344 100 344 0 0 548 0 --:--:-- --:--:-- --:--:-- 548
0 0 0 0 0 0 0 0 --:--:-- --:--:-- --:--:-- 0
100 346 100 346 0 0 420 0 --:--:-- --:--:-- --:--:-- 420
0 0 0 0 0 0 0 0 --:--:-- --:--:-- --:--:-- 0
100 16.7M 100 16.7M 0 0 1900k 0 0:00:09 0:00:09 --:--:-- 3144k
info: extracting 'aerospike-client-c-3.1.18.mac.x86_64/aerospike-client-c-devel-3.1.18.pkg' from 'aerospike-client-c.tgz'
info: extracting files from 'aerospike-client-c-3.1.18.mac.x86_64/aerospike-client-c-devel-3.1.18.pkg'
8173 blocks
CHECK
[✓] /Users/isaac/Desktop/node_modules/aerospike/aerospike-client-c/package/usr/local/lib/libaerospike.a
[✓] /Users/isaac/Desktop/node_modules/aerospike/aerospike-client-c/package/usr/local/include/aerospike/aerospike.h
[✓] /Users/isaac/Desktop/node_modules/aerospike/aerospike-client-c/package/usr/local/aerospike/client/sys/udf/lua/aerospike.lua
TOUCH Release/obj.target/aerospike-client-c.stamp
CXX(target) Release/obj.target/aerospike/src/main/aerospike.o
CXX(target) Release/obj.target/aerospike/src/main/client.o
In file included from ../src/main/client.cc:27:
In file included from ../src/main/util/conversions.h:30:
../aerospike-client-c/include/aerospike/aerospike_batch.h:193:9: error: cannot
initialize return object of type 'as_batch_read_record *' (aka
'as_batch_read_record_s *') with an rvalue of type 'void *'
return as_vector_reserve(&records->list);
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
1 error generated.
make: *** [Release/obj.target/aerospike/src/main/client.o] Error 1
gyp ERR! build error
gyp ERR! stack Error: `make` failed with exit code: 2
gyp ERR! stack at ChildProcess.onExit (/usr/local/lib/node_modules/npm/node_modules/node-gyp/lib/build.js:267:23)
gyp ERR! stack at ChildProcess.emit (events.js:98:17)
gyp ERR! stack at Process.ChildProcess._handle.onexit (child_process.js:820:12)
gyp ERR! System Darwin 13.4.0
gyp ERR! command "node" "/usr/local/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
gyp ERR! cwd /Users/isaac/Desktop/node_modules/aerospike
gyp ERR! node -v v0.10.38
gyp ERR! node-gyp -v v1.0.1
gyp ERR! not ok
npm ERR! [email protected] install: `node-gyp rebuild`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the [email protected] install script.
npm ERR! This is most likely a problem with the aerospike package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR! node-gyp rebuild
npm ERR! You can get their info via:
npm ERR! npm owner ls aerospike
npm ERR! There is likely additional logging output above.
npm ERR! System Darwin 13.4.0
npm ERR! command "/usr/local/bin/node" "/usr/local/bin/npm" "install" "[email protected]"
npm ERR! cwd /Users/isaac/Desktop
npm ERR! node -v v0.10.38
npm ERR! npm -v 1.4.28
npm ERR! code ELIFECYCLE
npm ERR! not ok code 0
Upvotes: 0
Views: 1155
Reputation: 707
If you can't get npm working you can always clone the repository from git.
Upvotes: 1
Reputation: 903
Filed a bug report with Aerospike, fixed in [email protected]. Convinced my company to update to 1.0.27
Upvotes: 1
Reputation: 121
You can circumvent this problem by installing the C client in your machine and using the locally installed version to install aerospike nodejs Client version 1.0.21. Here are the steps.
npm install [email protected]
This should solve the version dependency failure between C client and nodejs Client.
Upvotes: 1