配置 Windows 下的 nodejs C++ 模块编译环境 安装 node-gyp

时间:2015-08-11 23:03:40   收藏:0   阅读:3413

配置 Windows 下的 nodejs C++ 模块编译环境

根据 node-gyp 指示的 Windows 编译环境说明, 简单一句话就是 "Python + VC++ 编译环境".

所有需要的安装文件, 我都下载好放到百度云盘了: nodejs-gyp-windows

Python

iso 虚拟磁盘

Windows XP

文件在: node-gyp-windows/windowsXP

Windows 7

文件在: node-gyp-windows/windows7

编译你的第一个 nodejs c++ 模块

假设你在使用 node v0.10.29

这里举例安装 microtime 模块:

$ npm install microtime --registry=https://registry.npm.taobao.org --disturl=https://npm.taobao.org/dist

测试安装编译结果:

$ node -e ‘console.log("now is %d ms", require("microtime").now())‘

原文:http://www.cnblogs.com/meetrice/p/4722357.html

评论(0
© 2014 bubuko.com 版权所有 - 联系我们:wmxa8@hotmail.com
打开技术之扣,分享程序人生!