codeblocks编译找不到SDL2/SDL.h SDL.h SDL_image.h
下载
https://github.com/libsdl-org/SDL/releases/
https://github.com/libsdl-org/SDL_image/releases
1. 解压
将SDL2_image-devel-2.6.3-mingw.zip里面x86_64-w64-mingw32的lib、bin、include对应文件
解压到SDL2-devel-2.28.2-mingw.zip\SDL2-2.28.2\x86_64-w64-mingw32\lib、bin、include对应文件夹里面。
2. 配置codeblocks
Build options -> Linker settings -> Other linker options: -lmingw32 -lSDL2 -lSDL2main -lSDL2_image
添加SDL2位置
Search directories -> Compiler:
D:\Lvgl\SDL2-devel-2.28.2-mingw\SDL2-2.28.2\x86_64-w64-mingw32\include\SDL2
D:\Lvgl\SDL2-devel-2.28.2-mingw\SDL2-2.28.2\x86_64-w64-mingw32\include
Search directories -> Linker:
D:\Lvgl\SDL2-devel-2.28.2-mingw\SDL2-2.28.2\x86_64-w64-mingw32\lib
D:\Lvgl\SDL2-devel-2.28.2-mingw\SDL2-2.28.2\x86_64-w64-mingw32\bin
**粗体** _斜体_ [链接](http://example.com) `代码` - 列表 > 引用
。你还可以使用@
来通知其他用户。