changing configure script to work on mac and fixing a mac build error in jsstr.cpp. clang doesn't handle c++11 well :-(