Upgrade from gdb 7.7 to 7.8
gdb 7.8 is currently not available in trusty repo. But you can install it from the source.
Open terminal and type following commands
wget http://ftp.gnu.org/gnu/gdb/gdb-7.8.tar.xz
tar -xf gdb-7.8.tar.xz
cd gdb-7.8/
./configure
make
sudo cp gdb/gdb /usr/local/bin/gdb
It will install gdb
in /usr/local/bin/
directory. As /usr/local/bin/
is searched before /usr/bin/
whenever a command is executed, running gdb
will execute gdb 7.8
.
Once installed, you can check gdb version using
gdb --version
It should output
GNU gdb (GDB) 7.8
Copyright (C) 2014 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law. Type "show copying"
and "show warranty" for details.
This GDB was configured as "i686-pc-linux-gnu".
Type "show configuration" for configuration details.
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>.
Find the GDB manual and other documentation resources online at:
<http://www.gnu.org/software/gdb/documentation/>.
For help, type "help".
Type "apropos word" to search for commands related to "word".
If you want to uninstall it simply remove gdb
from /usr/local/bin/
by executing
sudo rm /usr/local/bin/gdb
Updating GDB from 7.7.1 to 8.2 on Ubuntu 14.04:
sudo add-apt-repository ppa:ubuntu-toolchain-r/test
sudo apt-get update
sudo apt-get -y --force-yes install gdb
gdb -v
sudo add-apt-repository --remove ppa:ubuntu-toolchain-r/test
sudo apt-get update