How to build and use GDB

Ubuntu uses quite an old version of GDB. When I need to use an updated version of GDB, here is what I do:

  • Obtain the newer version of GDB by downloading its .tar.gz from here. Unzip it.
  • Configure and build it:
$ ./configure
$ make
  • The newly built GDB executable can be found at gdb/gdb in your current directory. You can copy it or invoke it directly to use it.

Tried with: GDB 8.1 and Ubuntu 16.04

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

This site uses Akismet to reduce spam. Learn how your comment data is processed.