pthread: mutex synchronzation

pthread_join()
pthread_mutex_lock/unlock/trylock()

not included in this commit, the 3rd synchronzation method,
pthread_cond_init/destroy/wait/timedwait/signal/broadcast()