×

注意!页面内容来自https://www.tutorialspoint.com/gnu_debugger/installing_gdb.htm,本站不储存任何内容,为了更好的阅读体验进行在线解析,若有广告出现,请及时反馈。若您觉得侵犯了您的利益,请通知我们进行删除,然后访问 原网页

GDB - Installation



Before you go for installationcheck if you already have gdb installed on your Unix system by issuing the following command −

$gdb -help 

If GDB is installedthen it will display all the available options within your GDB. If GDB is not installedthen proceed for a fresh installation.

You can install GDB on your system by following the simple steps discussed below.

Step 1 − Make sure you have the prerequisites for installing gdb −

  • An ANSI-compliant C compiler (gcc is recommended − note that gdb can debug codes generated by other compilers)

  • 115 MB of free disk space is required on the partition on which you're going to build gdb.

  • 20 MB of free disk space is required on the partition on which you're going to install gdb.

Step 2 − Use the following command to install gdb on linux machine.

$ sudo apt-get install libc6-dbg gdb valgrind 

Step 3 − Now use the following command to find the help information.

$gdb -help 

You now have gdb installed on your system and it is ready to use.

Advertisements