Using thread variables on different versions of Solaris software requires different options on the command line.
On Solaris 8 software, objects that use __thread must be compiled with -mt and must be linked with -mt -L/usr/lib/lwp -R/usr/lib/lwp.
On Solaris 9 software, objects that use __thread must be compiled and linked with -mt.