__fltused already defined in LIBCMTD.lib c++ linker error LNK2005 already defined in SDL2

xingyun86 22天前 29

场景:

windows下visualstudio编译sdl2为静态库

问题:

sdl2demo例子使用时,出现

__fltused already defined in LIBCMTD.lib c++ linker error LNK2005 already defined in SDL2

解决方案:

编译sdl2静态库时,设定宏开关:#define HAVE_LIBC 1

VisualStudio编译则在Processor中设定

编译前,修改sdl2\include\sdl2_config.h,添加:#define HAVE_LIBC 1

×
打赏作者
最新回复 (0)
只看楼主
全部楼主
返回