package/nodejs: Fixed npm global install
authorMartin Bark <martin@barkynet.com>
Wed, 28 Oct 2015 15:59:53 +0000 (15:59 +0000)
committerThomas Petazzoni <thomas.petazzoni@free-electrons.com>
Mon, 2 Nov 2015 22:12:02 +0000 (23:12 +0100)
commit1325da4a28f0c701c09b9f090df706838540948d
tree852db4884fe4bd8d2fe595214e27e5b13d5a7e94
parentc2dd6cd2575e7767a502c2ae4f15785bcc088214
package/nodejs: Fixed npm global install

Set npm_config_prefix to $(TARGET_DIR)/usr so that npm -g will correctly
install global modules to $(TARGET_DIR)/usr/lib/node_modules.

By using npm -g to install global modules npm will now automatically create
the symlinks to executables under $(TARGET_DIR)/usr/bin.

See https://docs.npmjs.com/misc/config#global and
https://docs.npmjs.com/files/folders for information on how the prefix
setting is used by global installs.

Signed-off-by: Martin Bark <martin@barkynet.com>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
package/nodejs/nodejs.mk