微信公众号搜"智元新知"关注
微信扫一扫可直接关注哦!

µWebSockets 编译失败,并且没有预编译的二进制文件 - Raspberry Pi

如何解决µWebSockets 编译失败,并且没有预编译的二进制文件 - Raspberry Pi

我目前正在尝试在使用 uws 的 RaspBerry Pi 上运行 node.js 应用程序。但是,在使用 uws 安装 npm install uws 后,我收到以下错误消息:

            throw new Error('Compilation of µWebSockets has Failed and there is no pre-compiled binary ' +
            ^

Error: Compilation of µWebSockets has Failed and there is no pre-compiled binary available for your system. Please install a supported C++11 compiler and reinstall the module 'uws'.
    at /home/pi/visio/node_modules/uws/uws.js:38:19
    at Object.<anonymous> (/home/pi/visio/node_modules/uws/uws.js:42:3)
    at Module._compile (node:internal/modules/cjs/loader:1108:14)
    at Object.Module._extensions..js (node:internal/modules/cjs/loader:1137:10)
    at Module.load (node:internal/modules/cjs/loader:973:32)
    at Function.Module._load (node:internal/modules/cjs/loader:813:14)
    at Module.require (node:internal/modules/cjs/loader:997:19)
    at require (node:internal/modules/cjs/helpers:92:18)
    at Object.<anonymous> (/home/pi/visio/index.js:5:18)
    at Module._compile (node:internal/modules/cjs/loader:1108:14)

我的 NodeJS 版本:v15.5.0

我的 NPM 版本:7.3.0

我尝试了 sudo apt update && sudo apt upgrade 没有成功。我有 gcc version 8.3.0 (Raspbian 8.3.0-6+rpi1) 应该有 C++11 支持

有人遇到过类似的问题吗?

版权声明:本文内容由互联网用户自发贡献,该文观点与技术仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请发送邮件至 dio@foxmail.com 举报,一经查实,本站将立刻删除。