Mofications to work under GCC/pthreads on Linux.