Pygame Installation Issue in MAC Os

Error when installing PyGame on Mac (Catalina)

Your error is right here:

src_c/_pygame.h:216:10: fatal error: 'SDL.h' file not found

You need to install the SDL development files. I haven't personally used macOS in a little while now but if you have homebrew installed, I believe brew install sdl should do the trick.

pygame installation issue in mac os

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

("default" branch is on commit e3ae850 right now)

Source: https://bitbucket.org/pygame/pygame/issue/139/sdlh-not-found-even-thought-it-exists#comment-3822470

See this other StackOverflow question too: PyGame in a virtualenv on OS X with brew?



Related Topics



Leave a reply



Submit