pip 错误unused-command-line-argument-hard-error-in-future解决办法
在我的mac air上,用pip安装一些python库时,偶尔就会遇到一些报错,关于“unused-command-line-argument-hard-error-in-future”,错误如下:
cc -fno-strict-aliasing -fno-common -dynamic -arch x86_64 -arch i386 -g -os -pipe -fno-common -fno-strict-aliasing -fwrapv -mno-fused-madd -denable_dtrace -dmacosx -dndebug -wall -wstrict-prototypes -wshorten-64-to-32 -dndebug -g -fwrapv -os -wall -wstrict-prototypes -denable_dtrace -arch x86_64 -arch i386 -pipe -i/system/library/frameworks/python.framework/versions/2.7/include/python2.7 -c psutil/_psutil_osx.c -o build/temp.macosx-10.9-intel-2.7/psutil/_psutil_osx.o
clang: error: unknown argument: '-mno-fused-madd' [-wunused-command-line-argument-hard-error-in-future]
clang: note: this will be a hard error (cannot be downgraded to a warning) in the future
error: command 'cc' failed with exit status 1
这样的错误,出现次数多了,每次都去google,不如自己记录一下吧。
原因是:the apple llvm compiler in xcode 5.1 treats unrecognized command-line options as errors. this issue has been seen when building both python native extensions and ruby gems, where some invalid compiler options are currently specified.
解决方法:设置archflags参数,如下:
sudo archflags=-wno-error=unused-command-line-argument-hard-error-in-future pip install psutil
上一篇: 落枕怎么办 自我按摩手上落枕穴快速治疗
下一篇: 箭头函数
推荐阅读
-
未能加载文件或程序集 HRESULT:0×80131047错误的解决办法
-
Android 出现:java.lang.NoClassDefFoundError...错误解决办法
-
Android DaggerActivityComponent错误解决办法详解
-
MySQL Daemon failed to start错误解决办法
-
SpringBoot集成Swagger2实现Restful(类型转换错误解决办法)
-
502 bad gateway是什么意思?502 bad gateway错误解决办法
-
IE浏览器出现下载错误的解决办法
-
PHP编译安装时常见错误解决办法
-
CI使用Tank Auth转移数据库导致密码用户错误的解决办法
-
Android webview 遇到android.os.FileUriExposedException错误解决办法