How to re-compile ogrinfo against gdal used by QGIS?

المشرف العام

Administrator
طاقم الإدارة
I just solved a problem with missing libraries blocking use of ogrinfo and ogr2ogr, only to find that these utilities are garbled in one more way: whenever I run any of these, I get following error (this is for ogrinfo, for ogr2ogr it's analogical):

ERROR 1: ogrinfo was compiled against GDAL 1.9 but current library version is 1.10I think I understand the cause: I mistakenly installed GDAL 1.9 manually through make-install as suggested here; make-uninstall is not possible for it. Ogrinfo was compiled to this version of GDAL and forgot about version 1.10 shipped with my QGIS (2.10). But I'm stuck here, with no idea how to re-compile ogr against the right version of GDAL.

What I tried:

  • reinstall QGIS (with sudo apt-get --purge autoremove to clean the dependencies after uninstall)
  • trash ogrinfo, ogr2ogr and even whole GDAL-1.9 directory; then I have recovered the ogr files but not gdal 1.9, though I can do it any time
  • few more options like sudo apt-get autoclean
Perhaps I could cleanly purge and install the ogr package if I knew it's exact name. Or do I need to purge the old version completely and then somehow (how?) tell the QGIS installer to install ogr as well?



أكثر...
 
أعلى