Installation error #62

Open
ghost opened this Issue Mar 28, 2012 · 7 comments

Comments

Projects
None yet
5 participants
@ghost

ghost commented Mar 28, 2012

Hi, I'm currently trying to install db-mysql on my Mac (v10.7.3) and it's not ok ..

Here a log of the error

npm http GET https://registry.npmjs.org/db-mysql
npm http 304 https://registry.npmjs.org/db-mysql

> db-mysql@0.7.6 install /usr/local/lib/node_modules/db-mysql
> node-waf configure build

Checking for program g++ or c++          : /usr/bin/g++ 
Checking for program cpp                 : /usr/bin/cpp 
Checking for program ar                  : /usr/bin/ar 
Checking for program ranlib              : /usr/bin/ranlib 
Checking for g++                         : ok  
Checking for node path                   : not found 
Checking for node prefix                 : ok /usr/local 
Checking for program mysql_config        : not found 
/usr/local/lib/node_modules/db-mysql/wscript:34: error: The program ['mysql_config'] is required

> db-mysql@0.7.6 preuninstall /usr/local/lib/node_modules/db-mysql
> rm -rf build/*


npm ERR! db-mysql@0.7.6 install: `node-waf configure build`
npm ERR! `sh "-c" "node-waf configure build"` failed with 1
npm ERR! 
npm ERR! Failed at the db-mysql@0.7.6 install script.
npm ERR! This is most likely a problem with the db-mysql package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR!     node-waf configure build
npm ERR! You can get their info via:
npm ERR!     npm owner ls db-mysql
npm ERR! There is likely additional logging output above.
npm ERR! 
npm ERR! System Darwin 11.3.0
npm ERR! command "node" "/usr/local/bin/npm" "install" "-g" "db-mysql"
npm ERR! cwd /Users/xxx/Desktop/node-db-mysql
npm ERR! node -v v0.6.13
npm ERR! npm -v 1.1.9
npm ERR! code ELIFECYCLE
npm ERR! message db-mysql@0.7.6 install: `node-waf configure build`
npm ERR! message `sh "-c" "node-waf configure build"` failed with 1
npm ERR! errno {}
npm ERR! 
npm ERR! Additional logging details can be found in:
npm ERR!     /Users/xxx/Desktop/node-db-mysql/npm-debug.log
npm not ok

I've added the following line (export MYSQL_CONFIG=/Applications/MAMP/Library/bin/mysql_config) to my .bash_profile and restart the terminal

echo $MYSQL_CONFIG
/Applications/MAMP/Library/bin/mysql_config
@ghost

This comment has been minimized.

Show comment Hide comment
@ghost

ghost Mar 30, 2012

up ?

ghost commented Mar 30, 2012

up ?

@Sannis

This comment has been minimized.

Show comment Hide comment
@Sannis

Sannis Apr 14, 2012

Try node-mysql-libmysqlclient if you are looking for Node.js MySQL driver ;)

Sannis commented Apr 14, 2012

Try node-mysql-libmysqlclient if you are looking for Node.js MySQL driver ;)

@devvyn

This comment has been minimized.

Show comment Hide comment
@devvyn

devvyn May 11, 2012

Same problem for me. The installer doesn't seem to care about the MYSQL_CONFIG environment variable alone. Perhaps the installation instructions at http://nodejsdb.org/db-mysql/ just need to be clarified. (OS X 10.7) The only way I could install was to set the variable and then navigate to the directory where mysql_config resides and run the installer there without using sudo. The installer completes, but there's nothing in the node_modules directory afterward. I don't fully understand the issue but I can at least confirm it happens to me, too.

devvyn commented May 11, 2012

Same problem for me. The installer doesn't seem to care about the MYSQL_CONFIG environment variable alone. Perhaps the installation instructions at http://nodejsdb.org/db-mysql/ just need to be clarified. (OS X 10.7) The only way I could install was to set the variable and then navigate to the directory where mysql_config resides and run the installer there without using sudo. The installer completes, but there's nothing in the node_modules directory afterward. I don't fully understand the issue but I can at least confirm it happens to me, too.

@Sannis

This comment has been minimized.

Show comment Hide comment
@Sannis

Sannis May 12, 2012

The installer completes, but there's nothing in the node_modules directory afterward. I don't fully understand the issue but I can at least confirm it happens to me, too.

It is ok, compiled addon will be in ./build/default/mysql_bindings.node or in ./build/Release/mysql_bindings.node depending on your node version. You should require db-mysql.js to use it or just install it locally for oyur application via npm.

Sannis commented May 12, 2012

The installer completes, but there's nothing in the node_modules directory afterward. I don't fully understand the issue but I can at least confirm it happens to me, too.

It is ok, compiled addon will be in ./build/default/mysql_bindings.node or in ./build/Release/mysql_bindings.node depending on your node version. You should require db-mysql.js to use it or just install it locally for oyur application via npm.

@NachoSoto

This comment has been minimized.

Show comment Hide comment
@NachoSoto

NachoSoto Nov 27, 2012

This is happening to me too... which makes it impossible to install now

This is happening to me too... which makes it impossible to install now

@aaronfrost

This comment has been minimized.

Show comment Hide comment
@aaronfrost

aaronfrost Dec 17, 2012

I had the same error on Ubunutu 12.04, but installing the libmysqlclient-dev fixed. db-mysql now installs

I had the same error on Ubunutu 12.04, but installing the libmysqlclient-dev fixed. db-mysql now installs

@f9pix

This comment has been minimized.

Show comment Hide comment
@f9pix

f9pix Feb 17, 2013

haha awesome arronfrost , it working for me now :)

f9pix commented Feb 17, 2013

haha awesome arronfrost , it working for me now :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment