linux下shapely的安装

 

错误

1.“from shapely.geometry import Point, LineString, Polygon”时报错:

OSError: Could not find library geos_c or load any of its variants ['libgeos_c.so.1', 'libgeos_c.so

这是因为geos的目录未加入到环境变量,可以在~/.bashrc中添加

export GEOS_LIBRARY_PATH=/opt/source/geos-3.5.0/build/lib

source ~/.bashrc

即可。 

 

2. error: Python.h: No such file or directory

没有安装python-dev

sudo apt-get install python2.7-dev


posted @ 2016-04-21 17:59  ottll  阅读(2817)  评论(0编辑  收藏  举报