Giter Site home page Giter Site logo

../src/rocketmq.cpp:42:116: error: too few arguments to function call, single argument 'context' was not specified about rocketmq-client-nodejs HOT 10 OPEN

apache avatar apache commented on September 27, 2024
../src/rocketmq.cpp:42:116: error: too few arguments to function call, single argument 'context' was not specified

from rocketmq-client-nodejs.

Comments (10)

Miazzy avatar Miazzy commented on September 27, 2024
npm ERR! code 1
npm ERR! path /Users/yunwisdom/Workspace/xdata/xdata-search-service/node_modules/apache-rocketmq
npm ERR! command failed
npm ERR! command sh -c node ./script/download_lib.js && node-gyp rebuild
npm ERR! [rocketmq sdk] [info] downloading [https://opensource-rocketmq-client.oss-cn-hangzhou.aliyuncs.com/cpp-client/mac/1.2.0/librocketmq.dylib]...
npm ERR! [rocketmq sdk] [info] downloaded library [https://opensource-rocketmq-client.oss-cn-hangzhou.aliyuncs.com/cpp-client/mac/1.2.0/librocketmq.dylib].
npm ERR! [rocketmq sdk] [info] all libraries have been written to disk.
npm ERR!   CXX(target) Release/obj.target/rocketmq/src/rocketmq.o
npm ERR! gyp info it worked if it ends with ok
npm ERR! gyp info using node-gyp@7.1.2
npm ERR! gyp info using node@14.15.4 | darwin | x64
npm ERR! gyp info find Python using Python version 3.9.2 found at "/opt/homebrew/opt/[email protected]/bin/python3.9"
npm ERR! gyp info spawn /opt/homebrew/opt/python@3.9/bin/python3.9
npm ERR! gyp info spawn args [
npm ERR! gyp info spawn args   '/usr/local/lib/node_modules/npm/node_modules/node-gyp/gyp/gyp_main.py',
npm ERR! gyp info spawn args   'binding.gyp',
npm ERR! gyp info spawn args   '-f',
npm ERR! gyp info spawn args   'make',
npm ERR! gyp info spawn args   '-I',
npm ERR! gyp info spawn args   '/Users/yunwisdom/Workspace/xdata/xdata-search-service/node_modules/apache-rocketmq/build/config.gypi',
npm ERR! gyp info spawn args   '-I',
npm ERR! gyp info spawn args   '/usr/local/lib/node_modules/npm/node_modules/node-gyp/addon.gypi',
npm ERR! gyp info spawn args   '-I',
npm ERR! gyp info spawn args   '/Users/yunwisdom/Library/Caches/node-gyp/14.15.4/include/node/common.gypi',
npm ERR! gyp info spawn args   '-Dlibrary=shared_library',
npm ERR! gyp info spawn args   '-Dvisibility=default',
npm ERR! gyp info spawn args   '-Dnode_root_dir=/Users/yunwisdom/Library/Caches/node-gyp/14.15.4',
npm ERR! gyp info spawn args   '-Dnode_gyp_dir=/usr/local/lib/node_modules/npm/node_modules/node-gyp',
npm ERR! gyp info spawn args   '-Dnode_lib_file=/Users/yunwisdom/Library/Caches/node-gyp/14.15.4/<(target_arch)/node.lib',
npm ERR! gyp info spawn args   '-Dmodule_root_dir=/Users/yunwisdom/Workspace/xdata/xdata-search-service/node_modules/apache-rocketmq',
npm ERR! gyp info spawn args   '-Dnode_engine=v8',
npm ERR! gyp info spawn args   '--depth=.',
npm ERR! gyp info spawn args   '--no-parallel',
npm ERR! gyp info spawn args   '--generator-output',
npm ERR! gyp info spawn args   'build',
npm ERR! gyp info spawn args   '-Goutput_dir=.'
npm ERR! gyp info spawn args ]
npm ERR! gyp info spawn make
npm ERR! gyp info spawn args [ 'BUILDTYPE=Release', '-C', 'build' ]
npm ERR! ../src/rocketmq.cpp:42:116: error: too few arguments to function call, single argument 'context' was not specified
npm ERR!     Nan::Set(target, Nan::New("macosDLOpen").ToLocalChecked(), Nan::New<v8::FunctionTemplate>(DLOpen)->GetFunction());
npm ERR!                                                                ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ^
npm ERR! /Users/yunwisdom/Library/Caches/node-gyp/14.15.4/include/node/v8.h:6482:3: note: 'GetFunction' declared here
npm ERR!   V8_WARN_UNUSED_RESULT MaybeLocal<Function> GetFunction(
npm ERR!   ^
npm ERR! /Users/yunwisdom/Library/Caches/node-gyp/14.15.4/include/node/v8config.h:431:31: note: expanded from macro 'V8_WARN_UNUSED_RESULT'
npm ERR! #define V8_WARN_UNUSED_RESULT __attribute__((warn_unused_result))
npm ERR!                               ^
npm ERR! 1 error generated.
npm ERR! make: *** [Release/obj.target/rocketmq/src/rocketmq.o] Error 1
npm ERR! gyp ERR! build error 
npm ERR! gyp ERR! stack Error: `make` failed with exit code: 2
npm ERR! gyp ERR! stack     at ChildProcess.onExit (/usr/local/lib/node_modules/npm/node_modules/node-gyp/lib/build.js:194:23)
npm ERR! gyp ERR! stack     at ChildProcess.emit (events.js:315:20)
npm ERR! gyp ERR! stack     at Process.ChildProcess._handle.onexit (internal/child_process.js:277:12)
npm ERR! gyp ERR! System Darwin 20.1.0
npm ERR! gyp ERR! command "/usr/local/bin/node" "/usr/local/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
npm ERR! gyp ERR! cwd /Users/yunwisdom/Workspace/xdata/xdata-search-service/node_modules/apache-rocketmq
npm ERR! gyp ERR! node -v v14.15.4
npm ERR! gyp ERR! node-gyp -v v7.1.2
npm ERR! gyp ERR! not ok

npm ERR! A complete log of this run can be found in:
npm ERR!     /Users/yunwisdom/.npm/_logs/2021-03-24T11_48_57_940Z-debug.log
yunwisdom@yunwisdom xdata-search-service % npm install --save apache-rocketmq
npm ERR! code 1
npm ERR! path /Users/yunwisdom/Workspace/xdata/xdata-search-service/node_modules/apache-rocketmq
npm ERR! command failed
npm ERR! command sh -c node ./script/download_lib.js && node-gyp rebuild
npm ERR! [rocketmq sdk] [info] downloading [https://opensource-rocketmq-client.oss-cn-hangzhou.aliyuncs.com/cpp-client/mac/1.2.0/librocketmq.dylib]...
npm ERR! [rocketmq sdk] [info] downloaded library [https://opensource-rocketmq-client.oss-cn-hangzhou.aliyuncs.com/cpp-client/mac/1.2.0/librocketmq.dylib].
npm ERR! [rocketmq sdk] [info] all libraries have been written to disk.
npm ERR!   CXX(target) Release/obj.target/rocketmq/src/rocketmq.o
npm ERR! gyp info it worked if it ends with ok
npm ERR! gyp info using node-gyp@7.1.2
npm ERR! gyp info using node@14.15.4 | darwin | x64
npm ERR! gyp info find Python using Python version 3.9.2 found at "/opt/homebrew/opt/[email protected]/bin/python3.9"
npm ERR! gyp info spawn /opt/homebrew/opt/python@3.9/bin/python3.9
npm ERR! gyp info spawn args [
npm ERR! gyp info spawn args   '/usr/local/lib/node_modules/npm/node_modules/node-gyp/gyp/gyp_main.py',
npm ERR! gyp info spawn args   'binding.gyp',
npm ERR! gyp info spawn args   '-f',
npm ERR! gyp info spawn args   'make',
npm ERR! gyp info spawn args   '-I',
npm ERR! gyp info spawn args   '/Users/yunwisdom/Workspace/xdata/xdata-search-service/node_modules/apache-rocketmq/build/config.gypi',
npm ERR! gyp info spawn args   '-I',
npm ERR! gyp info spawn args   '/usr/local/lib/node_modules/npm/node_modules/node-gyp/addon.gypi',
npm ERR! gyp info spawn args   '-I',
npm ERR! gyp info spawn args   '/Users/yunwisdom/Library/Caches/node-gyp/14.15.4/include/node/common.gypi',
npm ERR! gyp info spawn args   '-Dlibrary=shared_library',
npm ERR! gyp info spawn args   '-Dvisibility=default',
npm ERR! gyp info spawn args   '-Dnode_root_dir=/Users/yunwisdom/Library/Caches/node-gyp/14.15.4',
npm ERR! gyp info spawn args   '-Dnode_gyp_dir=/usr/local/lib/node_modules/npm/node_modules/node-gyp',
npm ERR! gyp info spawn args   '-Dnode_lib_file=/Users/yunwisdom/Library/Caches/node-gyp/14.15.4/<(target_arch)/node.lib',
npm ERR! gyp info spawn args   '-Dmodule_root_dir=/Users/yunwisdom/Workspace/xdata/xdata-search-service/node_modules/apache-rocketmq',
npm ERR! gyp info spawn args   '-Dnode_engine=v8',
npm ERR! gyp info spawn args   '--depth=.',
npm ERR! gyp info spawn args   '--no-parallel',
npm ERR! gyp info spawn args   '--generator-output',
npm ERR! gyp info spawn args   'build',
npm ERR! gyp info spawn args   '-Goutput_dir=.'
npm ERR! gyp info spawn args ]
npm ERR! gyp info spawn make
npm ERR! gyp info spawn args [ 'BUILDTYPE=Release', '-C', 'build' ]
npm ERR! ../src/rocketmq.cpp:42:116: error: too few arguments to function call, single argument 'context' was not specified
npm ERR!     Nan::Set(target, Nan::New("macosDLOpen").ToLocalChecked(), Nan::New<v8::FunctionTemplate>(DLOpen)->GetFunction());
npm ERR!                                                                ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ^
npm ERR! /Users/yunwisdom/Library/Caches/node-gyp/14.15.4/include/node/v8.h:6482:3: note: 'GetFunction' declared here
npm ERR!   V8_WARN_UNUSED_RESULT MaybeLocal<Function> GetFunction(
npm ERR!   ^
npm ERR! /Users/yunwisdom/Library/Caches/node-gyp/14.15.4/include/node/v8config.h:431:31: note: expanded from macro 'V8_WARN_UNUSED_RESULT'
npm ERR! #define V8_WARN_UNUSED_RESULT __attribute__((warn_unused_result))
npm ERR!                               ^
npm ERR! 1 error generated.
npm ERR! make: *** [Release/obj.target/rocketmq/src/rocketmq.o] Error 1
npm ERR! gyp ERR! build error 
npm ERR! gyp ERR! stack Error: `make` failed with exit code: 2
npm ERR! gyp ERR! stack     at ChildProcess.onExit (/usr/local/lib/node_modules/npm/node_modules/node-gyp/lib/build.js:194:23)
npm ERR! gyp ERR! stack     at ChildProcess.emit (events.js:315:20)
npm ERR! gyp ERR! stack     at Process.ChildProcess._handle.onexit (internal/child_process.js:277:12)
npm ERR! gyp ERR! System Darwin 20.1.0
npm ERR! gyp ERR! command "/usr/local/bin/node" "/usr/local/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
npm ERR! gyp ERR! cwd /Users/yunwisdom/Workspace/xdata/xdata-search-service/node_modules/apache-rocketmq
npm ERR! gyp ERR! node -v v14.15.4
npm ERR! gyp ERR! node-gyp -v v7.1.2
npm ERR! gyp ERR! not ok

npm ERR! A complete log of this run can be found in:
npm ERR!     /Users/yunwisdom/.npm/_logs/2021-03-24T11_50_07_471Z-debug.log

from rocketmq-client-nodejs.

Miazzy avatar Miazzy commented on September 27, 2024

How Can I Fix this err?

from rocketmq-client-nodejs.

ifplusor avatar ifplusor commented on September 27, 2024

@Miazzy I make a n-api version in n-api branch, you can test it.

from rocketmq-client-nodejs.

danger49 avatar danger49 commented on September 27, 2024

@ifplusor 这个分支也不行啊

from rocketmq-client-nodejs.

ifplusor avatar ifplusor commented on September 27, 2024

@danger49 报什么错?

from rocketmq-client-nodejs.

levonchen avatar levonchen commented on September 27, 2024

@lfplusor The n-api branch can't work on windows 8 also.

from rocketmq-client-nodejs.

ifplusor avatar ifplusor commented on September 27, 2024

@lfplusor The n-api branch can't work on windows 8 also.

Yes, but I am not working on windows to make rocketmq-client-cpp@re_dev work on windows.

from rocketmq-client-nodejs.

NBSeven avatar NBSeven commented on September 27, 2024

@danger49 报什么错?
装了cmake

git submodule update --init --recommend-shallow

[email protected] install /Users/wangzhongxiang/Documents/duiba/tuia-risk-adfilter-node/rocketmq-client-nodejs
if [ ! -d deps/rocketmq/bin ]; then deps/rocketmq/build.sh; fi && node-gyp rebuild

CXX(target) Release/obj.target/rocketmq/src/rocketmq.o
CXX(target) Release/obj.target/rocketmq/src/producer.o
CXX(target) Release/obj.target/rocketmq/src/push_consumer.o
CXX(target) Release/obj.target/rocketmq/src/consumer_ack.o
SOLINK_MODULE(target) Release/rocketmq.node
ld: library not found for -lrocketmq
clang: error: linker command failed with exit code 1 (use -v to see invocation)
make: *** [Release/rocketmq.node] 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: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/bin/node" "/usr/local/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
gyp ERR! cwd /Users/wangzhongxiang/Documents/duiba/tuia-risk-adfilter-node/rocketmq-client-nodejs
gyp ERR! node -v v14.15.0
gyp ERR! node-gyp -v v5.1.0
gyp ERR! not ok
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! [email protected] install: if [ ! -d deps/rocketmq/bin ]; then deps/rocketmq/build.sh; fi && node-gyp rebuild
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the [email protected] install script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

from rocketmq-client-nodejs.

ifplusor avatar ifplusor commented on September 27, 2024

@NBSeven What's version do you use?

from rocketmq-client-nodejs.

casWangyy avatar casWangyy commented on September 27, 2024

the same question on mac os

from rocketmq-client-nodejs.

Related Issues (18)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.