Write about the problems and solutions when configuring OpenGL in vs2015

1. LNK2019 cannot resolve the external symbol _VSPRINTF, which is referenced in the function _PrintMessage
The problem seems to be that some functions in the add library are incompatible with the functions provided in VS, and additional dependencies need to be set
Specific solutions are as follows
Add a line of code under #include

#pragma comment(lib, "legacy_stdio_definitions.lib")

2. LNK2019 cannot parse the external symbol _main, which is used in the function “int __cdeclinvoke_main(void)” (?invoke_main@yahxz) is referenced

This is because the program does not have a main function, so the link fails. There are two ways to solve this problem: one is to write a main function as the entry point; The other is in the property page ->; The linker – & gt; On your system, change the first line from /subsytem:console to
/subsystem:windows

3. The arguments of type ‘char *’ participating in type ‘LPCWSTR’ are not compatible.
The argument of type “const char *” is not compatible with the parameter of type “LPCWSTR”.
This is due to the fact that VS2015 uses the Unicode character set. I have tried many methods to solve this problem for a long time, but the most convenient way to solve this problem is in the property page ->; In general, change the character set line from using the Unicode character set to using the multi-byte character set

Read More: