I was having trouble installing a Python package with pip. pip install gdal
failed so instead I tried installing with homebrew as suggested here, running brew install gdal
. This worked, but pip doesn't know the package exists, so it tries to install it when installing a package that depends on it. I want pip to be able to use packages installed by brew. My computer runs MacOS 10.14 and I'm using Python 3 with pip 19.0.3 and Homebrew 2.0.2
Asked
Active
Viewed 487 times
2

Luciano
- 426
- 2
- 9
- 19
-
try this out https://gis.stackexchange.com/questions/28966/python-gdal-package-missing-header-file-when-installing-via-pip – Carlos Azevedo Feb 20 '19 at 23:58
1 Answers
2
The command brew install gdal
doesn't install a python package — it installs GDAL library. After that you still have to install Python wrapper by running pip install gdal
.

phd
- 82,685
- 13
- 120
- 165
-
Oh I see. But when i run `pip install gdal`, I get a fatal error saying `#include
` was not found in `extensions/gdal_wrap.cpp`. – Luciano Feb 20 '19 at 23:56