diff --git a/SystemTools.hxx.in b/SystemTools.hxx.in
index 50a67efe51cdfbd6407d6f233d6102595fd5e9fc..69afdc19f26238171220e2ea201aee0d5279803a 100644
--- a/SystemTools.hxx.in
+++ b/SystemTools.hxx.in
@@ -126,7 +126,7 @@ public:
 
   /** Read an environment variable.  */
   static const char* GetEnv(const char* key);
-  static bool GetEnv(const char* key, std::string& result);
+  static bool GetEnv(const char* key, kwsys_std::string& result);
 
   /**
    *  Get the file extension (including ".") needed for an executable