I'm trying to install GDAL through pip. But I'm getting this error:
extensions/gdal_wrap.cpp:3089:27: fatal error: cpl_vsi_error.h: No such file or directory
#include "cpl_vsi_error.h"
^
compilation terminated.
error: command 'x86_64-linux-gnu-gcc' failed with exit status 1
I used these commands:
sudo apt-get install libgdal-dev
export CPLUS_INCLUDE_PATH=/usr/include/gdal
export C_INCLUDE_PATH=/usr/include/gdal
pip install GDAL
Can anyone tell me how to install it ?
On my MacBook, the update/fresh install of GDAL using this approach with homebrew worked out fine. The problem on my Mac was that I apparently had an old GDAL version installed and wasn't able to update with
brew upgrade gdal
because of the above error message.Solution in short:
Verification:
Check that you installed GDAL using this command
Then run this commands: