remove pthread dependency and using libuv