Commit 44a7cd55 authored by Ken Martin's avatar Ken Martin

removed all source lists from the system and made them vectors. Also appended...

removed all source lists from the system and made them vectors. Also appended _CMAKE_PATH to the end of the automatic cache entries for executables and libraries. Odds of all these changes working are slim but cmake builds and passes all its tests. VTK40 starts building
parent a1a05a5f
......@@ -26,6 +26,7 @@ bool cmAuxSourceDirectoryCommand::InitialPass(std::vector<std::string> const& ar
return false;
}
std::string sourceListValue;
std::string templateDirectory = args[0];
m_Makefile->AddExtraDirectory(templateDirectory.c_str());
std::string tdir = m_Makefile->GetCurrentDirectory();
......@@ -61,11 +62,17 @@ bool cmAuxSourceDirectoryCommand::InitialPass(std::vector<std::string> const& ar
m_Makefile->GetSourceExtensions(),
m_Makefile->GetHeaderExtensions());
cmfile.SetIsAnAbstractClass(false);
m_Makefile->AddSource(cmfile,args[1].c_str());
m_Makefile->AddSource(cmfile);
if (sourceListValue.size() > 0)
{
sourceListValue += ";";
}
sourceListValue += cmfile.GetSourceName();
}
}
}
}
m_Makefile->AddDefinition(args[1].c_str(), sourceListValue.c_str());
return true;
}
......@@ -266,7 +266,7 @@ bool cmCreateTestSourceList::InitialPass(std::vector<std::string> const& argsIn)
"cxx",
false);
m_Makefile->AddSource(cfile);
sourceListValue = args[1].c_str();
sourceListValue = args[1] + ".cxx";
for(i = testsBegin; i != tests.end(); ++i)
{
......
......@@ -252,8 +252,9 @@ void cmDSWWriter::WriteProject(std::ostream& fout,
if(j->first != dspname)
{
// is the library part of this DSW ? If so add dependency
std::string libPath = j->first + "_CMAKE_PATH";
const char* cacheValue
= m_Makefile->GetDefinition(j->first.c_str());
= m_Makefile->GetDefinition(libPath.c_str());
if(cacheValue)
{
fout << "Begin Project Dependency\n";
......
......@@ -48,39 +48,33 @@ bool cmFLTKWrapUICommand::InitialPass(std::vector<std::string> const& args)
m_Target = args[0]; // Target that will use the generated files
m_GUISourceList = args[1]; // Source List of the GUI source files
cmMakefile::SourceMap &GUISources = m_Makefile->GetSources();
std::vector<std::string> newArgs;
m_Makefile->ExpandSourceListArguments(args,newArgs, 1);
// get the list of GUI files from which .cxx and .h will be generated
cmMakefile::SourceMap::iterator l = GUISources.find( m_GUISourceList );
if (l == GUISources.end())
{
this->SetError("bad source list passed to FLTKWrapUICommand");
return false;
}
std::string outputDirectory = m_Makefile->GetCurrentOutputDirectory();
// Some of the generated files are *.h so the directory "GUI"
// where they are created have to be added to the include path
m_Makefile->AddIncludeDirectory( outputDirectory.c_str() );
for(std::vector<cmSourceFile*>::iterator i = l->second.begin();
i != l->second.end(); i++)
for(std::vector<std::string>::iterator i = (newArgs.begin() + 1);
i != newArgs.end(); i++)
{
cmSourceFile &curr = *(*i);
cmSourceFile *curr = m_Makefile->GetSource(i->c_str());
// if we should use the source GUI
// to generate .cxx and .h files
if (!curr.GetWrapExclude())
if (!curr || !curr->GetWrapExclude())
{
cmSourceFile header_file;
cmSourceFile source_file;
std::string srcName = cmSystemTools::GetFilenameWithoutExtension(*i);
const bool headerFileOnly = true;
header_file.SetName(curr.GetSourceName().c_str(),
header_file.SetName(srcName.c_str(),
outputDirectory.c_str(), "h",headerFileOnly);
source_file.SetName(curr.GetSourceName().c_str(),
source_file.SetName(srcName.c_str(),
outputDirectory.c_str(), "cxx",!headerFileOnly);
std::string origname = cdir + "/" + curr.GetSourceName() + "." +
curr.GetSourceExtension();
std::string origname = cdir + "/" + *i;
std::string hname = header_file.GetFullPath();
std::string cxxname = source_file.GetFullPath();
m_WrapUserInterface.push_back(origname);
......@@ -90,7 +84,6 @@ bool cmFLTKWrapUICommand::InitialPass(std::vector<std::string> const& args)
header_file.GetDepends().push_back(origname);
m_GeneratedHeadersClasses.push_back(header_file);
m_GeneratedSourcesClasses.push_back(source_file);
}
}
......
......@@ -54,7 +54,7 @@ bool cmGetFilenameComponentCommand::InitialPass(std::vector<std::string> const&
}
else if (args[2] == "NAME_WE")
{
result = cmSystemTools::GetFilenameNameWithoutExtension(filename);
result = cmSystemTools::GetFilenameWithoutExtension(filename);
}
else
{
......
......@@ -58,7 +58,7 @@ bool cmITKWrapTclCommand::InitialPass(std::vector<std::string> const& argsIn)
bool cmITKWrapTclCommand::CreateCableRule(const char* configFile)
{
std::string tclFile =
cmSystemTools::GetFilenameNameWithoutExtension(configFile);
cmSystemTools::GetFilenameWithoutExtension(configFile);
tclFile += "_tcl";
std::string inFile = m_Makefile->GetCurrentDirectory();
......@@ -138,8 +138,10 @@ bool cmITKWrapTclCommand::CreateCableRule(const char* configFile)
// Set dependency hints.
file.GetDepends().push_back(inFile.c_str());
file.GetDepends().push_back("CableTclFacility/ctCalls.h");
m_Makefile->AddSource(file, m_TargetName.c_str());
m_Makefile->AddSource(file);
std::string srcname = file.GetSourceName() + ".cxx";
m_Makefile->AddDefinition(m_TargetName.c_str(),
srcname.c_str());
return true;
}
......
......@@ -26,7 +26,7 @@ bool cmInstallFilesCommand::InitialPass(std::vector<std::string> const& argsIn)
return false;
}
std::vector<std::string> args;
cmSystemTools::ExpandListArguments(argsIn, args);
m_Makefile->ExpandSourceListArguments(argsIn, args, 2);
// Create an INSTALL_FILES target specifically for this path.
m_TargetName = "INSTALL_FILES_"+args[0];
......@@ -63,26 +63,9 @@ void cmInstallFilesCommand::FinalPass()
{
// replace any variables
std::string temps = *s;
// look for a srclist
if (m_Makefile->GetSources().find(temps) != m_Makefile->GetSources().end())
{
const std::vector<cmSourceFile*> &clsList =
m_Makefile->GetSources().find(temps)->second;
std::vector<cmSourceFile*>::const_iterator c = clsList.begin();
for (; c != clsList.end(); ++c)
{
testf = (*c)->GetSourceName() + ext;
// add to the result
targetSourceLists.push_back(testf);
}
}
// if one wasn't found then assume it is a single class
else
{
testf = temps + ext;
// add to the result
targetSourceLists.push_back(testf);
}
testf = temps + ext;
// add to the result
targetSourceLists.push_back(testf);
}
}
else // reg exp list
......
......@@ -51,7 +51,8 @@ bool cmLinkLibrariesCommand::InitialPass(std::vector<std::string> const& argsIn)
const char* ldir = m_Makefile->GetDefinition("LIBRARY_OUTPUT_PATH");
if (cmSystemTools::IsOff(ldir))
{
const char* dir = m_Makefile->GetDefinition(i->c_str());
std::string libPath = *i + "_CMAKE_PATH";
const char* dir = m_Makefile->GetDefinition(libPath.c_str());
if( dir )
{
m_Makefile->AddLinkDirectory( dir );
......
......@@ -407,8 +407,9 @@ void cmMSDotNETGenerator::WriteProjectDepends(std::ostream& fout,
if(j->first != dspname)
{
// is the library part of this SLN ? If so add dependency
std::string libPath = j->first + "_CMAKE_PATH";
const char* cacheValue
= m_Makefile->GetDefinition(j->first.c_str());
= m_Makefile->GetDefinition(libPath.c_str());
if(cacheValue)
{
fout << "\t\t{" << this->CreateGUID(dspname) << "}." << depcount << " = {"
......
......@@ -143,39 +143,35 @@ void cmMakeDepend::GenerateDependInformation(cmDependInformation* info)
if(!found)
{
// Try to find the file amongst the sources
cmMakefile::SourceMap srcmap = m_Makefile->GetSources();
cmMakefile::SourceMap::iterator l;
for (l= srcmap.begin() ; l!=srcmap.end() ; l++)
cmSourceFile *srcFile =
m_Makefile->GetSource(cmSystemTools::GetFilenameWithoutExtension(path).c_str());
if (srcFile)
{
for(std::vector<cmSourceFile*>::iterator i = l->second.begin();
i != l->second.end(); i++)
if (srcFile->GetFullPath() == path)
{
if ((*i)->GetFullPath() == path)
{
found=true;
}
else
{
//try to guess which include path to use
for(std::vector<std::string>::iterator t =
found=true;
}
else
{
//try to guess which include path to use
for(std::vector<std::string>::iterator t =
m_IncludeDirectories.begin();
t != m_IncludeDirectories.end(); ++t)
t != m_IncludeDirectories.end(); ++t)
{
std::string incpath = *t;
incpath = incpath + "/";
incpath = incpath + path;
if (srcFile->GetFullPath() == incpath)
{
std::string incpath = *t;
incpath = incpath + "/";
incpath = incpath + path;
if ((*i)->GetFullPath() == incpath)
{
// set the path to the guessed path
info->m_FullPath = incpath;
found=true;
}
// set the path to the guessed path
info->m_FullPath = incpath;
found=true;
}
}
}
}
}
if(!found)
{
// Couldn't find any dependency information.
......
......@@ -154,16 +154,6 @@ void cmMakefile::Print() const
{
// print the class lists
std::cout << "classes:\n";
for(SourceMap::const_iterator l = m_Sources.begin();
l != m_Sources.end(); l++)
{
std::cout << " Class list named: " << l->first << std::endl;
for(std::vector<cmSourceFile*>::const_iterator i = l->second.begin();
i != l->second.end(); i++)
{
(*i)->Print();
}
}
std::cout << " m_Targets: ";
for (cmTargets::const_iterator l = m_Targets.begin();
......@@ -364,27 +354,6 @@ bool cmMakefile::ReadListFile(const char* filename, const char* external)
return true;
}
cmSourceFile *cmMakefile::GetSource(const char *srclist, const char *cname)
{
SourceMap::iterator sl = m_Sources.find(srclist);
// find the src list
if (sl == m_Sources.end())
{
return 0;
}
// find the class
for (std::vector<cmSourceFile*>::iterator i = sl->second.begin();
i != sl->second.end(); ++i)
{
if ((*i)->GetSourceName() == cname)
{
return *i;
}
}
return 0;
}
void cmMakefile::AddCommand(cmCommand* wg)
{
......@@ -444,26 +413,6 @@ void cmMakefile::GenerateMakefile()
}
void cmMakefile::AddSource(cmSourceFile& cmfile, const char *srclist)
{
m_Sources[srclist].push_back(this->AddSource(cmfile));
}
void cmMakefile::RemoveSource(cmSourceFile& cmfile, const char *srclist)
{
std::vector<cmSourceFile*> &maplist = m_Sources[srclist];
for( std::vector<cmSourceFile*>::iterator f = maplist.begin();
f != maplist.end(); ++f)
{
if((*f)->GetSourceName() == cmfile.GetSourceName())
{
maplist.erase(f);
return;
}
}
}
void cmMakefile::AddCustomCommand(const char* source,
const char* command,
const std::vector<std::string>& commandArgs,
......@@ -711,8 +660,10 @@ void cmMakefile::AddLibrary(const char* lname, int shared,
m_Targets.insert(cmTargets::value_type(lname,target));
// Add an entry into the cache
std::string libPath = lname;
libPath += "_CMAKE_PATH";
cmCacheManager::GetInstance()->
AddCacheEntry(lname,
AddCacheEntry(libPath.c_str(),
this->GetCurrentOutputDirectory(),
"Path to a library", cmCacheManager::INTERNAL);
......@@ -778,8 +729,10 @@ void cmMakefile::AddExecutable(const char *exeName,
// Add an entry into the cache
std::string exePath = exeName;
exePath += "_CMAKE_PATH";
cmCacheManager::GetInstance()->
AddCacheEntry(exeName,
AddCacheEntry(exePath.c_str(),
this->GetCurrentOutputDirectory(),
"Path to an executable", cmCacheManager::INTERNAL);
}
......@@ -1368,7 +1321,7 @@ cmData* cmMakefile::LookupData(const char* name) const
}
}
cmSourceFile* cmMakefile::GetSource(const char* sourceName)
cmSourceFile* cmMakefile::GetSource(const char* sourceName) const
{
std::string s = sourceName;
std::string ext;
......@@ -1378,7 +1331,7 @@ cmSourceFile* cmMakefile::GetSource(const char* sourceName)
ext = s.substr(pos+1, s.size() - pos-1);
s = s.substr(0, pos);
}
for(std::vector<cmSourceFile*>::iterator i = m_SourceFiles.begin();
for(std::vector<cmSourceFile*>::const_iterator i = m_SourceFiles.begin();
i != m_SourceFiles.end(); ++i)
{
if((*i)->GetSourceName() == s
......@@ -1411,3 +1364,34 @@ void cmMakefile::EnableLanguage(const char* lang)
m_MakefileGenerator->EnableLanguage(lang);
}
void cmMakefile::ExpandSourceListArguments(
std::vector<std::string> const& arguments,
std::vector<std::string>& newargs, int start)
{
// first figure out if we need to handle version 1.2 style source lists
int oldVersion = 1;
const char* versionValue
= this->GetDefinition("CMAKE_MINIMUM_REQUIRED_VERSION");
if (versionValue && atof(versionValue) > 1.2)
{
oldVersion = 0;
}
// now expand the args
std::vector<std::string> tmpArgs;
int i;
for(i = 0; i < arguments.size(); ++i)
{
// is the arg defined ?, if so use the def
const char *def = this->GetDefinition(arguments[i].c_str());
if (def && oldVersion && i >= start)
{
tmpArgs.push_back(def);
}
else
{
tmpArgs.push_back(arguments[i]);
}
}
cmSystemTools::ExpandListArguments(tmpArgs, newargs);
}
......@@ -218,12 +218,12 @@ public:
/**
* Add a class/source file to the build.
*/
void AddSource(cmSourceFile& ,const char *srcListName);
//void AddSource(cmSourceFile& ,const char *srcListName);
/**
* Remove a class/source file from the build.
*/
void RemoveSource(cmSourceFile& ,const char *srcListName);
//void RemoveSource(cmSourceFile& ,const char *srcListName);
/**
* Add a source group for consideration when adding a new source.
......@@ -375,18 +375,21 @@ public:
return m_IncludeDirectories;
}
/**
* Return a list of source files in this makefile.
/** Expand out any arguements in the vector that have ; separated
* strings into multiple arguements. A new vector is created
* containing the expanded versions of all arguments in argsIn.
* This method differes from the one in cmSystemTools in that if
* the CmakeLists file is version 1.2 or earlier it will check for
* source lists being used without ${} around them
*/
typedef std::map<cmStdString,std::vector<cmSourceFile*> > SourceMap;
const SourceMap &GetSources() const {return m_Sources;}
SourceMap &GetSources() {return m_Sources;}
cmSourceFile* GetSource(const char *srclist, const char *sourceName);
void ExpandSourceListArguments(std::vector<std::string> const& argsIn,
std::vector<std::string>& argsOut,
int startArgumentIndex);
/** Get a cmSourceFile pointer for a given source name, if the name is
* not found, then a null pointer is returned.
*/
cmSourceFile* GetSource(const char* sourceName);
cmSourceFile* GetSource(const char* sourceName) const;
///! Add a new cmSourceFile to the list of sources for this makefile.
cmSourceFile* AddSource(cmSourceFile const&);
......@@ -524,9 +527,7 @@ protected:
// libraries, classes, and executables
cmTargets m_Targets;
SourceMap m_Sources;
std::vector<cmSourceFile*> m_SourceFiles;
std::vector<std::string> m_SubDirectories; // list of sub directories
struct StringSet : public std::set<cmStdString>
......
......@@ -25,7 +25,7 @@ bool cmQTWrapCPPCommand::InitialPass(std::vector<std::string> const& argsIn)
return false;
}
std::vector<std::string> args;
cmSystemTools::ExpandListArguments(argsIn, args);
m_Makefile->ExpandSourceListArguments(argsIn, args, 2);
// Now check and see if the value has been stored in the cache
// already, if so use that value and don't look for the program
......@@ -50,37 +50,28 @@ bool cmQTWrapCPPCommand::InitialPass(std::vector<std::string> const& argsIn)
m_SourceList = args[1];
// get the list of classes for this library
cmMakefile::SourceMap &Classes = m_Makefile->GetSources();
for(std::vector<std::string>::const_iterator j = (args.begin() + 2);
for(std::vector<std::string>::iterator j = (args.begin() + 2);
j != args.end(); ++j)
{
cmMakefile::SourceMap::iterator l = Classes.find(*j);
if (l == Classes.end())
{
this->SetError("bad source list passed to QTWrapCPPCommand");
return false;
}
for(std::vector<cmSourceFile*>::iterator i = l->second.begin();
i != l->second.end(); i++)
cmSourceFile *curr = m_Makefile->GetSource(j->c_str());
// if we should wrap the class
if (!curr || !curr->GetWrapExclude())
{
cmSourceFile &curr = *(*i);
// if we should wrap the class
if (!curr.GetWrapExclude())
cmSourceFile file;
if (curr)
{
cmSourceFile file;
file.SetIsAnAbstractClass(curr.IsAnAbstractClass());
std::string newName = "moc_" + curr.GetSourceName();
file.SetName(newName.c_str(), m_Makefile->GetCurrentOutputDirectory(),
"cxx",false);
std::string hname = cdir + "/" + curr.GetSourceName() + "." +
curr.GetSourceExtension();
m_WrapHeaders.push_back(hname);
// add starting depends
file.GetDepends().push_back(hname);
m_WrapClasses.push_back(file);
file.SetIsAnAbstractClass(curr->IsAnAbstractClass());
}
std::string srcName = cmSystemTools::GetFilenameWithoutExtension(*j);
std::string newName = "moc_" + srcName;
file.SetName(newName.c_str(), m_Makefile->GetCurrentOutputDirectory(),
"cxx",false);
std::string hname = cdir + "/" + *j;
m_WrapHeaders.push_back(hname);
// add starting depends
file.GetDepends().push_back(hname);
m_WrapClasses.push_back(file);
}
}
......@@ -94,7 +85,14 @@ void cmQTWrapCPPCommand::FinalPass()
size_t lastClass = m_WrapClasses.size();
std::vector<std::string> depends;
std::string moc_exe = "${QT_MOC_EXE}";
std::string sourceListValue;
// was the list already populated
const char *def = m_Makefile->GetDefinition(m_SourceList.c_str());
if (def)
{
sourceListValue = def;
}
// wrap all the .h files
depends.push_back(moc_exe);
......@@ -110,7 +108,12 @@ void cmQTWrapCPPCommand::FinalPass()
for(size_t classNum = 0; classNum < lastClass; classNum++)
{
// Add output to build list
m_Makefile->AddSource(m_WrapClasses[classNum],m_SourceList.c_str());
m_Makefile->AddSource(m_WrapClasses[classNum]);
if (sourceListValue.size() > 0)
{
sourceListValue += ";";
}
sourceListValue += m_WrapClasses[classNum].GetSourceName() + ".cxx";
// set up moc command
std::string res = m_Makefile->GetCurrentOutputDirectory();
......@@ -131,7 +134,7 @@ void cmQTWrapCPPCommand::FinalPass()
}
m_Makefile->AddDefinition("GENERATED_QT_FILES",moc_list.c_str());
m_Makefile->AddDefinition(m_SourceList.c_str(), sourceListValue.c_str());
}
......
......@@ -25,7 +25,7 @@ bool cmQTWrapUICommand::InitialPass(std::vector<std::string> const& argsIn)
return false;
}
std::vector<std::string> args;
cmSystemTools::ExpandListArguments(argsIn, args);
m_Makefile->ExpandSourceListArguments(argsIn, args, 3);
// Now check and see if the value has been stored in the cache
// already, if so use that value and don't look for the program
......@@ -49,63 +49,66 @@ bool cmQTWrapUICommand::InitialPass(std::vector<std::string> const& argsIn)
m_LibraryName = args[0];
m_HeaderList = args[1];
m_SourceList = args[2];
std::string sourceListValue;
const char *def = m_Makefile->GetDefinition(m_SourceList.c_str());
if (def)
{
sourceListValue = def;
}
// get the list of classes for this library
cmMakefile::SourceMap &Classes = m_Makefile->GetSources();
for(std::vector<std::string>::const_iterator j = (args.begin() + 3);
for(std::vector<std::string>::iterator j = (args.begin() + 3);
j != args.end(); ++j)
{
cmMakefile::SourceMap::iterator l = Classes.find(*j);
if (l == Classes.end())
{
this->SetError("bad source list passed to QTWrapUICommand");
return false;
}
for(std::vector<cmSourceFile*>::iterator i = l->second.begin();
i != l->second.end(); i++)
{
cmSourceFile *curr = m_Makefile->GetSource(j->c_str());
// if we should wrap the class
if (!curr || !curr->GetWrapExclude())
{
cmSourceFile &curr = *(*i);
// if we should wrap the class
if (!curr.GetWrapExclude())
cmSourceFile header_file;
cmSourceFile source_file;
cmSourceFile moc_file;
std::string srcName = cmSystemTools::GetFilenameWithoutExtension(*j);
header_file.SetName(srcName.c_str(),
m_Makefile->GetCurrentOutputDirectory(),
"h",false);
source_file.SetName(srcName.c_str(),
m_Makefile->GetCurrentOutputDirectory(),
"cxx",false);
std::string moc_source_name("moc_");
moc_source_name = moc_source_name + srcName;
moc_file.SetName(moc_source_name.c_str(),
m_Makefile->GetCurrentOutputDirectory(),
"cxx",false);
std::string origname = cdir + "/" + *j;
std::string hname = header_file.GetFullPath();
m_WrapUserInterface.push_back(origname);
// add starting depends
moc_file.GetDepends().push_back(hname);
source_file.GetDepends().push_back(hname);
source_file.GetDepends().push_back(origname);
header_file.GetDepends().push_back(origname);
m_WrapHeadersClasses.push_back(header_file);
m_WrapSourcesClasses.push_back(source_file);
m_WrapMocClasses.push_back(moc_file);
m_Makefile->AddSource(header_file);
m_Makefile->AddSource(source_file);
m_Makefile->AddSource(moc_file);
// create the list of sources
if (sourceListValue.size() > 0)
{
cmSourceFile header_file;
cmSourceFile source_file;
cmSourceFile moc_file;
header_file.SetName(curr.GetSourceName().c_str(),
m_Makefile->GetCurrentOutputDirectory(),
"h",false);
source_file.SetName(curr.GetSourceName().c_str(),
m_Makefile->GetCurrentOutputDirectory(),
"cxx",false);
std::string moc_source_name("moc_");
moc_source_name = moc_source_name + curr.GetSourceName().c_str();
moc_file.SetName(moc_source_name.c_str(),
m_Makefile->GetCurrentOutputDirectory(),
"cxx",false);
std::string origname = cdir + "/" + curr.GetSourceName() + "." +
curr.GetSourceExtension();
std::string hname = header_file.GetFullPath();
m_WrapUserInterface.push_back(origname);
// add starting depends
moc_file.GetDepends().push_back(hname);
source_file.GetDepends().push_back(hname);
source_file.GetDepends().push_back(origname);
header_file.GetDepends().push_back(origname);
m_WrapHeadersClasses.push_back(header_file);
m_WrapSourcesClasses.push_back(source_file);
m_WrapMocClasses.push_back(moc_file);
m_Makefile->AddSource(header_file,
m_HeaderList.c_str());
m_Makefile->AddSource(source_file,
m_SourceList.c_str());
m_Makefile->AddSource(moc_file,
m_SourceList.c_str());
sourceListValue += ";";
}
sourceListValue += header_file.GetSourceName() + ".h";
sourceListValue += ";";
sourceListValue += source_file.GetSourceName() + ".cxx";
sourceListValue += ";";
sourceListValue += moc_file.GetSourceName() + ".cxx";
}
}
m_Makefile->AddDefinition(m_SourceList.c_str(), sourceListValue.c_str());
return true;
}
......
......@@ -34,8 +34,16 @@ bool cmSourceFilesCommand::InitialPass(std::vector<std::string> const& argsIn)
}
std::vector<std::string> args;
cmSystemTools::ExpandListArguments(argsIn, args);
std::string sourceListValue;
// was the list already populated
std::string name = args[0];