How To Install gnat-gps on Ubuntu 18.04

In this tutorial we learn how to install gnat-gps on Ubuntu 18.04. gnat-gps is integrated development environment for C and Ada

Introduction

In this tutorial we learn how to install gnat-gps on Ubuntu 18.04.

What is gnat-gps

gnat-gps is:

GNAT Programming Studio is a complete integrated development environment that gives access to a wide range of tools and integrates them smoothly.

GPS gives access to built-in file editing; HTML based help system; complete compile/build/run cycle; intelligent source navigation; project management; general graph technology giving access to many different browsers such as source dependency, project dependency, call graphs, etc.; fully integrated visual debugger, based on the GVD technology, and enhanced for inclusion in GPS; generic version control system, providing access to CVS, ClearCase, and possibly others in the future; many other tools such as a visual comparison, automatic generation of files, source reformatting.

GPS is fully customizable, providing several levels of customizations: a first level, available through the preferences dialog; a second level, which allows you to customize your menu items, tool bar and key bindings; a third level, which allows you to automate processing through scripts; and a fourth level, which allows any kind of very specific or tight integration, due to the open nature of GPS, and to its architecture.

GPS also integrates with existing editors such as Emacs and Vi.

This package also provides related command line tools:

  • gnatdoc extracts documentation from comments in Ada sources
  • gnatspark runs a spark tool according to a GNAT project
  • gps_cli is a command-line interface for gnat-gps

There are three methods to install gnat-gps on Ubuntu 18.04. We can use apt-get, apt and aptitude. In the following sections we will describe each method. You can choose one of them.

Install gnat-gps Using apt-get

Update apt database with apt-get using the following command.

sudo apt-get update

After updating apt database, We can install gnat-gps using apt-get by running the following command:

sudo apt-get -y install gnat-gps

Install gnat-gps Using apt

Update apt database with apt using the following command.

sudo apt update

After updating apt database, We can install gnat-gps using apt by running the following command:

sudo apt -y install gnat-gps

Install gnat-gps Using aptitude

If you want to follow this method, you might need to install aptitude first since aptitude is usually not installed by default on Ubuntu. Update apt database with aptitude using the following command.

sudo aptitude update

After updating apt database, We can install gnat-gps using aptitude by running the following command:

sudo aptitude -y install gnat-gps

How To Uninstall gnat-gps on Ubuntu 18.04

To uninstall only the gnat-gps package we can use the following command:

sudo apt-get remove gnat-gps

Uninstall gnat-gps And Its Dependencies

To uninstall gnat-gps and its dependencies that are no longer needed by Ubuntu 18.04, we can use the command below:

sudo apt-get -y autoremove gnat-gps

Remove gnat-gps Configurations and Data

To remove gnat-gps configuration and data from Ubuntu 18.04 we can use the following command:

sudo apt-get -y purge gnat-gps

Remove gnat-gps configuration, data, and all of its dependencies

We can use the following command to remove gnat-gps configurations, data and all of its dependencies, we can use the following command:

sudo apt-get -y autoremove --purge gnat-gps

References

Summary

In this tutorial we learn how to install gnat-gps package on Ubuntu 18.04 using different package management tools: apt, apt-get and aptitude.