我正在尝试在我的 linux ubuntu 12.04 机器上安装 DBD::pg 模块,但无法这样做。我正在使用下载方法,因为我在从 CPAN 终端安装它时遇到连接问题。当我运行 perl Makefile.PL 它给了我以下信息。
Configuring DBD::Pg 3.4.2
Path to pg_config? /vol01/local/rina/cac/softwares/pgsql
Enter a valid PostgreSQL postgres major version number 8
Enter a valid PostgreSQL postgres minor version number 8
Enter a valid PostgreSQL postgres patch version number 8
Enter a valid PostgreSQL postgres bin dir /vol01/local/rina/cac/softwares/bin
Enter a valid PostgreSQL postgres include dir /vol01/local/rina/cac/softwares/pg_inc
我不知道在上述问题中要输入什么,但我仍然手动创建了几个目录并按上述方式提供。
然后它给了我这个
PostgreSQL version: 80898 (default port: 5432)
POSTGRES_HOME: (not set)
POSTPGRES_INCLUDE: /vol01/local/rina/cac/softwares/pg_inc
POSTGRES_LIB: /usr/local/pgsql/lib -lssl -lcrypto
OS: linux
Multiple copies of Driver.xst found in: /usr/local/lib64/perl5/auto/DBI/ /usr/lib64/perl5/auto/DBI/ at Makefile.PL line 182
Warning: prerequisite Time::HiRes 0 not found.
Multiple copies of Driver.xst found in: /usr/local/lib64/perl5/auto/DBI/ /usr/lib64/perl5/auto/DBI/ at Makefile.PL line 285
Using DBI 1.631 (for perl 5.010001 on x86_64-linux-thread-multi) installed in /usr/local/lib64/perl5/auto/DBI/
Writing Makefile for DBD::Pg
后来当我运行 make 它多次给我以下错误
Pg.xs:301: error: ‘imp_dbh_t’ has no member named ‘sqlstate
如何成功安装此模块?我发现很少有类似的问题,但找不到解决方案。请帮忙。