mac os中的pygame安装问题 [英] pygame installation issue in mac os
本文介绍了mac os中的pygame安装问题的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我在安装 pygame 包时遇到以下问题.
I have following issue of installing pygame package.
In file included from src/_numericsurfarray.c:23:
src/pygame.h:106:10: fatal error: 'SDL.h' file not found
#include <SDL.h>
^
1 error generated.
error: Setup script exited with error: command 'gcc' failed with exit status 1
系统信息
- Mac OS-10.9.2
- python 版本 - Python 2.7.5 :: Anaconda 1.6.1 (x86_64)
任何建议将不胜感激?谢谢.
Any suggestion will be greatly appreciate ? Thanks.
推荐答案
这里 (OSX Mavericks) 我可以这样安装:
Here (OSX Mavericks) I got able to install this way:
brew install sdl sdl_image sdl_mixer sdl_ttf portmidi
pip install https://bitbucket.org/pygame/pygame/get/default.tar.gz
(默认"分支现在提交e3ae850)
("default" branch is on commit e3ae850 right now)
来源:https://bitbucket.org/pygame/pygame/issue/139/sdlh-not-found-even-thought-it-exists#comment-3822470
也请参阅其他 StackOverflow 问题:虚拟环境中的 PyGame在 OS X 上使用 brew?
See this other StackOverflow question too: PyGame in a virtualenv on OS X with brew?
这篇关于mac os中的pygame安装问题的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文