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.