aboutsummaryrefslogtreecommitdiff
path: root/src/builder.cpp
diff options
context:
space:
mode:
authorMike Buland <eichlan@xagasoft.com>2006-08-02 05:52:41 +0000
committerMike Buland <eichlan@xagasoft.com>2006-08-02 05:52:41 +0000
commit53526ddd639aaed8ce90486b02ba621e02f6b505 (patch)
treea5e4ede5a47043b5934e17d6c4ddd7d19e0805a5 /src/builder.cpp
parent46a3cfdd7b2a77a308a6ac3fbca3b675c4f44fe7 (diff)
downloadbuild-53526ddd639aaed8ce90486b02ba621e02f6b505.tar.gz
build-53526ddd639aaed8ce90486b02ba621e02f6b505.tar.bz2
build-53526ddd639aaed8ce90486b02ba621e02f6b505.tar.xz
build-53526ddd639aaed8ce90486b02ba621e02f6b505.zip
Some minor updates to the functionality
Diffstat (limited to '')
-rw-r--r--src/builder.cpp14
1 files changed, 8 insertions, 6 deletions
diff --git a/src/builder.cpp b/src/builder.cpp
index 6bde1b4..d448243 100644
--- a/src/builder.cpp
+++ b/src/builder.cpp
@@ -44,8 +44,6 @@ void Builder::build( const char *sAct )
44 pAct = mAction[sAct]; 44 pAct = mAction[sAct];
45 } 45 }
46 46
47 printf("--- %s ---\n", pAct->getName() );
48
49 pAct->execute( *this ); 47 pAct->execute( *this );
50} 48}
51 49
@@ -183,13 +181,15 @@ void Builder::varSet( const char *sName, const char *sValue )
183{ 181{
184 checkVar( sContext, sName ); 182 checkVar( sContext, sName );
185 183
184 std::string newVal = varRepl( sValue, sContext, NULL );
185
186 if( sContext[0] == '\0' ) 186 if( sContext[0] == '\0' )
187 { 187 {
188 mVar[sName] = sValue; 188 mVar[sName] = newVal;
189 } 189 }
190 else 190 else
191 { 191 {
192 mContVar[sContext.getString()][sName] = sValue; 192 mContVar[sContext.getString()][sName] = newVal;
193 } 193 }
194} 194}
195 195
@@ -197,18 +197,20 @@ void Builder::varAddSet( const char *sName, const char *sValue )
197{ 197{
198 checkVar( sContext, sName ); 198 checkVar( sContext, sName );
199 199
200 std::string newVal = varRepl( sValue, sContext, NULL );
201
200 if( sContext[0] == '\0' ) 202 if( sContext[0] == '\0' )
201 { 203 {
202 std::string s = mVar[sName]; 204 std::string s = mVar[sName];
203 s += " "; 205 s += " ";
204 s += sValue; 206 s += newVal;
205 mVar[sName] = s; 207 mVar[sName] = s;
206 } 208 }
207 else 209 else
208 { 210 {
209 std::string s = mContVar[sContext.getString()][sName]; 211 std::string s = mContVar[sContext.getString()][sName];
210 s += " "; 212 s += " ";
211 s += sValue; 213 s += newVal;
212 mContVar[sContext.getString()][sName] = s; 214 mContVar[sContext.getString()][sName] = s;
213 } 215 }
214} 216}