To check whether you have gcc installed type the following at a console command line:
gcc -v
If you have gcc compiler installed then it should return the version. Next you'll want to find out what directory it resides in by typing the following at the command line:
find / -name gcc
If you find the directory where gcc is located the next thing to do is add it to your $PATH variable. This can be done by editing your .bash_profile file and concatenating the absolute path to where gcc is located to the PATH variable declaration.
Notes about .bash_profile: As you might know, but I'm not sure you do by your questioning; that the period (.) in front of any file means that file is hidden unless you use the -a option of the ls command. I prefer using ls -al so that the output is in list form. Also, I'm assuming you're using Bash shell for your console.
I hope this works or at least points you in the right direction.