Sublime Forum

Using Sublime Text 2 with C++ / OpenGL

#1

By default, Sublime Forum is configured to compile using C++. However, I’m not sure how to use it with OpenGL. Any help is appreciated!

0 Likes

#2

The way I did it was to set up CMake to generate a Make build system then used custom key bindings to call different variants of a custom build system in Sublime that would first of all call CMake to generate the Make build system, then call Make to build the program itself.

So for example:
ctrl + b runs CMake
ctrl + shift + b builds the program with the generated Make files
crtl + shift + r runs the newly built program

CMake was the easiest way for me to do it since Sublime is obviously not an IDE so it doesn’t compile/link all of the files in your project together for you.

If you need more of an explanation let me know and I’ll try to give more detail.

0 Likes

#3

I know this is over a year old… But I would really like an explanation on how to do this. I’ve tried binding the keys myself but it isn’t quite working. I saw that you are still active so I hope you see this!

Thanks,
Brent

0 Likes