Sublime Forum

Win10: Calling GCC without it being in the %PATH%?

#1

I’d like to be able to compile a C/C++ file calling gcc from Sublime Text. There’s a good amount of “How to” in the web, all assuming that the GCC bin location is present in the environment PATH variable.

For a lot of reasons i don’t have and don’t want to have it that way: instead i’d like that ST3 could use his own path for GCC.

There’s a way to do this?

0 Likes

#2

You’d need to have a build system that either has an absolute path to your compiler, or runs some shell/script to set the PATH to what you want.

0 Likes

#3

so, i should call a .bat file that takes in input the file opened in ST3, sets the environment and the calls gcc?
Will this allow me to see the gcc output in ST3?

0 Likes