Compile Multiple Files Into One Executable In Visual Studio Compiler – C++

  c++, cl

just a simple question I want to compile multiple files into one executable using the visual studio compiler (or as I call it "cl.exe").

for instance I have "main.cpp" this file needs a header file called "file.h" I need to compile both these files into one executable. I think you can do that in g++ so is there a way to do it in vs compiler?

oh by the way I’m not developing inside visual studio I’m just using the build tools.

thanks.

Source: Windows Questions C++

LEAVE A COMMENT