Sharp: error: REPLACE_INVALID_UTF8 is not a member of v8::String (was: Issue installing on CentOS 7)

Created on 28 Apr 2016  路  3Comments  路  Source: lovell/sharp

Hi,

Trying to install sharp on CentOS Linux release 7.1.1503 (Core)
The installation goes fine until the build phase (node-gyp).
The only thing before that are few warnings:

npm WARN engine [email protected]: wanted: {"node":">=0.10.40"} (current: {"node":"v0.10.36","npm":"1.3.6"})
npm WARN engine [email protected]: wanted: {"node":">=0.10.40"} (current: {"node":"v0.10.36","npm":"1.3.6"})
npm WARN engine [email protected]: wanted: {"node":">=0.10.40"} (current: {"node":"v0.10.36","npm":"1.3.6"})

Next, I see error

make: Entering directory /home/centos/node_modules/sharp/build' TOUCH Release/obj.target/libvips-cpp.stamp CXX(target) Release/obj.target/sharp/src/common.o CXX(target) Release/obj.target/sharp/src/metadata.o In file included from ../src/metadata.cc:4:0: ../node_modules/nan/nan.h:330:47: error: 芒REPLACE_INVALID_UTF8芒 is not a member of 芒v8::String芒 static const unsigned kReplaceInvalidUtf8 = v8::String::REPLACE_INVALID_UTF8; ^ make: *** [Release/obj.target/sharp/src/metadata.o] Error 1 make: Leaving directory/home/centos/node_modules/sharp/build'
gyp ERR! build error
gyp ERR! stack Error: make failed with exit code: 2
gyp ERR! stack at ChildProcess.onExit (/usr/lib/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 Linux 3.10.0-229.4.2.el7.x86_64
gyp ERR! command "node" "/usr/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
gyp ERR! cwd /home/centos/node_modules/sharp
gyp ERR! node -v v0.10.36
gyp ERR! node-gyp -v v0.10.6
gyp ERR! not ok
npm ERR! weird error 1
npm ERR! not ok code 0

Any pointer/suggestions?

Thanks!

Tomer

question

All 3 comments

Hello, did you see the possibly related https://github.com/nodejs/nan/issues/414 ?

I will review. I did a search for the error here but couldn't find it... not sure what nan is but will take a look. Thanks for the prompt reply!

OK. Updating npm did the trick... Thanks again

Was this page helpful?
0 / 5 - 0 ratings

Related issues

OleVik picture OleVik  路  3Comments

sansroman picture sansroman  路  3Comments

iq-dot picture iq-dot  路  3Comments

henbenla picture henbenla  路  3Comments

natural-law picture natural-law  路  3Comments