joeferner / node-oracle

node.js driver to connect with an oracle database.
MIT License
271 stars 99 forks source link

failed to install oracle package in Solaris 11 #227

Open ReznichenkoSV opened 9 years ago

ReznichenkoSV commented 9 years ago
make: Entering directory `/u/test-node-oracle/node_modules/oracle/build'
  CXX(target) Release/obj.target/oracle_bindings/src/connection.o
cc1plus: error: unrecognized command line option "-fno-tree-vrp"
make: *** [Release/obj.target/oracle_bindings/src/connection.o] Error 1
make: Leaving directory `/u/test-node-oracle/node_modules/oracle/build'
gyp ERR! build error
gyp ERR! stack Error: `make` failed with exit code: 2
gyp ERR! stack     at ChildProcess.onExit (/opt/Node/lib/node_modules/npm/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:810:12)
gyp ERR! System SunOS 5.11
gyp ERR! command "node" "/opt/Node/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
gyp ERR! cwd /u/test-node-oracle/node_modules/oracle
gyp ERR! node -v v0.10.31
gyp ERR! node-gyp -v v1.0.1
gyp ERR! not ok
npm ERR! oracle@0.3.7 install: `node-gyp rebuild`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the oracle@0.3.7 install script.
npm ERR! This is most likely a problem with the oracle package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR!     node-gyp rebuild
npm ERR! You can get their info via:
npm ERR!     npm owner ls oracle
npm ERR! There is likely additional logging output above.

npm ERR! System SunOS 5.11
npm ERR! command "/opt/Node/bin/node" "/opt/Node/bin/npm" "install" "oracle"
npm ERR! cwd /u/test-node-oracle
npm ERR! node -v v0.10.31
npm ERR! npm -v 1.4.23
npm ERR! code ELIFECYCLE
npm ERR!
npm ERR! Additional logging details can be found in:
npm ERR!     /u/test-node-oracle/npm-debug.log
npm ERR! not ok code 0

I checked system variables was set up correctly:

OCI_INCLUDE_DIR=/u/app/oracle/instantclient_12_1//sdk/include
OCI_HOME=/u/app/oracle/instantclient_12_1/
OCI_VERSION=11
OCI_LIB_DIR=/u/app/oracle/instantclient_12_1/
FedericoLaggiard commented 9 years ago

UP same problem here, but on Solaris 10

ReznichenkoSV commented 9 years ago

Suggestion:

  1. Use Oracle Application Express on the server side and receive data via the configured api Oracle REST Data Services.
  2. In this case, the client oracle for node.js not needed using http request.
antoniobusrod commented 9 years ago

I think it is because you are compiling with an old version of gcc, maybe version 3. Maybe upgrading gcc to version 4 (4.3) will solve your problem.

It worked for me.

Related issue: https://github.com/joyent/node/issues/3863