sbsv2/raptor/python/raptor_make.py
branchfix
changeset 176 b601167a8189
parent 134 2648751b64b4
child 191 3bfc260b6d61
--- a/sbsv2/raptor/python/raptor_make.py	Tue Jan 26 14:25:28 2010 +0000
+++ b/sbsv2/raptor/python/raptor_make.py	Thu Jan 28 16:06:25 2010 +0000
@@ -497,12 +497,22 @@
 						universal_newlines=True, env=makeenv)
 				stream = p.stdout
 
-
+				inRecipe = False
 				line = " "
 				while line:
 					line = stream.readline()
-					self.raptor.out.write(line)
-
+					
+					if line.startswith("<recipe"):
+						inRecipe = True
+					elif line.startswith("</recipe"):
+						inRecipe = False
+					
+					# unless we are inside a "recipe", any line not starting
+					# with "<" is free text that must be escaped.
+					if inRecipe or line.startswith("<"):
+						self.raptor.out.write(line)
+					else:
+						self.raptor.out.write(escape(line))
 
 				# should be done now
 				returncode = p.wait()