[GIS] Installing Shapely with libgeos_c on Linux

linuxshapely

The installation instructions for shapely suggest:

"Windows users should use the executable installer, which contains the required GEOS DLL. Other users should acquire libgeos_c by any means, make sure that it is on the system library path, and install from the Python package index."

What exactly is libgeos_c? Is it the same as GEOS – Geometry Engine, Open Source?

Best Answer

GEOS is the software you get from https://libgeos.org/ (which has the title you mentioned, so it is likely what you meant).

There are C and C++ interfaces as part of a standard build. libgeos_c means the C interface. On Ubuntu (and probably Debian) it is the

libgeos-c1 Geometry engine for Geographic Information Systems - C Library

package. Other distributions will also likely have it as a package or build script. They may or may not split out the C++ interface.

I'd suggest using system packages (via your package manager) unless you have strong reason to prefer building from source. On Ubuntu, a command line install would be something like:

sudo apt-get install libgeos-c1

(there are many other options including GUI and aptitude client, but this should work for all installs).