CLion bits/stdc++.h on macOS

I have been using CLion on macOS for competitive programming for sometime now. I recently switched to sublime text because I could get bits/stdc++.h to work with it. Having to paste many includes in my CLion template really annoys me and makes the code less readable.
If anyone has had success on getting bits/stdc++ to work with CLion on macOS could you please share your approach? There was a folder I could make to get it to work with Sublime Text but I can’t find any tutorials for CLion.

make a file store in the path of c++ compiler and name it as bits/stdc++.h and store all header files in it

1 Like

Try to reinstall latest mingw… And add new setup in Settings >> Build, Execution, Deployment >> Toolchains.

NOTE - Dont modify existing one. Add new one.

Use xcode, personally it’s better than Clion.
Anyways if you want to use clion you have to manually do these steps.
First open finder. Then press shift+cmd+G.

Then copy this /Applications/ and paste it in the box. then click Go.

When you’re in v1 folder create a new folder called bits after that create a new file called stdc++.h

Then go to this page: copy the content and paste it in stdc++.h file and save it.

This will solve the problem.

you can go through it for the need

That folder doesn’t exist on my laptop, I don’t have Xcode installed…

1 Like