在Mac上安装uWSGI时出错 [英] Error while installing uWSGI on mac
本文介绍了在Mac上安装uWSGI时出错的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我需要uWSGI来运行django项目。所以当我试图安装uWSGI,它给我一个错误说异常:你需要一个C编译器来构建uWSGI。但是mac附带了gcc编译器。
I need uWSGI for running a django project. So when i'm trying to install uWSGI, its giving me an error saying "Exception: you need a C compiler to build uWSGI". But mac comes with gcc compiler.
我从 http://projects.unbit.it/uwsgi/wiki/WikiStart#Getit ,并尝试通过命令python setup.py install安装
I've downloaded uWSGI from "http://projects.unbit.it/uwsgi/wiki/WikiStart#Getit" and tried to install by the command "python setup.py install"
这是我在安装uWSGI时遇到的错误。
This is the error i got while installing uWSGI
running install
using profile: buildconf/default.ini
detected include path: ['/usr/local/include', '/Developer/usr/llvm-gcc-4.2/lib/gcc/i686-apple
darwin11/4.2.1/include', '/usr/include', '/System/Library/Frameworks', '/Library/Frameworks']
Traceback (most recent call last):
File "setup.py", line 98, in <module>
distclass=uWSGIDistribution,
File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/distutils/core.py",
line 152, in setup
dist.run_commands()
File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/distutils/dist.py",
line 953, in run_commands
self.run_command(cmd)
File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/distutils/dist.py",
line 972, in run_command
cmd_obj.run()
File "setup.py", line 61, in run
conf = uc.uConf(get_profile())
File "/Users/jay/Downloads/Softwares/Work/uwsgi-1.2.4/uwsgiconfig.py", line 340, in __init__
raise Exception("you need a C compiler to build uWSGI")
Exception: you need a C compiler to build uWSGI
推荐答案
gcc已安装,只需导出CC = gcc将可以。
gcc already installed, just export CC=gcc will be ok.
这篇关于在Mac上安装uWSGI时出错的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文