Small problem with including a library

Dec 28, 2014 at 10:35pm
Using CodeBlocks.
I've added the path to the library files in 'search directories' in 'linker' tab.
E:\Data\Comp\Library\SDL2-2.0.3\lib\x86
I also added the include files location in 'search directories' and that works fine.


But still when I add 'SDL2.lib' in linker settings and try to compile I get: cannot find -lSDL2.lib

I'm sure I just overlooked something here. Any ideas what's wrong?
Dec 29, 2014 at 2:21am
Did you add .dll link?
Dec 29, 2014 at 4:13am
remove the .lib in linker settings.
In windows you need

-lmingw32
-lSDL2main
-lSDL2
*And the sdl extentions like -lSDL2_image here*
Dec 29, 2014 at 2:48pm
removing .lib worked. tnx
-lmingw32 isn't necessary I think. I'm using that anyway
Topic archived. No new replies allowed.