I'm trying to install a node.js module (zmq in this case) with npm install. The C lib needed for this module is not installed in a standard location. How do I specify extra include paths and lib paths to npm? I've tried things like "CFLAGS="-I/path/to/include" npm install" with no effect.
The zeromq module can be built as follows (other modules may work the same):
/tmp/zeromq.node-masterbinding.gyp file-I and library -L paths there. e.g.
['OS=="linux"', {
'cflags': [
'<!(pkg-config libzmq --cflags 2>/dev/null || echo "")',
'-I/usr/local/zeromq3/include'
],
'libraries': [
'<!(pkg-config libzmq --libs 2>/dev/null || echo "")',
'-L/usr/local/zeromq3/lib'
],
}],
npm install /tmp/zeromq.node-master