added option initialization of memcached, so we can pass more advanced configuration options. added check for backwards compatibility with old libmemcached