LINK : fatal error LNK1221: a subsystem can't be inferred and must be defined
You need to set the subsystem in your C++ project under Project Properties -> Configuration Properties -> Linker -> System -> SubSystem. And you probably want to use SUBSYSTEM:WINDOWS.