Update cursor
[m6w6/libmemcached] / libtest / has.cc
index 52e1d405b26f90a91e6f70c711c61332ba34dea0..ba4bbfc65efd6af1aa31db34f11c9b3141bfee99 100644 (file)
@@ -82,7 +82,7 @@ bool has_gearmand()
   {
     std::stringstream arg_buffer;
 
-    if (getenv("PWD"))
+    if (getenv("PWD") and strcmp(MEMCACHED_BINARY, "gearmand/gearmand") == 0)
     {
       arg_buffer << getenv("PWD");
       arg_buffer << "/";
@@ -111,6 +111,19 @@ bool has_drizzled()
   return false;
 }
 
+bool has_mysqld()
+{
+  if (HAVE_MYSQLD_BUILD)
+  {
+    if (access(MYSQLD_BINARY, X_OK) == 0)
+    {
+      return true;
+    }
+  }
+
+  return false;
+}
+
 bool has_memcached()
 {
   if (HAVE_MEMCACHED_BINARY)
@@ -135,6 +148,7 @@ bool has_memcached()
 
 bool has_memcached_sasl()
 {
+#if defined(HAVE_MEMCACHED_SASL_BINARY) && HAVE_MEMCACHED_SASL_BINARY
   if (HAVE_MEMCACHED_SASL_BINARY)
   {
     if (access(MEMCACHED_SASL_BINARY, X_OK) == 0)
@@ -142,6 +156,7 @@ bool has_memcached_sasl()
       return true;
     }
   }
+#endif
 
   return false;
 }