What setting(s) in a Visual Studio 2005 project could cause the build to not add the /dll argument to the linker command line?
Background:
We have a large VC6 project that I'm porting over to VC 2005. This project contains a number of MFC extension DLLs, and I'm running into the following linker warning when I run a build:
warning LNK4086: entrypoint '_WinMainCRTStartup' is not __stdcall with 12 bytes of arguments; image may not run
The reference to _WinMainCRTStartup is highly suspicious, because this is a DLL (which shouldn't have a _WinMainCRTStartup function at all). A search for of the sources indicate that there is no such function defined, so my conclusion is that it it being provided to us by the linker.
Review of the linker.exe command line arguments shows the problem (I've removed full paths for brevity):
/OUT:"Debug\thedll.dll" /INCREMENTAL /MANIFEST /MANIFESTFILE:"Debug\thedll.dll.intermediate.manifest" /DEF:".\thedll.def" /DEBUG /PDB:"\Debug\thedll.pdb" /SUBSYSTEM:WINDOWS /MACHINE:X86 version.lib
There is a highly critical command line argument missing: /DLL
If I manually add this argument (using the project properties, Configuration Properties\Linker\Command Line settings), I can get things to compile properly.
But I'm wondering what in the project configuration is causing the /DLL command line setting of linker.exe to be left out?
I've created a temporary project with an extension DLL, and I've done side-by-side comparisons of the .vcproj files, but I can not see any specific settings that would impact this.
EDIT - I've checked the Configuration Properties\General\Project Defaults setting for Configuration Type. It is set to Dynamic Library (.dll)
EDIT2 - Apparently, VS was ignoring the setting until I manually adjusted it. rggggg