1、参考博文http://www.360doc.com/content/12/0719/18/2660674_225285935.shtml中的方法,在编译SDL-1.2源码时出现问题,没有set-gcc-default-*.sh
google后在https://github.com/adobe-flash/crossbridge/blob/master/cygwin/bin/set-gcc-default-3.sh找到对应文件,添加到cygwin。然而没有卵用。
2、换成SDL-2.0没有出现Your compiler (gcc) does not produce Win32 executables错误,但是make出了一串错误
google发现一片博文http://m.blog.csdn.net/article/details?id=50470665说需要修改SDL目录下/src/render/direct3d11/SDL_render_d3d11.c文件,然而没有说清楚怎么修改__FUNCTION__。
再google,发现两份补丁
http://pkgs.fedoraproject.org/cgit/rpms/mingw-SDL2.git/plain/SDL2-fix-gcc-compatibility.patch
https://github.com/mxe/mxe/blob/master/src/sdl2-1.patch
对着修改,通过make && make install
3、然而在configure ffmpeg时又发现SDL始终是no
4、最后发现博文http://blog.csdn.net/czc1009/article/details/12868933说SDL-2.0改动很大,易出问题。
将SDL-2.0 make uninstall && make clean
5、想到cygwin会不会本身有sdl库,打开setup-x86.exe,在库中搜索sdl,WTF,直接安装。
6 、 到ffmpeg目录configure、make、 make install