I get a strange behaviour when I compile SDL (2.0.3) on my own.
I compiled using CL.exe 18.00.30501 via nmake (Visual Studio Professional 2013) with CMAKE. When I want to compile and link a minimal example I get LNK2019 errors (unresolved symbol) which I can workaround by linking additionally to winmm.lib, imm32.lib and version.lib.
However, when I use the precompiled binaries or the compiled versions via the solution files, it works without these additional dependencies. So there must be something going on in the CMAKE options which I missed.
How can I get rid of these additional dependencies? Can I somehow link them into the library itself via cmake?
I tried to link my hello-sdl program to different versions of the library:
1.) compiled by source via cmake/nmake: dependencies needed.
2.) compiled by source via cmake/VS2013 solution files: dependencies needed.
3.) compiled by source via given VS2013 solution files: no dependencies needed.
4.) precompiled libraries: no dependencies needed.
So it must have something to do with the CMAKE compilation/linking process and not with my way how to link.
I simply want to understand in which way the precompiled binaries or the given solution files differ from the cmake-builds.