postgis-2.0.so:未定义符号:GETSTRUCT [英] postgis-2.0.so: undefined symbol: GETSTRUCT

查看:143
本文介绍了postgis-2.0.so:未定义符号:GETSTRUCT的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

当我使用pg_upgrade时,请检查将postgresql 9.0 beta2升级到postgresql 9.3 beta1. 发生以下错误:

when i use pg_upgrade check upgrade postgresql 9.0 beta2 to postgresql 9.3 beta1. error occure below :

uptest@db-172-16-3-33-> cat loadable_libraries.txt 
Could not load library "$libdir/postgis-2.0"
ERROR:  could not load library "/opt/pgsql9.3beta1/lib/postgis-2.0.so": /opt/pgsql9.3beta1/lib/postgis-2.0.so: undefined symbol: GETSTRUCT

详细过程:

  1. 安装9.3
  2. initdb 9.3
  3. 这样安装(pgfincore,pg_stat_statements,postgis,不要安装模式sql)
  4. 检查

我的LD_LIBRARY_PATH是:

LD_LIBRARY_PATH=/opt/pgsql9.3beta1/lib:/opt/postgis-2.0.3-for9.3/lib:/opt/gdal-1.10.0/lib:/opt/geos-3.3.8/lib:/opt/json-c-git20130520/lib:/opt/proj-4.8.0/lib:/lib64:/usr/lib64:/usr/local/lib64:/lib:/usr/lib:/usr/local/lib /opt/pgsql9.3beta1/bin/pg_upgrade -c -b /opt/pgsql9.0beta2/bin -B /opt/pgsql9.3beta1/bin -d /pgdata1099 -D /pgdata2099 -p 1099 -P 2099 -u postgres -v

然后出现错误:

Checking for presence of required libraries                 fatal

Your installation references loadable libraries that are missing from the
new installation.  You can add these libraries to the new installation,
or remove the functions using them from the old installation.  A list of
problem libraries is in the file:
    loadable_libraries.txt

Failure, exiting

已解决:

这是Postgresql 9.3的postgis错误. 并解决了.

this is a postgis bug for postgresql 9.3. and resolved it.

谢谢.

http://trac.osgeo.org/postgis/changeset/10321

vi/opt/soft_bak/postgis-2.0.3/postgis/geometry_estimate.c

vi /opt/soft_bak/postgis-2.0.3/postgis/geometry_estimate.c

//add
#if POSTGIS_PGSQL_VERSION >= 93
  #include "access/htup_details.h"
#endif

,然后是gmakegmake install

立即通过pg_upgrade.

do pg_upgrade passed now.

推荐答案

这是从问题中引用的. (OP编辑了问题)

This is quoted from question. (OP has edited the question)

这是Postgresql 9.3的postgis错误.并解决了.

this is a postgis bug for postgresql 9.3. and resolved it.

谢谢.

http://trac.osgeo.org/postgis/changeset/10321

vi/opt/soft_bak/postgis-2.0.3/postgis/geometry_estimate.c

vi /opt/soft_bak/postgis-2.0.3/postgis/geometry_estimate.c

//add
#if POSTGIS_PGSQL_VERSION >= 93
  #include "access/htup_details.h"
#endif

,然后gmakegmake install

立即通过pg_upgrade.

do pg_upgrade passed now.

这篇关于postgis-2.0.so:未定义符号:GETSTRUCT的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆