Search code examples
c++visual-studio-2013linkerprojects-and-solutions

How to disable link step in VS2013 project configuration?


I would like to disable the linker for a particular project configuration of a VS2013 C++ project. How can I do this?

I have tried to remove the output path, remove the <Link> parts of the project file, but this only results in error messages ("error : The OutputPath property is not set for project" / "error: The output paths do not match" etc.)

The reason is that this particular configuration does preprocessing to file so no object files are created, which always results in a linker error.


Solution

  • There is a compiler switch /c to "compile only". Unfortunately this is only available outside of Visual Studio. So you would need to build the project on the command line using cl.exe.