GCC error



I have noticed that when I try to compile code that I get an error saying that gcc cannot create executables. If I try something simple like:

gcc test.c -o test

I get the error "ld: can't locate file for: -lSystem"

If I run gcc without linking (-c) I don't get the error. I have basically come to the conclusion that I am missing a library. I have reinstalled gcc and the xcode tools serveral times and it has not fixed the problem. Any suggestions would be greatly appreciated.


Shop Amazon

Shop for your Apple, Mac, iPhone and other computer products on Amazon.
We are a participant in the Amazon Services LLC Associates Program, an affiliate program designed to provide a means for us to earn fees by linking to Amazon and affiliated sites.