makmake error parser regression tests (reference data). Fix bug 9620, NPE when adding bogus path to PRJ_MMPFILES in bld.inf.
authortimkelly
Wed, 12 Aug 2009 16:32:36 -0500
changeset 430 147ef5f224c4
parent 421 7bf2b8a16445
child 431 e0f29d5da67a
makmake error parser regression tests (reference data). Fix bug 9620, NPE when adding bogus path to PRJ_MMPFILES in bld.inf.
builder/com.nokia.carbide.cdt.builder.test/data/errorpatterns/makmake.errors.input.1.txt
builder/com.nokia.carbide.cdt.builder.test/data/errorpatterns/makmake.errors.regression.1.xml
builder/com.nokia.carbide.cdt.builder.test/data/errorpatterns/regression_capture/regression.capture.xml
builder/com.nokia.carbide.cdt.builder.test/data/errorpatterns/regression_capture/your.input.errorparser.txt
builder/com.nokia.carbide.cdt.builder/src/com/nokia/carbide/cdt/builder/EpocEngineHelper.java
--- a/builder/com.nokia.carbide.cdt.builder.test/data/errorpatterns/makmake.errors.input.1.txt	Wed Aug 12 09:26:04 2009 -0500
+++ b/builder/com.nokia.carbide.cdt.builder.test/data/errorpatterns/makmake.errors.input.1.txt	Wed Aug 12 16:32:36 2009 -0500
@@ -26,5 +26,7 @@
 
 FATAL ERROR: ERROR: No Sources specified
 
-X:\SWATI_Symbian_Tools\Trace\TraceCore\group2\BLD.INF:59: #error test
+C:\runtime-EclipseApplication\GUIFooey\group\BLD.INF:23: #error test
+BLDMAKE ERROR: ERROR: cpp.exe returned non-zero exit status (8448)
+	cpp.EXE -undef -nostdinc -+  -I "C:\S60\devices\S60_5th_Edition_SDK_v1.0\epoc32\include" -I . -I "C:\runtime-EclipseApplication\GUIFooey\group\"  -I "C:\S60\devices\S60_5th_Edition_SDK_v1.0\EPOC32\include\variant" -include "C:\S60\devices\S60_5th_Edition_SDK_v1.0\EPOC32\include\variant\Symbian_OS.hrh" "C:\runtime-EclipseApplication\GUIFooey\group\BLD.INF"
 
--- a/builder/com.nokia.carbide.cdt.builder.test/data/errorpatterns/makmake.errors.regression.1.xml	Wed Aug 12 09:26:04 2009 -0500
+++ b/builder/com.nokia.carbide.cdt.builder.test/data/errorpatterns/makmake.errors.regression.1.xml	Wed Aug 12 16:32:36 2009 -0500
@@ -15,6 +15,6 @@
   <!--Error Marker at index 6-->
   <marker_info file="^EMPTY^" line_number="-1" message="ERROR: No Sources specified" severity="3" variable_name="^EMPTY^" external_path_string="^EMPTY^" />
   <!--Error Marker at index 7-->
-  <marker_info file="^EMPTY^" line_number="59" message="X:\SWATI_Symbian_Tools\Trace\TraceCore\group2\BLD.INF #error test" severity="2" variable_name="^EMPTY^" external_path_string="X:/SWATI_Symbian_Tools/Trace/TraceCore/group2/BLD.INF" />
+  <marker_info file="^EMPTY^" line_number="23" message="#error test" severity="2" variable_name="^EMPTY^" external_path_string="C:/runtime-EclipseApplication/GUIFooey/group/BLD.INF" />
 </root>
 
--- a/builder/com.nokia.carbide.cdt.builder.test/data/errorpatterns/regression_capture/regression.capture.xml	Wed Aug 12 09:26:04 2009 -0500
+++ b/builder/com.nokia.carbide.cdt.builder.test/data/errorpatterns/regression_capture/regression.capture.xml	Wed Aug 12 16:32:36 2009 -0500
@@ -1,4 +1,20 @@
+<?xml version="1.0" encoding="UTF-8"?>
 <root>
-<!--Error Marker at index 0-->
-<marker_info external_path_string="^EMPTY^" file="^EMPTY^" line_number="-1" message="filePath(lineNum) : errStr" severity="3" variable_name="^EMPTY^"/>
+  <!--Error Marker at index 0-->
+  <marker_info file="^EMPTY^" line_number="2" message="Unrecognised Keyword &quot;TARGE&quot;[\APPS\Nokia\DDB21Nightly\workspace\ListBox\group\LISTBOX.MMP]" severity="1" variable_name="^EMPTY^" external_path_string="/APPS/Nokia/DDB21Nightly/workspace/ListBox/group/LISTBOX.MMP" />
+  <!--Error Marker at index 1-->
+  <marker_info file="^EMPTY^" line_number="-1" message="ERROR: No Target specified" severity="3" variable_name="^EMPTY^" external_path_string="^EMPTY^" />
+  <!--Error Marker at index 2-->
+  <marker_info file="^EMPTY^" line_number="11" message="SOURCEPATH &quot;\APPS\Nokia\DDB21Nightly\workspace\ListBox\datx\&quot; not found[\APPS\Nokia\DDB21Nightly\workspace\ListBox\group\LISTBOX.MMP]" severity="1" variable_name="^EMPTY^" external_path_string="/APPS/Nokia/DDB21Nightly/workspace/ListBox/group/LISTBOX.MMP" />
+  <!--Error Marker at index 3-->
+  <marker_info file="^EMPTY^" line_number="6" message="Stack size doesn't fit expected number format[\APPS\Nokia\DDB21Nightly\workspace\ListBox\group\LISTBOX.MMP]" severity="3" variable_name="^EMPTY^" external_path_string="/APPS/Nokia/DDB21Nightly/workspace/ListBox/group/LISTBOX.MMP" />
+  <!--Error Marker at index 4-->
+  <marker_info file="^EMPTY^" line_number="42" message="BITMAP color depth &quot;listboxlistbox.cpp&quot; - unexpected format[\APPS\Nokia\DDB21Nightly\workspace\ListBox\group\LISTBOX.MMP]" severity="3" variable_name="^EMPTY^" external_path_string="/APPS/Nokia/DDB21Nightly/workspace/ListBox/group/LISTBOX.MMP" />
+  <!--Error Marker at index 5-->
+  <marker_info file="^EMPTY^" line_number="-1" message="ERROR: No Sources specified" severity="3" variable_name="^EMPTY^" external_path_string="^EMPTY^" />
+  <!--Error Marker at index 6-->
+  <marker_info file="^EMPTY^" line_number="-1" message="ERROR: No Sources specified" severity="3" variable_name="^EMPTY^" external_path_string="^EMPTY^" />
+  <!--Error Marker at index 7-->
+  <marker_info file="^EMPTY^" line_number="23" message="#error test" severity="2" variable_name="^EMPTY^" external_path_string="C:/runtime-EclipseApplication/GUIFooey/group/BLD.INF" />
 </root>
+
--- a/builder/com.nokia.carbide.cdt.builder.test/data/errorpatterns/regression_capture/your.input.errorparser.txt	Wed Aug 12 09:26:04 2009 -0500
+++ b/builder/com.nokia.carbide.cdt.builder.test/data/errorpatterns/regression_capture/your.input.errorparser.txt	Wed Aug 12 16:32:36 2009 -0500
@@ -1,2 +1,32 @@
-FATAL ERROR: filePath(lineNum) : errStr
+MMPFILE "\APPS\Nokia\DDB21Nightly\workspace\ListBox\group\LISTBOX.MMP"
+Died at C:\Symbian\9.3\S60_3rd_FP2_Beta\epoc32\tools\/MMP.PM line 1814.
+make: *** [MAKEFILELISTBOX] Error 255
+perl -S makmake.pl -nd -D \APPS\Nokia\DDB21Nightly\workspace\ListBox\group\LISTBOX ARMV5  
+WARNING: \APPS\Nokia\DDB21Nightly\workspace\ListBox\group\LISTBOX.MMP(2) : Unrecognised Keyword "TARGE"
+
+FATAL ERROR: ERROR: No Target specified
+
+MMPFILE "\APPS\Nokia\DDB21Nightly\workspace\ListBox\group\LISTBOX.MMP"
+perl -S makmake.pl -nd -D \APPS\Nokia\DDB21Nightly\workspace\ListBox\group\LISTBOX ARMV5  
+WARNING: \APPS\Nokia\DDB21Nightly\workspace\ListBox\group\LISTBOX.MMP(11) : SOURCEPATH "\APPS\Nokia\DDB21Nightly\workspace\ListBox\datx\" not found
 
+MMPFILE "\APPS\Nokia\DDB21Nightly\workspace\ListBox\group\LISTBOX.MMP"
+Died at C:\Symbian\9.3\S60_3rd_FP2_Beta\epoc32\tools\/MMP.PM line 1814.
+make: *** [MAKEFILELISTBOX] Error 255
+perl -S makmake.pl -nd -D \APPS\Nokia\DDB21Nightly\workspace\ListBox\group\LISTBOX ARMV5  
+FATAL ERROR: \APPS\Nokia\DDB21Nightly\workspace\ListBox\group\LISTBOX.MMP(6) : Stack size doesn't fit expected number format
+
+MMPFILE "\APPS\Nokia\DDB21Nightly\workspace\ListBox\group\LISTBOX.MMP"
+Died at C:\Symbian\9.3\S60_3rd_FP2_Beta\epoc32\tools\/MMP.PM line 1814.
+make: *** [MAKEFILELISTBOX] Error 255
+perl -S makmake.pl -nd -D \APPS\Nokia\DDB21Nightly\workspace\ListBox\group\LISTBOX ARMV5  
+FATAL ERROR: \APPS\Nokia\DDB21Nightly\workspace\ListBox\group\LISTBOX.MMP(42) : BITMAP color depth "listboxlistbox.cpp" - unexpected format
+
+FATAL ERROR: ERROR: No Sources specified
+
+FATAL ERROR: ERROR: No Sources specified
+
+C:\runtime-EclipseApplication\GUIFooey\group\BLD.INF:23: #error test
+BLDMAKE ERROR: ERROR: cpp.exe returned non-zero exit status (8448)
+	cpp.EXE -undef -nostdinc -+  -I "C:\S60\devices\S60_5th_Edition_SDK_v1.0\epoc32\include" -I . -I "C:\runtime-EclipseApplication\GUIFooey\group\"  -I "C:\S60\devices\S60_5th_Edition_SDK_v1.0\EPOC32\include\variant" -include "C:\S60\devices\S60_5th_Edition_SDK_v1.0\EPOC32\include\variant\Symbian_OS.hrh" "C:\runtime-EclipseApplication\GUIFooey\group\BLD.INF"
+
--- a/builder/com.nokia.carbide.cdt.builder/src/com/nokia/carbide/cdt/builder/EpocEngineHelper.java	Wed Aug 12 09:26:04 2009 -0500
+++ b/builder/com.nokia.carbide.cdt.builder/src/com/nokia/carbide/cdt/builder/EpocEngineHelper.java	Wed Aug 12 16:32:36 2009 -0500
@@ -1467,6 +1467,9 @@
 			
 			EpocEnginePathHelper helper = new EpocEnginePathHelper(info.getProject());
 			final IPath workspaceRelativeMMPPath = helper.convertToWorkspace(mmp.getPath());
+			if (workspaceRelativeMMPPath == null){
+				continue;
+			}
 			EpocEnginePlugin.runWithMMPData(workspaceRelativeMMPPath, 
 					new DefaultMMPViewConfiguration(info, new AllNodesViewFilter()), 
 					new MMPDataRunnableAdapter() {
@@ -1634,7 +1637,9 @@
 
 					for (IMMPReference mmp : data.getAllMMPReferences()) {
 						IPath workspaceRelativeMMPPath = helper.convertToWorkspace(mmp.getPath());
-						mmps.add(workspaceRelativeMMPPath);
+						if (workspaceRelativeMMPPath != null){
+							mmps.add(workspaceRelativeMMPPath);
+						}
 					}
 					return null;
 				}