If you use SunPRO C 3.0 or later, you need to specify the commandline option ``-mt'' when compiling and linking. If you and earlier version of SunPRO C or when using gcc, you'll need to specify -D_REENTRANT on compile command lines and -lthread on the link command line. -lthread should precede -lc.