From b5dcff365db1a53934a9a896ae3d4580d52d0eea Mon Sep 17 00:00:00 2001 From: Rainer Schuetze Date: Wed, 3 Jun 2015 07:27:50 +0200 Subject: add support for VS 2015 --- CHANGES | 1 + src/cv2pdb.cpp | 1 + src/mspdb.cpp | 18 ++++++++++++++++++ 3 files changed, 20 insertions(+) diff --git a/CHANGES b/CHANGES index 9ba5f0d..f1ce089 100644 --- a/CHANGES +++ b/CHANGES @@ -225,3 +225,4 @@ unreleased Version 0.22 * last version introduced a regression that could cause DWARF conversion to crash * DWARF sections now stripped from image (if last sections) + * add support for VS 2015 diff --git a/src/cv2pdb.cpp b/src/cv2pdb.cpp index 6eb3937..259c277 100644 --- a/src/cv2pdb.cpp +++ b/src/cv2pdb.cpp @@ -3049,6 +3049,7 @@ bool CV2PDB::writeSymbols(mspdb::Mod* mod, DWORD* data, int databytes, int prefi mspdb::vsVersion == 10 ? "cannot add symbols to module, probably msobj100.dll missing" : mspdb::vsVersion == 11 ? "cannot add symbols to module, probably msobj110.dll missing" : mspdb::vsVersion == 12 ? "cannot add symbols to module, probably msobj120.dll missing" + : mspdb::vsVersion == 14 ? "cannot add symbols to module, probably msobj140.dll missing" : "cannot add symbols to module, probably msobj80.dll missing"); return true; } diff --git a/src/mspdb.cpp b/src/mspdb.cpp index d951940..f95457c 100644 --- a/src/mspdb.cpp +++ b/src/mspdb.cpp @@ -17,6 +17,7 @@ char* mspdb80_dll = "mspdb80.dll"; char* mspdb100_dll = "mspdb100.dll"; char* mspdb110_dll = "mspdb110.dll"; char* mspdb120_dll = "mspdb120.dll"; +char* mspdb140_dll = "mspdb140.dll"; // char* mspdb110shell_dll = "mspdbst.dll"; // the VS 2012 Shell uses this file instead of mspdb110.dll, but is missing mspdbsrv.exe int mspdb::vsVersion = 8; @@ -134,6 +135,21 @@ void tryLoadMsPdb120(bool throughPath) } } +void tryLoadMsPdb140(bool throughPath) +{ + if (!modMsPdb) + { + if(throughPath) + modMsPdb = LoadLibraryA(mspdb140_dll); + if (!modMsPdb && !throughPath) + tryLoadMsPdb("VisualStudio\\14.0", mspdb140_dll, "..\\..\\VC\\bin\\"); + if (!modMsPdb && !throughPath) + tryLoadMsPdb("VSWinExpress\\14.0", mspdb140_dll, "..\\..\\VC\\bin\\"); + if (modMsPdb) + mspdb::vsVersion = 14; + } +} + bool initMsPdb() { #if 0 // might cause problems when combining VS Shell 2010 with VS 2008 or similar @@ -149,11 +165,13 @@ bool initMsPdb() #endif // try loading through the PATH first to best match current setup + tryLoadMsPdb140(true); tryLoadMsPdb120(true); tryLoadMsPdb110(true); tryLoadMsPdb100(true); tryLoadMsPdb80(true); + tryLoadMsPdb140(false); tryLoadMsPdb120(false); tryLoadMsPdb110(false); tryLoadMsPdb100(false); -- cgit v0.12