Author: shivaram
Date: 2012-01-30 08:30:05 -0500 (Mon, 30 Jan 2012)
New Revision: 3864

Modified:
   trunk/osprey/be/cg/cgdwarf.cxx
Log:
Fix for bug#944. 
Allow debugging of sources compiled from different directory.

Code Review: Sun Chan. 


Modified: trunk/osprey/be/cg/cgdwarf.cxx
===================================================================
--- trunk/osprey/be/cg/cgdwarf.cxx      2012-01-30 08:53:26 UTC (rev 3863)
+++ trunk/osprey/be/cg/cgdwarf.cxx      2012-01-30 13:30:05 UTC (rev 3864)
@@ -2832,8 +2832,16 @@
              file_table[count].filename);
     else 
 #endif
-    fprintf(Asm_File, "\t%s\t%d\t\"%s\"\n", AS_FILE, count,
-            file_table[count].filename);
+    {
+      int include_idx = file_table[count].incl_index;
+      if (incl_table[include_idx].path_name)
+         fprintf(Asm_File, "\t%s\t\%d\t\"%s/%s\"\n", AS_FILE,count, 
+                                incl_table[include_idx].path_name,
+                                file_table[count].filename);
+      else
+         fprintf(Asm_File, "\t%s\t%d\t\"%s\"\n", AS_FILE, count,
+               file_table[count].filename);
+    }
     count++;
   }
   fputc ('\n', Asm_File);


------------------------------------------------------------------------------
Try before you buy = See our experts in action!
The most comprehensive online learning library for Microsoft developers
is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3,
Metro Style Apps, more. Free future releases when you subscribe now!
http://p.sf.net/sfu/learndevnow-dev2
_______________________________________________
Open64-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/open64-devel

Reply via email to