i recently got Oracle Solaris on my VM to test some code on it, i was unable to install gcc since i dont really know how, i googled alot but all info is about oracle compile
I had the same problem and 'pkg install gcc-3' worked for me.