gdal-config command not found
Introduction
When you run more command in linux terminal / console, you get the following error message
gdal-config: command not found
or when using sudo you get the following error message
sudo: gdal-config: command not found
Solutions to gdal-config: command not found
How To Fix gdal-config: command not found in Ubuntu / Debian / Kali Linux / Raspbian
In Ubuntu gdal-config is provided by libgdal-dev package.
libgdal-dev is:
GDAL is a translator library for raster geospatial data formats. As a library, it presents a single abstract data model to the calling application for all supported formats. The related OGR library (which lives within the GDAL source tree) provides a similar capability for simple features vector data.
GDAL supports many popular data formats, including commonly used ones (GeoTIFF, JPEG, PNG and more) as well as the ones used in GIS and remote sensing software packages (ERDAS Imagine, ESRI Arc/Info, ENVI, PCI Geomatics). Also supported many remote sensing and scientific data distribution formats such as HDF, EOS FAST, NOAA L1B, NetCDF, FITS.
OGR library supports popular vector formats like ESRI Shapefile, TIGER data, S57, MapInfo File, DGN, GML and more.
This package contains the files needed to develop a software that will use the GDAL/OGR (headers, static objects, configuration script).
To fix this problem, we can install more using the command below.
sudo apt-get -y install libgdal-dev
This command might take some time to finish depending on your machine internet connection.
You can also use apt command to install libgdal-dev.
sudo apt -y install libgdal-dev
Or if you have aptitude installed you can use the following command.
sudo aptitude install libgdal-dev
Summary
In this tutorial we learn how to fix gdal-config command not found error in Ubuntu / Debian / Kali Linux or Raspbian distribution.