PGジュエリーをインストールできません

PGジュエリーをインストールできません

pg gemインストールできません。私は--with-pg_config成功せずにこれを試しました。

Gem::Installer::ExtensionBuildError: エラー: gem 基本拡張をビルドできません。

/usr/local/rvm/rubies/ruby-1.9.3-p194/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.

ベストアンサー1

'libpq-fe.h'ヘッダーが見つかりません

まだインストールして初期化していない場合適切なファイル。このツールは、どのパッケージに特定の名前のファイルが含まれているかを知らせます。

sudo apt-get install apt-file
apt-file update

apt-file search libpq-fe.h次に、ファイルを含むパッケージの検索を実行し、問題のパッケージをインストールします。 (それはlibpq-dev.)

一部のパッケージインストールGUIでこのファイル名を検索することもできます。オンライン

おすすめ記事