From 48ccc018440aa0c177f717c653e75c58feb66cc3 Mon Sep 17 00:00:00 2001 From: Rainer Schuetze Date: Thu, 24 Jan 2019 07:44:20 +0100 Subject: update README with existing options --- README | 26 +++++++++++++++++++------- src/main.cpp | 2 +- 2 files changed, 20 insertions(+), 8 deletions(-) diff --git a/README b/README index 7824875..2a20ac3 100644 --- a/README +++ b/README @@ -73,22 +73,30 @@ Description: cv2pdb.exe is a command line tool which outputs its usage information if run without arguments: - usage: cv2pdb [-Dversion|-C] [new-exe-file] [pdb-file] + usage: cv2pdb [-D|-C|-n|-e|-s|-p] [new-exe-file] [pdb-file] -With the -D option, you can specify the version of the DMD compiler +With the `-D` option, you can specify the version of the DMD compiler you are using. Unfortunately, this information is not embedded into -the debug information. The default is -D2. So far, this information +the debug information. The default is -D2.072. So far, this information is only needed to determine whether "char[]" or "const char[]" is translated to "string". Starting with DMD 2.043, assoiciative arrays have a slightly different -implementation, so debug information needs to be adjusted aswell. +implementation, so debug information needs to be adjusted aswell. This changed +again with DMD 2.068. Version 2.072 startet embedding source language 'D' into object files. Use -D 2.043 or higher to produce the matching debug info. -Option -C tells the program, that you want to debug a program compiled +Option `-C` tells the program, that you want to debug a program compiled with DMC, the Digital Mars C/C++ compiler. It will disable some of the D specific functions and will enable adjustment of stack variable names. +With option `-n` demangling of symbols is disabled. + +Older versions of the Visual Studio Debugger (up to VS 2012) don't work well if type +and symbol names contain '.'. That's why cv2pdb replaces these characters with '@' by default. +This character can be configured to another character with the `-s`, so `-s.` will +keep symbol names as emitted by the compiler. + The first file name on the command line is expected to be the executable or dynamic library compiled by the DMD compiler and containing the CodeView debug information (-g option used when running dmd). @@ -118,6 +126,10 @@ a third file name. Example: cv2pdb debuggee.exe debuggee_pdb.exe debug.pdb +If you plan to move the excutable and PDB file to another computer, it might be helpful +to change the path or file reference that is embedded into the converted binary. `-p` allows +to replace the absolute path of the PDB file with any other file name irrespective of the +actually generated PDB file and without making the file reference absolute. Changes @@ -130,9 +142,9 @@ Feedback -------- The project home for cv2pdb is here: - http://www.dsource.org/projects/cv2pdb + https://github.com/rainers/cv2pdb -There's also a forum, where you can leave your comments and suggestions. +There's an issue tracker, where you can leave your comments and suggestions. Have fun, Rainer Schuetze diff --git a/src/main.cpp b/src/main.cpp index 608f197..ced7aac 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -156,7 +156,7 @@ int T_main(int argc, TCHAR* argv[]) printf("License for redistribution is given by the Artistic License 2.0\n"); printf("see file LICENSE for further details\n"); printf("\n"); - printf("usage: " SARG " [-Dversion|-C|-n|-e|-sC|-pembedded-pdb] [new-exe-file] [pdb-file]\n", argv[0]); + printf("usage: " SARG " [-D|-C|-n|-e|-s|-p] [new-exe-file] [pdb-file]\n", argv[0]); return -1; } -- cgit v0.12