My VS Code's set-up to compile C++ generates too many files in the folder [closed]

20 hours ago 1
ARTICLE AD BOX

I have it set to compile at the shortcut control+shift+b, after which it compiles making a obj and exe file in the directory. For example, it makes a .pdb, .ilk, etc over and over, makine a simple 9 files in a folder for my class's first unit into 6 files for one actual cpp file. Can I minimize this easily? I am a screenreader (jaws) user.

Shrey Bhatt's user avatar

New contributor

Shrey Bhatt is a new contributor to this site. Take care in asking for clarification, commenting, and answering. Check out our Code of Conduct.

6

You did not provide any essential information to get help. The post lacks focus. It is not even a definitive question, in particular, because “easily” is a fuzzy concept.

2026-02-10 02:47:50 +00:00

Commented 4 hours ago

VSCode is not a compiler. You can set it up to use gcc. With gcc you'll get only one final file. Using GCC with MinGW

2026-02-10 02:54:36 +00:00

Commented 4 hours ago

So what is your actual problem with those extra files? It is quite normal for a debug build to have them. These extra files are needed for debugging, incremental linking. (You can try a Release build without debug info, and disable incremental linking).

2026-02-10 03:41:39 +00:00

Commented 3 hours ago

The .pdb file is the program database used for debugging. The .ilk file is likely for incremental linking. And so on... All those files have a purpose.

2026-02-10 04:16:48 +00:00

Commented 2 hours ago

It's not clear to me what you mean by "minimize this". That's your question? You are asking how to make something minimized?

2026-02-10 04:35:08 +00:00

Commented 2 hours ago

Read Entire Article