ktrongnhan / xxhash-addon

Yet another xxhash addon for Node.js which can be x50 times faster than crypto MD5
Other
81 stars 9 forks source link

Can't install xxhash-addon module #17

Closed kevalrathod closed 2 years ago

kevalrathod commented 3 years ago

Node Version: v14.16.1

I tried to install module but it gives me : fatal error: too many errors emitted, stopping now [-ferror-limit=]

xxhash-addon@1.4.0 install /Users/turinganalytics/Development/transform/node_modules/xxhash-addon node-gyp rebuild --ensure

CXX(target) Release/obj.target/addon/src/addon.o In file included from ../src/addon.cc:1: In file included from ../src/xxhash32.h:4: In file included from /Users/turinganalytics/Library/Caches/node-gyp/14.16.1/include/node/node_api.h:12: In file included from /Users/turinganalytics/Library/Caches/node-gyp/14.16.1/include/node/js_native_api.h:24: /Users/turinganalytics/Library/Caches/node-gyp/14.16.1/include/node/js_native_api_types.h:128:3: error: unknown type name 'uint32_t' uint32_t engine_error_code; ^ In file included from ../src/addon.cc:1: In file included from ../src/xxhash32.h:4: In file included from /Users/turinganalytics/Library/Caches/node-gyp/14.16.1/include/node/node_api.h:12: /Users/turinganalytics/Library/Caches/node-gyp/14.16.1/include/node/js_native_api.h:73:43: error: unknown type name 'int32_t' int32_t value, ^ /Users/turinganalytics/Library/Caches/node-gyp/14.16.1/include/node/js_native_api.h:76:44: error: unknown type name 'uint32_t' uint32_t value, ^ /Users/turinganalytics/Library/Caches/node-gyp/14.16.1/include/node/js_native_api.h:79:43: error: unknown type name 'int64_t' int64_t value, ^ /Users/turinganalytics/Library/Caches/node-gyp/14.16.1/include/node/js_native_api.h:124:46: error: unknown type name 'int32_t' int32_t result); ^ /Users/turinganalytics/Library/Caches/node-gyp/14.16.1/include/node/js_native_api.h:127:47: error: unknown type name 'uint32_t' uint32_t result); ^ /Users/turinganalytics/Library/Caches/node-gyp/14.16.1/include/node/js_native_api.h:130:46: error: unknown type name 'int64_t' int64_t result); ^ /Users/turinganalytics/Library/Caches/node-gyp/14.16.1/include/node/js_native_api.h:212:42: error: unknown type name 'uint32_t' uint32_t index, ^ /Users/turinganalytics/Library/Caches/node-gyp/14.16.1/include/node/js_native_api.h:216:42: error: unknown type name 'uint32_t' uint32_t index, ^ /Users/turinganalytics/Library/Caches/node-gyp/14.16.1/include/node/js_native_api.h:220:42: error: unknown type name 'uint32_t' uint32_t index, ^ /Users/turinganalytics/Library/Caches/node-gyp/14.16.1/include/node/js_native_api.h:224:45: error: unknown type name 'uint32_t' uint32_t index, ^ /Users/turinganalytics/Library/Caches/node-gyp/14.16.1/include/node/js_native_api.h:238:47: error: unknown type name 'uint32_t' uint32_t result); ^ /Users/turinganalytics/Library/Caches/node-gyp/14.16.1/include/node/js_native_api.h:315:47: error: unknown type name 'uint32_t' uint32_t initial_refcount, ^ /Users/turinganalytics/Library/Caches/node-gyp/14.16.1/include/node/js_native_api.h:329:44: error: unknown type name 'uint32_t' uint32_t result); ^ /Users/turinganalytics/Library/Caches/node-gyp/14.16.1/include/node/js_native_api.h:337:46: error: unknown type name 'uint32_t' uint32_t result); ^ /Users/turinganalytics/Library/Caches/node-gyp/14.16.1/include/node/js_native_api.h:434:56: error: unknown type name 'uint32_t' NAPI_EXTERN napi_status napi_get_version(napi_env env, uint32_t result); ^ /Users/turinganalytics/Library/Caches/node-gyp/14.16.1/include/node/js_native_api.h:457:53: error: unknown type name 'int64_t' int64_t change_in_bytes, ^ /Users/turinganalytics/Library/Caches/node-gyp/14.16.1/include/node/js_native_api.h:458:53: error: unknown type name 'int64_t' int64_t adjusted_value); ^ /Users/turinganalytics/Library/Caches/node-gyp/14.16.1/include/node/js_native_api.h:489:50: error: unknown type name 'int64_t' int64_t value, ^ fatal error: too many errors emitted, stopping now [-ferror-limit=] 20 errors generated. make: *** [Release/obj.target/addon/src/addon.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/Cellar/node@14/14.16.1_1/lib/node_modules/npm/node_modules/node-gyp/lib/build.js:194:23) gyp ERR! stack at ChildProcess.emit (events.js:315:20) gyp ERR! stack at Process.ChildProcess._handle.onexit (internal/child_process.js:277:12) gyp ERR! System Darwin 20.3.0 gyp ERR! command "/usr/local/Cellar/node@14/14.16.1_1/bin/node" "/usr/local/Cellar/node@14/14.16.1_1/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild" "--ensure" gyp ERR! cwd /Users/turinganalytics/Development/transform/node_modules/xxhash-addon gyp ERR! node -v v14.16.1 gyp ERR! node-gyp -v v5.1.0 gyp ERR! not ok npm ERR! code ELIFECYCLE npm ERR! errno 1 npm ERR! xxhash-addon@1.4.0 install: node-gyp rebuild --ensure npm ERR! Exit status 1 npm ERR! npm ERR! Failed at the xxhash-addon@1.4.0 install script. npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in: npm ERR! /Users/turinganalytics/.npm/_logs/2021-05-05T13_32_33_490Z-debug.log

ktrongnhan commented 2 years ago

Hi @kevalrathod , Looks like you are on a Mac. Have you tried installing Xcode command line tools? Check README.md for more info.

ktrongnhan commented 2 years ago

@kevalrathod I'm closing this ticket. If you still see the errors after installing Xcode command line tools then feel free to reopen. I will try to investigate then.