I have created a Visual C++ empty project with Visual Studio 2017 15.3.4 Community edition selecting Visual C++ -> General -> Empty project from wizard. I wanted to create a C++ library (static or dynamic).
But when I compile it I get this message:
LINK : fatal error LNK1561: entry point must be defined
I have right clicked on Project, select Properties, Linker and advanced and Entry Point option is empty.
What do I have to put there?
Is there another better option to create a C++ library?
To create a static library in VS 2017 version 15.3.4, first select the "Windows Desktop Wizard" template,
In the wizard dialog that pops up, change the application type to static library:
You might also want to turn off precompiled headers, since with Visual C++ that gives a non-standard preprocessor behavior.
A library does not have an entrypoint, so you can tell that the project is not configured correctly. The specific setting you forgot to change is Project > Properties > General > Configuration Type. Select "Static library (.lib)".
This went wrong because you started from scratch, having to get dozens of settings right is never not a problem. For VS2017 RTM you'll favor starting from Win32 > Win32 Project > Next > "Static library" radio button. Maybe that changed, I haven't kept it updated because I've seen too many nasty bug reports for 15.3.x