diff --git a/Source/cmSystemTools.cxx b/Source/cmSystemTools.cxx
index 52032f0eebc2af2166a9e0cab92c0f9a53d653a5..1bee080a2156801d8f9bc98fa68cc10104d11f14 100644
--- a/Source/cmSystemTools.cxx
+++ b/Source/cmSystemTools.cxx
@@ -973,10 +973,11 @@ void cmSystemTools::ExpandList(std::vector<std::string> const& arguments,
 }
 
 void cmSystemTools::ExpandListArgument(const std::string& arg,
-                                       std::vector<std::string>& newargs)
+                                       std::vector<std::string>& newargs,
+                                       bool emptyArgs)
 {
   // If argument is empty, it is an empty list.
-  if(arg.length() == 0)
+  if(arg.length() == 0 && !emptyArgs)
     {
     return;
     }
@@ -1027,7 +1028,7 @@ void cmSystemTools::ExpandListArgument(const std::string& arg,
         // brackets.
         if(squareNesting == 0)
           {
-          if ( newArgVec.size() )
+          if ( newArgVec.size() || emptyArgs )
             {
             // Add the last argument if the string is not empty.
             newArgVec.push_back(0);
@@ -1047,7 +1048,7 @@ void cmSystemTools::ExpandListArgument(const std::string& arg,
         } break;
       }
     }
-  if ( newArgVec.size() )
+  if ( newArgVec.size() || emptyArgs )
     {
     // Add the last argument if the string is not empty.
     newArgVec.push_back(0);
diff --git a/Source/cmSystemTools.h b/Source/cmSystemTools.h
index 6c5be9908a515c212dd52fde817da9a266e4ffd5..a07a7b88073c472841788b0a2c2abb01d602ee90 100644
--- a/Source/cmSystemTools.h
+++ b/Source/cmSystemTools.h
@@ -39,7 +39,8 @@ public:
   static void ExpandList(std::vector<std::string> const& argsIn,
                          std::vector<std::string>& argsOut);
   static void ExpandListArgument(const std::string& arg,
-                                 std::vector<std::string>& argsOut);
+                                 std::vector<std::string>& argsOut,
+                                 bool emptyArgs=false);
 
   /**
    * Look for and replace registry values in a string