在执行npm install的时候出现了下面的错误,安装Xcode并执行sudo xcode-select -s /Applications/Xcode.app/Contents/Developer,整个过程记录如下

$~> npm install

> fsevents@1.2.11 install /Users/*/Project/*/node_modules/fsevents
> node-gyp rebuild No receipt for 'com.apple.pkg.CLTools_Executables' found at '/'. No receipt for 'com.apple.pkg.DeveloperToolsCLILeo' found at '/'. No receipt for 'com.apple.pkg.DeveloperToolsCLI' found at '/'. gyp: No Xcode or CLT version detected!
gyp ERR! configure error
gyp ERR! stack Error: `gyp` failed with exit code: 1
gyp ERR! stack at ChildProcess.onCpExit (/usr/local/lib/node_modules/npm/node_modules/node-gyp/lib/configure.js:351:16)
gyp ERR! stack at ChildProcess.emit (events.js:210:5)
gyp ERR! stack at Process.ChildProcess._handle.onexit (internal/child_process.js:272:12)
gyp ERR! System Darwin 19.2.0
gyp ERR! command "/usr/local/Cellar/node/12.12.0/bin/node" "/usr/local/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
gyp ERR! cwd /Users/*/Project/*/node_modules/fsevents
gyp ERR! node -v v12.12.0
gyp ERR! node-gyp -v v5.0.5
gyp ERR! not ok
npm notice created a lockfile as package-lock.json. You should commit this file.
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.2.11 (node_modules/fsevents):
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.2.11 install: `node-gyp rebuild`
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: Exit status 1 added 455 packages from 261 contributors in 9.297s 5 packages are looking for funding
run `npm fund` for details $~> sudo xcode-select -s /Applications/Xcode.app/Contents/Developer
Password:
$~> npm install > fsevents@1.2.11 install /Users/*/Project/*/node_modules/fsevents
> node-gyp rebuild SOLINK_MODULE(target) Release/.node
CXX(target) Release/obj.target/fse/fsevents.o
SOLINK_MODULE(target) Release/fse.node
added 71 packages from 33 contributors in 6.981s 5 packages are looking for funding
run `npm fund` for details

在npm install时node-gyp出现错误的更多相关文章

  1. npm install 时总是报phantomjs-prebuilt@2.1.14安装失败

    在npm install时总是报如下错误, 尝试单独安装:npm install phantomjs-prebuilt@2.1.14 还是报错 Please report this full log ...

  2. 转:npm install 时总是报phantomjs-prebuilt@2.1.14安装失败

    该文章转自:http://www.cnblogs.com/alice626/p/6206722.html 在npm install时总是报如下错误, 尝试单独安装:npm install phanto ...

  3. npm install 时出现的 EACCES: permission denied 错误的可能有效的解决方案

    最近我开始接触手机 app 的编写,公司用到了 Nativescript.当我下载了公司的项目后,在配置时出现了不少的问题,其中出现概率最高的就是 EACCES: permission denied ...

  4. 安装npm install时,长时间停留在某一处的解决方案

    默认情况npm install安装时,会从 github.com 上下载文件,大部分安装不成功的原因都源自这里 因为 GitHub Releases 里的文件都托管在 s3.amazonaws.com ...

  5. 安装npm install时,长时间停留在fetchMetadata的解决方法

    安装npm install时,长时间停留在fetchMetadata: sill mapToRegistry uri http://registry.npmjs.org/whatwg-fetch处, ...

  6. 安装npm install时,长时间停留在fetchMetadata: sill 解决方法——换npm的源

    安装npm install时,长时间停留在fetchMetadata: sill mapToRegistry uri http://registry.npmjs.org/whatwg-fetch处, ...

  7. 使用npm install时一直报错-4048 operation not permitted

    一:权限问题 首先看到operation not permitted我们能想到权限问题,所以这时候我们可以以管理员身份运行cmd或者直接快捷键Win+X来打开. 二:依赖包错误 如上图,根据错误日志我 ...

  8. npm install 时--save-dev和--save的区别

    package.json中两个字段含义简介 一直在使用npm包管理器,对于npm install module --save-dev 和 npm install module --save这两个的区别 ...

  9. vue-cli 项目踩坑 npm install 时出错

    1.报错如下: 2.此时你执行npm run dev  / npm run build 会报错如下 npm ERR! code ELIFECYCLEnpm ERR! errno 1npm ERR! v ...

随机推荐

  1. 1.5JdbcTmeplates、Jpa、Mybatis、beatlsql、Druid的使用

    Spring boot 连接数据库整合 -- create table `account`DROP TABLE `account` IF EXISTSCREATE TABLE `account` ( ...

  2. Eureka【启用https】

    上一篇主要说的是开启http basic认证,从安全角度来讲,基于base64编码,容易被抓包后破解,在公网中很不安全,本文详谈如何在eureka server和eureka client中开启htt ...

  3. 在Visual C++ 6.0中为代码添加行号

    由如上代码可知Visual C++ 6.0是没有行号的(新手代码不要在意,重点是没有行号),在编译报错的时候会发现其会指出在第几行错了,如果没有代码行号将很难找到它 为解决这个问题可以安装插件给Vis ...

  4. PHP搭建B2C分销商城系统需要考虑哪些因素?(一)

    在网购日渐繁盛的今天,传统线下门店和代理分销越发显示出其弊端.此种情况下,进入互联网市场是最好的选择.入驻第三方平台成本太高,无法掌握自己的流量,所以搭建自己的分销平台成为众多企业的首选.搭建B2C分 ...

  5. KeyValuePair<string, string>

    ; #region CUP Method /// <summary> /// 请求与响应的超时时间 /// </summary> static public int Timeo ...

  6. 怎样安装并编译TypeScript?

    1. 使用: npm -v 查看是否安装了 npm ,  如果没有安装, 请前往 Nodejs 官网 下载安装, 下图表示已经安装 npm , 版本为: 6.9.0 . PS C:\Users\Adm ...

  7. C#动态生成Word文档并填充数据

    C#也能动态生成Word文档并填充数据 http://www.cnblogs.com/qyfan82/archive/2007/09/14/893293.html 引用http://blog.csdn ...

  8. CentOS开机启动进度条卡死问题

    centos为例 一, 如下: 如果这个地方卡住了的话也许是你上次改了passwd文件,这个是其中一个情况. 如果刚刚开机就卡住了或者怎么卡住了的话在开机的读条时候摁esc显示读取的进程,根据显示的错 ...

  9. Navicat for MySQL 设置定时任务(事件)

    1.查询界面输入命令,查看定时任务是否开启,未开始时OFF: show variables like '%event_scheduler%'; 2. 查询界面输入命令,开启定时任务: set glob ...

  10. ubuntu安装交叉编译器

    # sudo apt-get install gcc-arm-linux-gnueabi # sudo apt-get install g++-arm-linux-gnueabi 官方下载 https ...