Next  |  Prev  |  Up  |  Top  |  Index  |  JOS Index  |  JOS Pubs  |  JOS Home  |  Search

An example .gdbinit file.

Below is an example .gdbinit file used with the simple example STK patch (the ``acoustic echo simulator'') described in §1.2.6:

echo    set args 2 \n
        set args 2

echo    dir ../../src \n
        dir ../../src

echo    b FileWvIn::tick(void) \n
        b FileWvIn::tick(void)

The .gdbinit file goes in the same directory as the main program where gdb is started. It assumes that the library of standard stklib modules is located in ../../src/ (which works if your main directory is located in or parallel to the STK projects folder).B.2 A correct pointer to the STK source directory is necessary for viewing source code while single-stepping standard STK modules.

Note that a breakpoint is always set at the tick function of the WvIn object. When the program is run, it will halt just before sound reading begins, after preliminary set-up is finished. You can also set the breakpoint at main in order to see absolutely everything that happens.

The ``echo'' commands are not required, but they remind the user that the .gdbinit file is being executed every time gdb is started in this directory.


Next  |  Prev  |  Up  |  Top  |  Index  |  JOS Index  |  JOS Pubs  |  JOS Home  |  Search

[How to cite and copy this work] 
``Physical Audio Signal Processing for Virtual Musical Instruments and Digital Audio Effects'', by Julius O. Smith III, (December 2005 Edition).
Copyright © 2006-07-01 by Julius O. Smith III
Center for Computer Research in Music and Acoustics (CCRMA),   Stanford University
CCRMA  [Automatic-links disclaimer]