question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Error in installing ibm_db

See original GitHub issue

Hi, I am getting the below error in mac while doing “npm install ibm_db”. Absolutely no clue as I am a UI developer.

Nagas-MacBook-Pro:lib nagasrinivasa$ npm install ibm_db

ibm_db@2.4.0 install /usr/local/lib/node_modules/ibm_db node installer/driverInstall.js

Downloading DB2 ODBC CLI Driver from https://public.dhe.ibm.com/ibmdl/export/pub/software/data/db2/drivers/odbc_cli/macos64_odbc_cli.tar.gz

100.00% | 20080158 bytes downloaded out of 20080158 bytes.


You are downloading a package which includes the Node.js module for IBM DB2/Informix. The module is licensed under the Apache License 2.0. The package also includes IBM ODBC and CLI Driver from IBM, which is automatically downloaded as the node module is installed on your system/device. The license agreement to the IBM ODBC and CLI Driver is available in undefined Check for additional dependencies, which may come with their own license agreement(s). Your use of the components of the package and dependencies constitutes your acceptance of their respective license agreements. If you do not accept the terms of any license agreement(s), then delete the relevant component(s) from your device.


Downloading and extraction of DB2 ODBC CLI Driver completed successfully …

CXX(target) Release/obj.target/odbc_bindings/src/odbc.o

{ Error: Command failed: node-gyp configure build --IS_DOWNLOADED=true --IBM_DB_HOME=“$IBM_DB_HOME” xcode-select: error: tool ‘xcodebuild’ requires Xcode, but active developer directory ‘/Library/Developer/CommandLineTools’ is a command line tools instance

xcode-select: error: tool ‘xcodebuild’ requires Xcode, but active developer directory ‘/Library/Developer/CommandLineTools’ is a command line tools instance

…/src/odbc.cpp:210:15: warning: ‘Call’ is deprecated [-Wdeprecated-declarations] data->cb->Call(1, info); ^ …/node_modules/nan/nan.h:1617:3: note: ‘Call’ has been explicitly marked deprecated here NAN_DEPRECATED inline v8::Localv8::Value ^ …/node_modules/nan/nan.h:98:40: note: expanded from macro ‘NAN_DEPRECATED’

define NAN_DEPRECATED attribute((deprecated))

                                   ^

…/src/odbc.cpp:217:80: error: no matching member function for call to ‘NewInstance’ Local<Object> js_result = Nan::New<Function>(ODBCConnection::constructor)->NewInstance(2, info); ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^ /Users/nagasrinivasa/.node-gyp/10.0.0/include/node/v8.h:3851:44: note: candidate function not viable: requires single argument ‘context’, but 2 arguments were provided V8_WARN_UNUSED_RESULT MaybeLocal<Object> NewInstance( ^ /Users/nagasrinivasa/.node-gyp/10.0.0/include/node/v8.h:3848:44: note: candidate function not viable: requires 3 arguments, but 2 were provided V8_WARN_UNUSED_RESULT MaybeLocal<Object> NewInstance( ^ …/src/odbc.cpp:222:15: warning: ‘Call’ is deprecated [-Wdeprecated-declarations] data->cb->Call(2, info); ^ …/node_modules/nan/nan.h:1617:3: note: ‘Call’ has been explicitly marked deprecated here NAN_DEPRECATED inline v8::Localv8::Value ^ …/node_modules/nan/nan.h:98:40: note: expanded from macro ‘NAN_DEPRECATED’

define NAN_DEPRECATED attribute((deprecated))

                                   ^

…/src/odbc.cpp:262:78: error: no matching member function for call to ‘NewInstance’ Local<Object> js_result = Nan::New<Function>(ODBCConnection::constructor)->NewInstance(2, params); ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^ /Users/nagasrinivasa/.node-gyp/10.0.0/include/node/v8.h:3851:44: note: candidate function not viable: requires single argument ‘context’, but 2 arguments were provided V8_WARN_UNUSED_RESULT MaybeLocal<Object> NewInstance( ^ /Users/nagasrinivasa/.node-gyp/10.0.0/include/node/v8.h:3848:44: note: candidate function not viable: requires 3 arguments, but 2 were provided V8_WARN_UNUSED_RESULT MaybeLocal<Object> NewInstance( ^ …/src/odbc.cpp:1194:7: warning: ‘Call’ is deprecated [-Wdeprecated-declarations] cb->Call(1, info); ^ …/node_modules/nan/nan.h:1617:3: note: ‘Call’ has been explicitly marked deprecated here NAN_DEPRECATED inline v8::Localv8::Value ^ …/node_modules/nan/nan.h:98:40: note: expanded from macro ‘NAN_DEPRECATED’

define NAN_DEPRECATED attribute((deprecated))

                                   ^

…/src/odbc.cpp:1258:87: error: too few arguments to function call, expected 2, have 1 objError->SetPrototype(Exception::Error(Nan::New(errorMessage).ToLocalChecked())); ~~~~~~~~~~~~~~~~~~~~~~ ^ /Users/nagasrinivasa/.node-gyp/10.0.0/include/node/v8.h:3308:3: note: ‘SetPrototype’ declared here V8_WARN_UNUSED_RESULT Maybe<bool> SetPrototype(Local<Context> context, ^ /Users/nagasrinivasa/.node-gyp/10.0.0/include/node/v8config.h:410:31: note: expanded from macro ‘V8_WARN_UNUSED_RESULT’ #define V8_WARN_UNUSED_RESULT attribute((warn_unused_result)) ^ 3 warnings and 3 errors generated. make: *** [Release/obj.target/odbc_bindings/src/odbc.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:258:23) gyp ERR! stack at ChildProcess.emit (events.js:182:13) gyp ERR! stack at Process.ChildProcess._handle.onexit (internal/child_process.js:225:12) gyp ERR! System Darwin 17.6.0 gyp ERR! command “/usr/local/bin/node” “/usr/local/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js” “configure” “build” “–IS_DOWNLOADED=true” “–IBM_DB_HOME=/usr/local/lib/node_modules/ibm_db/installer/clidriver” gyp ERR! cwd /usr/local/lib/node_modules/ibm_db gyp ERR! node -v v10.0.0 gyp ERR! node-gyp -v v3.6.2 gyp ERR! not ok

at ChildProcess.exithandler (child_process.js:282:12)
at ChildProcess.emit (events.js:182:13)
at maybeClose (internal/child_process.js:947:16)
at Socket.stream.socket.on (internal/child_process.js:368:11)
at Socket.emit (events.js:182:13)
at Pipe._handle.close [as _onclose] (net.js:598:12)

killed: false, code: 1, signal: null, cmd: ‘node-gyp configure build --IS_DOWNLOADED=true --IBM_DB_HOME=“$IBM_DB_HOME”’ } npm ERR! code ELIFECYCLE npm ERR! errno 1 npm ERR! ibm_db@2.4.0 install: node installer/driverInstall.js npm ERR! Exit status 1 npm ERR! npm ERR! Failed at the ibm_db@2.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/nagasrinivasa/.npm/_logs/2018-07-14T18_11_39_997Z-debug.log

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Comments:17 (6 by maintainers)

github_iconTop GitHub Comments

3reactions
kbosshardtcommented, Oct 10, 2018

Installing Xcode seemed to do the trick.

3reactions
rhtpandeyINcommented, Jul 14, 2018

Hi, you are getting this error because of the node.js version, currently node-ibm_db does not support node.js version 10 on Mac OS, please use node < 10.X. Thanks. Our team is working on this issue, very soon we will release the compatible version with node 10.X

Read more comments on GitHub >

github_iconTop Results From Across the Web

ERROR when `pip install ibm_db` · Issue #303
I cannot install ibm_db using pip! I get the following error: pip install ibm_db Collecting ibm_db Using cached ibm_db-2.0.8.tar.gz Building wheels for ...
Read more >
install error for ibm_db with pip (python)
The python ibm_db module by default will try to download from IBM the tiny footprint db2cli driver. This is what is failing in...
Read more >
Installation issues and solutions
You can diagnose problems when the installation and configuration is unsuccessful. Error: Cannot manage agent without connection information. When you install ...
Read more >
ibm_db
If npm install ibm_db aborts with "Out Of Memory" error on AIX, first run ulimit -d unlimited and then npm install ibm_db ....
Read more >
pip install ibm-db==3.1.1
Linux/Unix: If you face problems due to missing python header files while installing the driver, you would need to install python developer package...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found