Skip to content

Install latest GMT on RHEL CentOS

Dongdong Tian edited this page Nov 9, 2020 · 7 revisions

GMT binary packages are available from Extra Packages for Enterprise Linux (EPEL). However, EPEL is far behind packaging a recent version. We provide the GMT official RPM repository to allow RHEL/CentOS users access the latest GMT releases in an easy way.

RHEL/CentOS 7 & 8

To install the latest GMT on RHEL/CentOS 7 & 8 , run:

# install epel-release
sudo yum install epel-release

# RHEL/CentOS 8 users need to enable PowerTools repository first
sudo yum config-manager --set-enabled PowerTools

# Enable the RPM repository
sudo yum install yum-plugin-copr
sudo yum copr enable genericmappingtools/gmt

# Install GMT
sudo yum install gmt

# Update to the latest version if available
sudo yum update gmt

You may also install other optional dependencies for more capabilities within GMT:

sudo yum localinstall --nogpgcheck https://download1.rpmfusion.org/free/el/rpmfusion-free-release-`rpm -E %rhel`.noarch.rpm
sudo yum install GraphicsMagick ffmpeg gdal

Note: If you already installed the GMT packages provided by EPEL, you have to uninstall them before installing the new GMT packages provided by the official GMT repository. You can uninstall the older packages by:

yum remove GMT dcw-gmt gshhg-gmt-nc4 gshhg-gmt-nc4-full gshhg-gmt-nc4-high

RHEL/CentOS 6

RHEL/CentOS 6 reaches End of Life on Nov. 30, 2020.

The latest GMT version available for RHEL/CentOS 6 is GMT v6.1.1, and it won't be maintained and upgraded anymore. RHEL/CentOS 6 users are highly recommended to upgrade to more recent Linux distros.

For RHEL/CentOS 6, run:

# install epel-release
sudo yum install epel-release

## RHEL/CentOS 6 only
sudo wget https://copr.fedorainfracloud.org/coprs/genericmappingtools/gmt/repo/epel-6/genericmappingtools-gmt-epel-6.repo -O /etc/yum.repos.d/genericmappingtools-gmt-epel-6.repo

# Install GMT
sudo yum install gmt

You may also install other optional dependencies for more capabilities within GMT:

yum localinstall --nogpgcheck https://download1.rpmfusion.org/free/el/rpmfusion-free-release-`rpm -E %rhel`.noarch.rpm
yum install GraphicsMagick ffmpeg gdal