Thanks, Dave!
Here's the last lines with the error info..
/bin/rm -f nsd
gcc -pipe -L../nsthread -L../nsd -o nsd main.o libnsd.so -lnsthread -L/usr/local/lib -ltcl8.4 -ldl -lpthread -lieee -lm -lz -lgcc_s -Wl,--export-dynamic -Wl,-rpath,/usr/local/aolserver40r10/lib -Wl,-rpath,/usr/local/lib
libnsd.so: undefined reference to `pthread_kill_other_threads_np'
collect2: ld returned 1 exit status
make[1]: *** [nsd] Error 1
make[1]: Leaving directory `/usr/local/src/aolserver40r10/aolserver/nsd'
make: *** [all] Error 1