Don't forget that you *must* also compile with -pthreads and link with -pthreads, without this you won't have a thread safe std lib, and probably other problems as well (see gcc -dumpspecs for a full list of what -pthreads does on Solaris). The issue we're grappling with is that when you specify -pthreads in debug mode you will get an unresolved external from std::runtime_error::runtime_error, the fix is to place:
#pragma implementation "stdexcept"
in one of your source files (this isn't needed for release code though). We should probably get this fix rolled into the thread lib itself at some stage.
Intriguing, as gcc-3.0.3 doesn't have a -pthread argument. I believe you specify the threading model with a configure argument when building gcc now (although I just grabbed pre-built binaries, so I may be wrong). - Dale.