M1 MAC安装pygame

1. 先安装下面这些库:

 

brew install hg sdl sdl_image sdl_ttf sdl2 sdl2_image pkgconfig sdl_mixer portmidi

如果没有找到,需要brew更换阿里源,更换方式见:https://www.cnblogs.com/mrlonely2018/p/15174983.html

 

2. git clone git@github.com:pygame/pygame.git

 

3. 进入repo,执行pip install .

 

posted @ 2021-08-27 23:43  Shiyu_Huang  阅读(359)  评论(0编辑  收藏  举报