can you also try this patch also?
--
VJ

On Feb 5, 2008 12:02 PM, Vijay Kiran Kamuju <[EMAIL PROTECTED]> wrote:
> Hi,
>
> can you try this patch:
> http://www.winehq.org/pipermail/wine-patches/2008-January/049156.html
>
> I think currently dbghelp in wine doesnt support pdb files generated by VS 
> 2005.
>
> Thanks,
> VJ
>
>
> On Feb 5, 2008 12:54 PM, Michel Jacques <[EMAIL PROTECTED]> wrote:
> > Hello,
> >
> > I am using PDBs generated with 2005 with wine version 0.9.54.
> >
> > I get errors related to my PDBs and I am wondering if I need
> > to change the pdb format? Anything special to do when using 2005?
> >
> > Here are the errors I get, each time one of my pdb gets loaded:
> >
> > 0009:trace:dbghelp:SymFindFileInPathW (hProcess = 0x30, searchPath = 
> > (null), full_path =
> > L"C:\\master\\x86\\debug\\bin\\mydll.pdb", id = 0x34c160, two = 0x00000002, 
> > three = 0x00000000,
> > flags = 0x00000008, buffer = 0x34b718, cb = 0x6020fb50, user = 0x34bd30)
> > 0009:err:dbghelp_msc:pdb_process_types -Unknown type info version 20040203
> > 0009:err:dbghelp_msc:pe_load_debug_directory Got a page fault while loading 
> > symbols
> > 0009:trace:dbghelp:pcs_callback 0x111998 2 0x34c378
> > 0009:trace:dbghelp:pcs_callback 0x111998 1 0x34c378
> > 0009:trace:dbghelp:pe_load_stabs failed to load the STABS debug info
> >
> > Thanks,
> >
> > Michel Jacques
> >
> >
> >
> >       Découvrez les styles qui font sensation sur Yahoo! Québec Avatars.
> > http://cf.avatars.yahoo.com/
> >
> >
> >
>
diff --git a/dlls/dbghelp/msc.c b/dlls/dbghelp/msc.c
index 66a2570..78af43f 100644
--- a/dlls/dbghelp/msc.c
+++ b/dlls/dbghelp/msc.c
@@ -1944,7 +1944,8 @@ static void pdb_process_types(const struct msc_debug_info* msc_dbg,
         case 19950410:      /* VC 4.0 */
         case 19951122:
         case 19961031:      /* VC 5.0 / 6.0 */
-        case 19990903:
+        case 19990903:      /* VC 7.0 */
+        case 20040203:      /* VC 8.0 */
             break;
         default:
             ERR("-Unknown type info version %d\n", types.version);
@@ -2184,7 +2185,8 @@ static BOOL pdb_process_internal(const struct process* pcs,
         case 0:            /* VC 4.0 */
         case 19960307:     /* VC 5.0 */
         case 19970606:     /* VC 6.0 */
-        case 19990903:
+        case 19990903:     /* VC 7.0 */
+        case 20040203:     /* VC 8.0 */
             break;
         default:
             ERR("-Unknown symbol info version %d %08x\n",
@@ -2194,11 +2196,14 @@ static BOOL pdb_process_internal(const struct process* pcs,
         pdb_process_symbol_imports(pcs, msc_dbg, &symbols, symbols_image, image, pdb_lookup, module_index);
 
         /* Read global symbol table */
-        modimage = pdb_read_file(image, pdb_lookup, symbols.gsym_file);
+        /* only the low word of gsym_file is the file number for the symbols file. On VC 8.0 the high word
+           is always 0x002a, on VC 7.0 its 0x0000. similarly hash1_file and hash2_file the high word values 
+           for VC 7.0 are 0x38a0 and 0x0c05 and for VC 8.0 they are 0x8800 and 0xc267 respectively. */
+        modimage = pdb_read_file(image, pdb_lookup, symbols.gsym_file & 0x0000ffff);
         if (modimage)
         {
             codeview_snarf(msc_dbg, modimage, 0, 
-                           pdb_get_file_size(pdb_lookup, symbols.gsym_file), NULL);
+                           pdb_get_file_size(pdb_lookup, symbols.gsym_file & 0x0000ffff), NULL);
 
             pdb_free(modimage);
         }
@@ -2231,6 +2236,12 @@ static BOOL pdb_process_internal(const struct process* pcs,
 
                 pdb_free(modimage);
             }
+
+            /* PDB files generated from VC 8.0 use a new format for storing linee no information.
+               The <lineno_size> member of PDB_SYMBOL_EX header is 0 but unknown2 has a value. */
+            if (sfile.unknown2 && sfile.lineno_size == 0)
+                FIXME("Line no info is missing.\n");
+
             file_name = (const char*)file + size;
             file_name += strlen(file_name) + 1;
             file = (BYTE*)((DWORD)(file_name + strlen(file_name) + 1 + 3) & ~3);
@@ -2281,6 +2292,9 @@ static BOOL pdb_process_file(const struct process* pcs,
         msc_dbg->module->module.SourceIndexed = TRUE;
         msc_dbg->module->module.Publics = TRUE;
     }
+    else
+       TRACE("failed to load pdb file.\n");
+
     return ret;
 }
 


Reply via email to