Warning LNK4098 when building in debug configuration in Visual Studio

By default when building for Debug configuration in VS, it uses /MDd option, while (I assume) glfw3.lib has been compiled with /MD option.

As a workaround one can change the option in VS as follows (I leave it here for people who strugled with this issue too):

  1. Ensure that Configuration is set to Debug;
  2. C/C++ → Code Generation → Runtime Library;
  3. Choose /MD from the drop-down list.

Though, it would be nice to have glfw3_d.lib and glfw3_mt_d.lib, that are compiled with /MDd and /MTd options respectively, in the archive with the pre-compiled binaries for windows.

Thanks for the feedback - I’ll discuss this with @elmindreda

I would recommend using source code to build GLFW if you want control over any build options. It’s almost trivial to include GLFW manually by adding the files to an existing Visual Studio C++ project, and this is how I use GLFW. You can also build using Visual Studio with CMake based on something like: