Catch up fix
authorIain Williamson <iain.williamson@nokia.com>
Fri, 05 Feb 2010 12:00:44 +0000
branchfix
changeset 189 af8c576529ae
parent 188 4b98f0310a8d (current diff)
parent 177 a363840a27e3 (diff)
child 190 2cca6dc0bb4b
Catch up
sbsv2/raptor/RELEASE-NOTES.txt
--- a/sbsv2/raptor/RELEASE-NOTES.txt	Fri Feb 05 11:57:11 2010 +0000
+++ b/sbsv2/raptor/RELEASE-NOTES.txt	Fri Feb 05 12:00:44 2010 +0000
@@ -1,13 +1,15 @@
 
 Release Notes for Symbian Build System v2
 
-Next version
+version 2.12.1
 
-Defect fixes:
+Defect Fixes:
 - SF Bug 1494 - sbs --what does not report Trace Compiler output
 - sbs -c winscw.tracecompiler uses wrong UID and doesn't generate traces
+- SF Bug 1519 - Raptor output files may contain unescaped left angle brackets as XML character data
 - SF Bug 1569 - excessive recompilation in incremental tracecompiler builds
 
+
 version 2.12.0
 
 New Features:
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/sbsv2/raptor/python/plugins/filter_broken.py	Fri Feb 05 12:00:44 2010 +0000
@@ -0,0 +1,48 @@
+#
+# Copyright (c) 2010 Nokia Corporation and/or its subsidiary(-ies).
+# All rights reserved.
+# This component and the accompanying materials are made available
+# under the terms of the License "Eclipse Public License v1.0"
+# which accompanies this distribution, and is available
+# at the URL "http://www.eclipse.org/legal/epl-v10.html".
+#
+# Initial Contributors:
+# Nokia Corporation - initial contribution.
+#
+# Contributors:
+#
+# Description: 
+# Example of a Filter class using the SAX parser base class
+#
+
+import filter_interface
+
+class FilterBroken(filter_interface.FilterSAX):
+	
+	def startDocument(self):
+		self.first = True
+		
+	def startElement(self, name, attributes):
+		pass
+	
+	def characters(self, char):
+		pass
+		
+	def endElement(self, name):
+		pass
+	
+	def endDocument(self):
+		pass
+	
+	def error(self, exception):
+		pass
+		
+	def fatalError(self, exception):
+		if self.first:
+			print "fatal error:", str(exception)
+			self.first = False
+		
+	def warning(self, exception):
+		pass
+	
+# the end
--- a/sbsv2/raptor/python/plugins/filter_check.py	Fri Feb 05 11:57:11 2010 +0000
+++ b/sbsv2/raptor/python/plugins/filter_check.py	Fri Feb 05 12:00:44 2010 +0000
@@ -26,4 +26,5 @@
         def __init__(self): 
 		super(filter_what.FilterWhat,self).__init__()
 		self.check = True
+		self.path_prefix_to_strip = None
 
--- a/sbsv2/raptor/python/raptor_make.py	Fri Feb 05 11:57:11 2010 +0000
+++ b/sbsv2/raptor/python/raptor_make.py	Fri Feb 05 12:00:44 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()
--- a/sbsv2/raptor/python/raptor_meta.py	Fri Feb 05 11:57:11 2010 +0000
+++ b/sbsv2/raptor/python/raptor_meta.py	Fri Feb 05 12:00:44 2010 +0000
@@ -1453,10 +1453,9 @@
 			for cap in toks[1]:
 				cap = cap.lower()
 				self.__debug("Setting  "+toks[0]+": " + cap)
-				if cap != "all":
-					if not cap.startswith("-"):
-						if not cap.startswith("+"):
-							cap = "+" + cap	
+				if not cap.startswith("-"):
+					if not cap.startswith("+"):
+						cap = "+" + cap	
 				self.capabilities.append(cap)
 		elif varname=='DEFFILE':
 			self.__defFileRoot = self.__currentMmpFile
@@ -2215,9 +2214,7 @@
 
 			if capability.startswith('-'):
 				invert = 0xffffffff
-				capability = capability[1:]
-			elif capability.startswith('+'):
-				capability = capability[1:]
+			capability = capability[1:]
 
 			if MMPRaptorBackend.supportedCapabilities.has_key(capability):
 				capabilityFlag1 = capabilityFlag1 ^ invert
--- a/sbsv2/raptor/python/raptor_version.py	Fri Feb 05 11:57:11 2010 +0000
+++ b/sbsv2/raptor/python/raptor_version.py	Fri Feb 05 12:00:44 2010 +0000
@@ -1,5 +1,5 @@
 #
-# Copyright (c) 2006-2009 Nokia Corporation and/or its subsidiary(-ies).
+# Copyright (c) 2006-2010 Nokia Corporation and/or its subsidiary(-ies).
 # All rights reserved.
 # This component and the accompanying materials are made available
 # under the terms of the License "Eclipse Public License v1.0"
@@ -13,9 +13,10 @@
 #
 # Description: 
 # raptor version information module
-#
 
-version=(2,12,0,"2010-01-25","symbian build system")
+# replace CHANGESET with the Hg changeset for ANY release
+
+version=(2,12,1,"2010-01-29","symbian build system","CHANGESET")
 
 def numericversion():
 	"""Raptor version string"""
@@ -23,4 +24,4 @@
 
 def fullversion():
 	"""Raptor version string"""
-	return "%d.%d.%d [%s %s]" % version
+	return "%d.%d.%d [%s %s %s]" % version
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/sbsv2/raptor/test/smoke_suite/make_engine_errors.py	Fri Feb 05 12:00:44 2010 +0000
@@ -0,0 +1,54 @@
+#
+# Copyright (c) 2010 Nokia Corporation and/or its subsidiary(-ies).
+# All rights reserved.
+# This component and the accompanying materials are made available
+# under the terms of the License "Eclipse Public License v1.0"
+# which accompanies this distribution, and is available
+# at the URL "http://www.eclipse.org/legal/epl-v10.html".
+#
+# Initial Contributors:
+# Nokia Corporation - initial contribution.
+#
+# Contributors:
+#
+# Description: 
+#
+
+from raptor_tests import SmokeTest
+
+def run():
+	t = SmokeTest()
+	t.id = "113"
+	t.name = "make_engine_errors"
+	t.description = "Errors reported by gmake and emake should be escaped to ensure that the logs are valid XML"
+	
+	t.mustmatch_singleline = ["Circular b &lt;- a dependency",
+							  "non_existent_&amp;_needs_escaping.txt"]
+	
+	t.mustnotmatch_singleline = ["Circular b <- a dependency",
+							     "non_existent_&_needs_escaping.txt"]
+	
+	t.usebash = True
+	t.errors = 1
+	t.returncode = 1
+	base_command = "sbs -b smoke_suite/test_resources/make_engine_errors/bld.inf -f-"
+	
+	t.id = "113a"
+	t.name = "gmake_engine_errors"
+	t.command = base_command + " -e make"
+	t.run()
+
+	t.id = "113b"
+	t.name = "emake_engine_errors"
+	t.command = base_command + " -e emake"
+	t.run()
+	
+	t.id = "113c"
+	t.name = "emake_engine_errors_with_merged_streams"
+	t.command = base_command + " -e emake --mo=--emake-mergestreams=1"
+	t.run()
+		
+	t.id = "113"
+	t.name = "make_engine_errors"
+	t.print_result()
+	return t
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/sbsv2/raptor/test/smoke_suite/test_resources/make_engine_errors/bld.inf	Fri Feb 05 12:00:44 2010 +0000
@@ -0,0 +1,9 @@
+
+PRJ_EXPORTS
+with_make_errors.flm /epoc32/tools/makefile_templates/tools/with_make_errors.flm
+with_make_errors.xml /epoc32/tools/makefile_templates/tools/with_make_errors.xml
+
+PRJ_EXTENSIONS
+start extension tools/with_make_errors
+end
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/sbsv2/raptor/test/smoke_suite/test_resources/make_engine_errors/with_make_errors.flm	Fri Feb 05 12:00:44 2010 +0000
@@ -0,0 +1,10 @@
+
+ALL:: a b c
+
+a: b
+b: a
+
+c: non_existent_&_needs_escaping.txt
+
+$(call raptor_phony_recipe,name,ALL,,echo "this FLM is rubbish")
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/sbsv2/raptor/test/smoke_suite/test_resources/make_engine_errors/with_make_errors.xml	Fri Feb 05 12:00:44 2010 +0000
@@ -0,0 +1,7 @@
+<?xml version="1.0" encoding="ISO-8859-1" ?> 
+<build xmlns="http://symbian.com/xml/build" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://symbian.com/xml/build build/2_0.xsd"> 
+
+<interface name="tools.with_make_errors" flm="with_make_errors.flm">
+</interface>
+
+</build>
--- a/sbsv2/raptor/test/smoke_suite/test_resources/simple/capability.mmp	Fri Feb 05 11:57:11 2010 +0000
+++ b/sbsv2/raptor/test/smoke_suite/test_resources/simple/capability.mmp	Fri Feb 05 12:00:44 2010 +0000
@@ -31,4 +31,4 @@
 EPOCSTACKSIZE 8192
 EPOCHEAPSIZE 0x5000 65535
 EPOCPROCESSPRIORITY low
-capability ALL -TCB -ProtServ TCB ProtServ -DRM
+capability TCB ALL -TCB -ProtServ TCB ProtServ -DRM