当前位置: 首页 > 知识库问答 >
问题:

设置stf时,“npm安装-g stf”显示错误

梅逸清
2023-03-14
"I am trying to set up STF(SmartPhone test farm), but while installing NPM and firing command "npm install -g stf" in terminal i

我收到以下错误。”

Enter code here

sh-3.2# npm install -g stf
npm WARN deprecated node-uuid@1.4.7: use uuid module instead
/usr/local/bin/stf -> /usr/local/lib/node_modules/stf/bin/stf

> dtrace-provider@0.8.0 install /usr/local/lib/node_modules/stf/node_modules/bunyan/node_modules/dtrace-provider
> node scripts/install.js


> dtrace-provider@0.7.1 install /usr/local/lib/node_modules/stf/node_modules/dtrace-provider
> node scripts/install.js


> bufferutil@1.3.0 install /usr/local/lib/node_modules/stf/node_modules/bufferutil
> node-gyp rebuild

gyp WARN EACCES user "root" does not have permission to access the dev dir "/var/root/.node-gyp/6.9.5"
gyp WARN EACCES attempting to reinstall using temporary dev dir "/usr/local/lib/node_modules/stf/node_modules/bufferutil/.node-gyp"
xcode-select: error: tool 'xcodebuild' requires Xcode, but active developer directory '/Library/Developer/CommandLineTools' is a command

线工具实例

xcode-select: error: tool 'xcodebuild' requires Xcode, but active developer directory '/Library/Developer/CommandLineTools' is a command

线工具实例

  CXX(target) Release/obj.target/bufferutil/src/bufferutil.o
  SOLINK_MODULE(target) Release/bufferutil.node

> jpeg-turbo@0.4.0 install /usr/local/lib/node_modules/stf/node_modules/jpeg-turbo
> node-pre-gyp install --fallback-to-build

gyp WARN EACCES user "root" does not have permission to access the dev dir "/var/root/.node-gyp/6.9.5"
gyp WARN EACCES attempting to reinstall using temporary dev dir "/usr/local/lib/node_modules/stf/node_modules/jpeg-turbo/.node-gyp"
xcode-select: error: tool 'xcodebuild' requires Xcode, but active developer directory '/Library/Developer/CommandLineTools' is a command

线工具实例

xcode-select: error: tool 'xcodebuild' requires Xcode, but active developer directory '/Library/Developer/CommandLineTools' is a command

线工具实例

make: *** No rule to make target `../.node-gyp/6.9.5/include/node/common.gypi', needed by `Makefile'. 

停止。吉普ERR!构建错误吉普ERR!堆栈错误:make失败,退出代码:2吉普ERR!堆栈在ChildP_退出(/usr/local/lib/node_modules/npm/node_modules/node-gyp/lib/build.js:276: 23)吉普ERR!堆栈在emitTwo(events.js:106: 13)吉普ERR!堆栈在ChildProcess.emit(events.js:191: 7)吉普ERR!堆栈在进程。ChildProcess。rocess.onhandle.onexit(内部/child_process.js:215: 12)吉普ERR!系统达尔文15.3.0吉普ERR!命令"/usr/local/bin/node""/usr/local/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js""build""--allback-to-build""--mode=/usr/local/lib/node_modules/stf/node_modules/jpeg-turbo/lib/绑定/node-v48-darwin-x64/jpegturbo.node"--module_name=jpegturbo"--module_path=/usr/local/lib/node_modules/stf/node_modules/jpeg-turbo/lib/绑定/node-v48-darwin-x64"gyp ERR! cwd /usr/local/lib/node_modules/stf/node_modules/jpeg-turbogyp ERR! node-v v6.9.5 gyp ERR! node-gyp-v v3.4.0 gyp ERR! not ok node-pre-gyp ERR!构建错误node-pre-gyp ERR!堆栈错误:无法html" target="_blank">执行'/usr/local/bin/node /usr/local/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.jsbuild-回退到构建-模块=/usr/local/lib/node_modules/stf/node_modules/jpeg-turbo/lib/绑定/node-v48-darwin-x64/jpegturbo.node--module_name=jpegturbo--module_path=/usr/local/lib/node_modules/stf/node_modules/jpeg-turbo/lib/绑定/node-v48-darwin-x64'(1)node-pre-gyp ERR!在ChildProcess堆栈。(/usr/local/lib/node_modules/stf/node_modules/jpeg-turbo/node_modules/node-pre-gyp/lib/util/compile.js:83: 29)node-pre-gyp ERR!堆栈在emit2(events.js:106: 13)node-pre-gyp ERR!堆栈在ChildProcess.emit(events.js:191: 7)node-pre-gyp ERR!堆栈在可能关闭(内部/child_process.js:877: 16)node-pre-gyp ERR!堆栈在进程。ChildProcess。node_moduleshandle.onexit(内部/child_process.js:226: 5)node-pre-gyp ERR!系统达尔文15.3.0 node-pre-gyp ERR!命令“/usr/local/bin/node”“/usr/local/lib/node_modules/stf/node_modules/jpeg-turbo/_/. bin/node-pre-gyp”“安装”“——回退到构建”node-pre-gyp ERR!cwd /usr/local/lib/node_modules/stf/node_modules/jpeg-turbonode-pre-gyp ERR!node-v v6.9.5 node-pre-gyp ERR!node-pre-gyp-v v0.6.19 node-pre-gyp ERR!不确定无法执行'/usr/local/bin/node /usr/local/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.jsbuild-回退构建-模块=/usr/local/lib/node_modules/stf/node_modules/jpeg-turbo/lib/绑定/node-v48-darwin-x64/jpegturbo.node--module_name=jpegturbo--module_path=/usr/local/lib/node_modules/stf/node_modules/jpeg-turbo/lib/绑定/node-v48-darwin-x64'(1) /usr/local/lib──(空)

npm ERR! Darwin 15.3.0
npm ERR! argv "/usr/local/bin/node" "/usr/local/bin/npm" "install" "-g" "stf"
npm ERR! node v6.9.5
npm ERR! npm  v3.10.10
npm ERR! code ELIFECYCLE
npm ERR! jpeg-turbo@0.4.0 install: `node-pre-gyp install --fallback-to-build`
npm ERR! Exit status 1
npm ERR! 
npm ERR! Failed at the jpeg-turbo@0.4.0 install script 'node-pre-gyp install --fallback-to-build'.
npm ERR! Make sure you have the latest version of node.js and npm installed.
npm ERR! If you do, this is most likely a problem with the jpeg-turbo package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR!     node-pre-gyp install --fallback-to-build
npm ERR! You can get information on how to open an issue for this project with:
npm ERR!     npm bugs jpeg-turbo
npm ERR! Or if that isn't available, you can get their info via:
npm ERR!     npm owner ls jpeg-turbo
npm ERR! There is likely additional logging output above.
npm ERR! Please include the following file with any support request:
npm ERR!     /Users/indianic/npm-debug.log
npm ERR! code 1

共有1个答案

刘嘉木
2023-03-14

帮助#1961

似乎也有同样的问题,希望他们的修复对您有效。

 类似资料:
  • 问题内容: 当我尝试在nodejs服务器上安装时间时,出现以下错误: 问题答案: 您正在使用哪个操作系统? 如果是Ubuntu,则需要安装build-essential软件包: 然后尝试再次安装该软件包。

  • 我是一个初学者,我正在努力学习角,所以我试图安装一个新的项目与角种子。但是当我安装npm时,我得到一个错误,我不知道是从哪里来的。我已经安装了节点。版本是5.5.0。这是我在控制台得到的错误。

  • 我使用npm很长一段时间了(使用Win10)-在防火墙/权限等方面没有改变任何东西,突然间我在尝试安装任何软件包时出现以下错误: C:\udemy-button>npm安装引导程序--保存npm错误!路径C:\udemy-button\node_modules\fsevents\node_modules\aws4\package.json npm err!代码EPERM npm错误!错误-4048

  • 我在安装NPM时遇到以下错误: npm WARN Worker-Loader@0.8.1需要WebPack@>=0.9<2^2.1.0-Beta^2.2.0的对等项,但未安装任何对等项。 npm警告可选跳过可选依赖项:fsevents@1.1.2(node_modules\fsevents): npm WARN notsup跳过可选依赖项:fsevents@1.1.2:wanted平台不受支持{“

  • 问题内容: 我刚刚安装了Jenkins 2.6(作为全新安装),但似乎找不到Maven安装选项。以前,我只能进入Jenkins配置,并且在Maven部分中可以选择并自动安装Maven。但是,这似乎对我不存在。 我已经安装了Maven集成插件。如何显示这些内容? 问题答案: 从Jenkins 2.x开始,您可以在Jenkins管理(Manage Jenkins)的“全局工具”条目下找到所有工具配置(

  • 当我运行命令时,会出现以下错误: 我尝试像下面这样设置pythonpath:https://www.tutorialspoint.com/how-to-set-your-python-path-on-Mac,但没有帮助 我只是通过使用本教程插入路径:https://www.howtogeek.com/118594/how-to-edit-your-system-path-for-easy-comm