Link lib pthreads for Shared Memory API. Cleaned up ELIBS and EINCS in build scripts