Open gregfutia opened 7 years ago
I think this error is caused by changes in V8: string going from node 0.10 to 0.12. Now the string type comes into the New declaration.
Here is a blog post describing this and some other issues.
The call on line 11 of common.cpp probably needs to change to ::NewFromOneByte()
I realized I was running a old node release on my Debian system and upgraded to V. 7.4.0. The error remains.
/var/lib/cloud9/Projects/VideoServer# npm install jpeg --save
jpeg@2.0.0 install /var/lib/cloud9/Projects/VideoServer/node_modules/jpeg node-gyp configure build
gyp WARN download NVM_NODEJS_ORG_MIRROR is deprecated and will be removed in node-gyp v4, please use NODEJS_ORG_MIRROR
gyp WARN download NVM_NODEJS_ORG_MIRROR is deprecated and will be removed in node-gyp v4, please use NODEJS_ORG_MIRROR
gyp WARN download NVM_NODEJS_ORG_MIRROR is deprecated and will be removed in node-gyp v4, please use NODEJS_ORG_MIRROR
make: Entering directory '/var/lib/cloud9/Projects/VideoServer/node_modules/jpeg/build'
CXX(target) Release/obj.target/jpeg/src/common.o
In file included from /root/.node-gyp/7.4.0/include/node/node.h:42:0,
from ../src/common.h:4,
from ../src/common.cpp:3:
/root/.node-gyp/7.4.0/include/node/v8.h: In function ‘v8::Handlemake
failed with exit code: 2
gyp ERR! stack at ChildProcess.onExit (/root/.nvm/versions/node/v7.4.0/lib/node_modules/npm/node_modules/node-gyp/lib/build.js:276:23)
gyp ERR! stack at emitTwo (events.js:106:13)
gyp ERR! stack at ChildProcess.emit (events.js:191:7)
gyp ERR! stack at Process.ChildProcess._handle.onexit (internal/child_process.js:215:12)
gyp ERR! System Linux 4.4.9-ti-r25
gyp ERR! command "/root/.nvm/versions/node/v7.4.0/bin/node" "/root/.nvm/versions/node/v7.4.0/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "configure" "build"
gyp ERR! cwd /var/lib/cloud9/Projects/VideoServer/node_modules/jpeg
gyp ERR! node -v v7.4.0
gyp ERR! node-gyp -v v3.4.0
gyp ERR! not ok
npm WARN videoserver@1.0.0 No repository field.
npm ERR! Linux 4.4.9-ti-r25
npm ERR! argv "/root/.nvm/versions/node/v7.4.0/bin/node" "/root/.nvm/versions/node/v7.4.0/bin/npm" "install" "jpeg" "--save"
npm ERR! node v7.4.0
npm ERR! npm v4.0.5
npm ERR! code ELIFECYCLE
npm ERR! jpeg@2.0.0 install: node-gyp configure build
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the jpeg@2.0.0 install script 'node-gyp configure build'.
npm ERR! Make sure you have the latest version of node.js and npm installed.
npm ERR! If you do, this is most likely a problem with the jpeg package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR! node-gyp configure build
npm ERR! You can get information on how to open an issue for this project with:
npm ERR! npm bugs jpeg
npm ERR! Or if that isn't available, you can get their info via:
npm ERR! npm owner ls jpeg
npm ERR! There is likely additional logging output above.
npm ERR! Please include the following file with any support request: npm ERR! /var/lib/cloud9/Projects/VideoServer/npm-debug.log
Install fails when building on a beagle bone black/ Debian ARM linux.
root@coolbone:/var/lib/cloud9/Projects/MPEGserver# npm install jpeg
make: Entering directory '/var/lib/cloud9/node_modules/jpeg/build' CXX(target) Release/obj.target/jpeg/src/common.o In file included from /root/.node-gyp/0.12.18/include/node/node.h:61:0, from ../src/common.h:4, from ../src/common.cpp:3: /root/.node-gyp/0.12.18/include/node/v8.h: In function ‘v8::Handle ErrorException(const char)’:
/root/.node-gyp/0.12.18/include/node/v8.h:816:13: error: ‘v8::HandleScope::HandleScope()’ is protected
V8_INLINE HandleScope() {}
^
../src/common.cpp:10:17: error: within this context
HandleScope scope;
^
../src/common.cpp:11:29: error: ‘New’ is not a member of ‘v8::String’
return Exception::Error(String::New(msg));
^
In file included from /root/.node-gyp/0.12.18/include/node/node.h:61:0,
from ../src/common.h:4,
from ../src/common.cpp:3:
/root/.node-gyp/0.12.18/include/node/v8.h: In function ‘v8::Handle VException(const char )’:
/root/.node-gyp/0.12.18/include/node/v8.h:816:13: error: ‘v8::HandleScope::HandleScope()’ is protected
V8_INLINE HandleScope() {}
^
../src/common.cpp:16:17: error: within this context
HandleScope scope;
^
../src/common.cpp:17:46: error: ‘ThrowException’ was not declared in this scope
return ThrowException(ErrorException(msg));
^
../src/common.cpp: In function ‘v8::Handle ErrorException(const char)’:
../src/common.cpp:12:1: warning: control reaches end of non-void function [-Wreturn-type]
}
^
../src/common.cpp: In function ‘v8::Handle VException(const char )’:
../src/common.cpp:18:1: warning: control reaches end of non-void function [-Wreturn-type]
}
^
jpeg.target.mk:90: recipe for target 'Release/obj.target/jpeg/src/common.o' failed
make: *** [Release/obj.target/jpeg/src/common.o] Error 1
make: Leaving directory '/var/lib/cloud9/node_modules/jpeg/build'
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:276:23) gyp ERR! stack at ChildProcess.emit (events.js:110:17) gyp ERR! stack at Process.ChildProcess._handle.onexit (child_process.js:1078:12) gyp ERR! System Linux 4.4.9-ti-r25 gyp ERR! command "node" "/usr/local/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "configure" "build" gyp ERR! cwd /var/lib/cloud9/node_modules/jpeg gyp ERR! node -v v0.12.18 gyp ERR! node-gyp -v v3.3.1 gyp ERR! not ok /var/lib/cloud9 ├── express@4.14.0 └── update@0.7.4npm WARN enoent ENOENT, open '/var/lib/cloud9/package.json' npm WARN cloud9 No description npm WARN cloud9 No repository field. npm WARN cloud9 No README data npm WARN cloud9 No license field. npm ERR! Linux 4.4.9-ti-r25 npm ERR! argv "node" "/usr/local/bin/npm" "install" "jpeg" npm ERR! node v0.12.18 npm ERR! npm v3.8.2 npm ERR! code ELIFECYCLE
npm ERR! jpeg@2.0.0 install:
node-gyp configure build
npm ERR! Exit status 1 npm ERR! npm ERR! Failed at the jpeg@2.0.0 install script 'node-gyp configure build'. npm ERR! Make sure you have the latest version of node.js and npm installed. npm ERR! If you do, this is most likely a problem with the jpeg package, npm ERR! not with npm itself. npm ERR! Tell the author that this fails on your system: npm ERR! node-gyp configure build npm ERR! You can get information on how to open an issue for this project with: npm ERR! npm bugs jpeg npm ERR! Or if that isn't available, you can get their info via: npm ERR! npm owner ls jpeg npm ERR! There is likely additional logging output above.npm ERR! Please include the following file with any support request: npm ERR! /var/lib/cloud9/Projects/MPEGserver/npm-debug.log