Re: From VC6 to VC 2008 : debugging with additional DLL



In article <uoWA682wJHA.5100@xxxxxxxxxxxxxxxxxxxx>,
Frederic Forjan <frederic.forjan@xxxxxxxxxxxxxxxx> wrote:
It's become redundant, newer versions are smarter and *should* just
work without doing anything if the debug information is available for
the DLL.

But in this case, how can we put some breakpoint inside these DLL before
starting the application ?

If you built the dll on the same machine, and have generated .pdb
files, then a breakpoint in the source code will be auto-inserted by
DevStudio when that dll loads. To do/check this, right click on your
dll project (NOT the solution, but the project entries in the solution
explorer), and get properties. Go to Configuration Properties ->
C/C++, and ensure that 'Debug Information Format' is set to 'Program
Database' or 'Program Database for Edit & Continue'. (The former makes
sense for release builds, the latter for debug builds.) Also, look at
Configuration Properties -> Linker -> Debugging, and make sure that
'Generate Debug Info' is set to yes, and you're generating a program
database file.

Once you have built your dll with the above settings, (1) in the
Visual Studio .sln you use to run your exe, open up the .c/.cpp/.h
file(s) you want to put breakpoints on. (2) Put a breakpoint on the
line(s) you want (F9 if you have the VC++6 keyboard shortcuts), (3)
Run the .exe. Obviously, if you run debug, it's easier to debug.

Nathan Mates
--
<*> Nathan Mates - personal webpage http://www.visi.com/~nathan/
# Programmer at Pandemic Studios -- http://www.pandemicstudios.com/
# NOT speaking for Pandemic Studios. "Care not what the neighbors
# think. What are the facts, and to how many decimal places?" -R.A. Heinlein
.



Relevant Pages

  • ThisApplication_Startup event not firing
    ... However the event will not fire in debug. ... not built with debug information. ... InitializeTrace ...
    (microsoft.public.vsnet.vstools.office)
  • Re: How to connect to children process
    ... Main problem is amount of manual operations required per debug cycle. ... connection to DLL with debugger takes sensible amount of time and manual ... Is the main problem that the debugger keeps symbols file loaded ... AFAIK that's how VS2003 debugger works, but WinDbg should usually ...
    (microsoft.public.vsnet.debugging)
  • Re: Windows CE 5.0 bug list
    ... I've managed to get the vmini.dll built by including the Local Area Netowork ... I've read the article and I am in the process of tracing through how the DLL ... " The output of the BSP phase is normally placed in a CPU-specific directory ...
    (microsoft.public.windowsce.platbuilder)
  • Re: running a service/driver/application upon startup
    ... Would it be possible for you to drop a debug services.exe and debug nk.exe ... > I ran dumpbin/exports on the finger dll and saw the required function ... >> theories as to why it's not getting loaded but just doing 'services load ...
    (microsoft.public.windowsce.embedded)
  • Re: adding XML support (without new OS image)
    ... In theory an image built without MSXML3 can have it added after the fact. ... then it would look like msxml3 dll being not setup right isn't the ... the OS image that you're targeting and a debug msxml3.dll. ... > but during the time the CE.NET OS was built without XML support. ...
    (microsoft.public.windowsce.platbuilder)

Loading