Parse libraries.

svn path=/branches/xmlbuildsystem/; revision=12840
This commit is contained in:
Casper Hornstrup 2005-01-05 22:36:17 +00:00
parent 91d97cbc91
commit 7d876c4d0c
8 changed files with 72 additions and 12 deletions

View file

@ -21,6 +21,8 @@ Module::~Module ()
{
for ( size_t i = 0; i < files.size(); i++ )
delete files[i];
for ( size_t i = 0; i < libraries.size(); i++ )
delete libraries[i];
}
void Module::ProcessXML ( const XMLElement& e,
@ -31,6 +33,10 @@ void Module::ProcessXML ( const XMLElement& e,
{
files.push_back ( new File ( path + "/" + e.value ) );
}
else if ( e.name == "library" && e.value.size () )
{
libraries.push_back ( new Library ( e.value ) );
}
else if ( e.name == "directory" )
{
const XMLAttribute* att = e.GetAttribute ( "name", true );
@ -50,7 +56,14 @@ ModuleType Module::GetModuleType ( const XMLAttribute& attribute )
attribute.value );
}
File::File ( const string& _name )
: name(_name)
{
}
Library::Library ( const string& _name )
: name(_name)
{
}