ruby-on-rails – 无法在Fedora 17上安装PG gem

pg gem很顽固,所以我无法在新电脑上加载我的应用程序.看起来像多个问题,无法找到pg_config,然后是extconf.rb

#psql working...
psql (9.2.1)
Type "help" for help.

nd =>
\q

$pg_config:

#adding the path to bashrc...
$nano .bashrc

PATH=/usr/pgsql-9.2/bin:$PATH

#seems to work...
pg_config: /usr/pgsql-9.2/bin/pg_config

$sudo gem install pg

#but i get the same errors...
Building native extensions.  This could take a while...
.......
ERROR:  Error installing pg:
        ERROR: Failed to build gem native extension.

        /usr/bin/ruby extconf.rb
checking for pg_config... no
No pg_config... trying anyway. If building fails,please try again with
 --with-pg-config=/path/to/pg_config
checking for libpq-fe.h... no
Can't find the 'libpq-fe.h header
*** extconf.rb failed ***
Could not create Makefile due to some reason,probably lack of
necessary libraries and/or headers.  Check the mkmf.log file for more
details.  You may need configuration options.

有没有处理过这个问题的linux人?

最佳答案
这是通过解决的

$yum install /usr/include/libpq-fe.h

相关文章

linux常用进程通信方式包括管道(pipe)、有名管道(FIFO)、...
Linux性能观测工具按类别可分为系统级别和进程级别,系统级别...
本文详细介绍了curl命令基础和高级用法,包括跳过https的证书...
本文包含作者工作中常用到的一些命令,用于诊断网络、磁盘占满...
linux的平均负载表示运行态和就绪态及不可中断状态(正在io)的...
CPU上下文频繁切换会导致系统性能下降,切换分为进程切换、线...