Made the code build on MacOSX 10.9

Prefixed the namespace std:: to wcschr and wmemchr, and uncommented a configure.ac line.