libpqxx 库安装&configure: error:Linking a call to libpq failed in C++, even though it succeeded in C.

在尝试安装libpqxx库时,遇到configure错误:Linking a call to libpq失败。尽管在C中成功,但在C++中失败。参考简书和Stack Overflow上的建议,问题可能与版本有关。升级libpqxx到5.0.1未解决问题,但升级到7.2.0解决了问题。建议直接从GitHub的tags页面选择合适的版本进行安装。
摘要由CSDN通过智能技术生成

参考了这篇libpqxx 库安装及使用 - 简书安装libpqxx,遇到报错信息:

configure: error:
Linking a call to libpq failed in C++, even though it succeeded in C. If your
C and C++ compilers are very different beasts, this may mean that we do not have
the right options for linking with it after all.

网上给的解决方案是:

postgresql - Error in ./configure step in installation of libpqxx - Stack Overflow

看到可能是版本遗留问题,升级版本到5.0.1 还是这个错误,升级到7.2.0解决。

https://github.com/jtv/libpqxx

在git tags中找到合适的新版本即可。

  • 1
    点赞
  • 1
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值