简体   繁体   English

使用node.js安装高速公路

[英]Installing autobahn with node.js

I am new to nodejs and looking to run some simple code on Ubuntu 16.04. 我是nodejs的新手,希望在Ubuntu 16.04上运行一些简单的代码。

I have installed nodejs and npm 我已经安装了nodejs和npm

root@coding:~# node -v
v6.3.0
root@coding:~# npm -v
3.10.3

I am now looking to install autobahn as per: http://autobahn.ws/js/gettingstarted.html 我现在正在按照以下方法安装高速公路: http : //autobahn.ws/js/gettingstarted.html

Unfortunately I get: 不幸的是我得到:

root@coding:~# npm install autobahn

> bufferutil@1.2.1 install /root/node_modules/bufferutil
> node-gyp rebuild

gyp WARN download NVM_NODEJS_ORG_MIRROR is deprecated and will be removed in node-gyp v4, please use NODEJS_ORG_MIRROR
gyp WARN download NVM_NODEJS_ORG_MIRROR is deprecated and will be removed in node-gyp v4, please use NODEJS_ORG_MIRROR
gyp WARN download NVM_NODEJS_ORG_MIRROR is deprecated and will be removed in node-gyp v4, please use NODEJS_ORG_MIRROR
make: Entering directory '/root/node_modules/bufferutil/build'
  CXX(target) Release/obj.target/bufferutil/src/bufferutil.o
  SOLINK_MODULE(target) Release/obj.target/bufferutil.node
  COPY Release/bufferutil.node
make: Leaving directory '/root/node_modules/bufferutil/build'

> utf-8-validate@1.2.1 install /root/node_modules/utf-8-validate
> node-gyp rebuild

gyp WARN download NVM_NODEJS_ORG_MIRROR is deprecated and will be removed in node-gyp v4, please use NODEJS_ORG_MIRROR
gyp WARN download NVM_NODEJS_ORG_MIRROR is deprecated and will be removed in node-gyp v4, please use NODEJS_ORG_MIRROR
gyp WARN download NVM_NODEJS_ORG_MIRROR is deprecated and will be removed in node-gyp v4, please use NODEJS_ORG_MIRROR
make: Entering directory '/root/node_modules/utf-8-validate/build'
  CXX(target) Release/obj.target/validation/src/validation.o
  SOLINK_MODULE(target) Release/obj.target/validation.node
  COPY Release/validation.node
make: Leaving directory '/root/node_modules/utf-8-validate/build'
/root
└─┬ autobahn@0.10.1 
  ├─┬ bufferutil@1.2.1 
  │ ├── bindings@1.2.1 
  │ └── nan@2.4.0 
  ├── crypto-js@3.1.6 
  ├─┬ msgpack-lite@0.1.20 
  │ ├── event-lite@0.1.1 
  │ ├── ieee754@1.1.6 
  │ ├── int64-buffer@0.1.9 
  │ └── isarray@1.0.0 
  ├── utf-8-validate@1.2.1 
  ├── when@3.7.7 
  └─┬ ws@1.1.1 
    ├── options@0.0.6 
    └── ultron@1.0.2 

npm WARN enoent ENOENT: no such file or directory, open '/root/package.json'
npm WARN root No description
npm WARN root No repository field.
npm WARN root No README data
npm WARN root No license field.

WARNING-1: 警告-1:

gyp WARN download NVM_NODEJS_ORG_MIRROR is deprecated and will be removed in node-gyp v4, please use NODEJS_ORG_MIRROR

REASON: One of the dependencies of either your npm or autobahn is using a deprecated library or function, which is NVM_NODEJS_ORG_MIRROR in this case. 原因: npm或高速公路的依赖项之一是使用不赞成使用的库或函数,在这种情况下为NVM_NODEJS_ORG_MIRROR If your npm is already upto date, don't worry the guys at autobahn will fix it. 如果您的npm已经更新,不要担心autobahn的家伙会解决它。 Raise an issue with them if you feel so. 如果您愿意,请与他们提出问题。

WARNING-2: 警告2:

npm WARN enoent ENOENT: no such file or directory, open '/root/package.json'
npm WARN root No description
npm WARN root No repository field.
npm WARN root No README data
npm WARN root No license field.

REASON: You don't have a package.json. 原因:您没有package.json。 Simply run npm init and follow the instructions and it'll create one for you. 只需运行npm init并按照说明进行操作,它将为您创建一个。

CONCLUSION: 结论:

Either way both are warning. 无论哪种方式都是警告。 Check your node_modules\\ folder and to most probability everything should be installed becase there was no errors listed. 检查您的node_modules\\文件夹,如果没有列出错误,则很可能应该安装所有组件。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM