0
所以我不得不在我的電腦墜毀後重新初始化一個項目,並且正在重新安裝所有寶石上的紅寶石。不幸的是,當我運行軟件包安裝時,出現以下錯誤。寶石pg沒有安裝
Building native extensions. This could take a while...
ERROR: Error installing pg:
ERROR: Failed to build gem native extension.
current directory: /usr/lib/ruby/gems/2.3.0/gems/pg-0.21.0/ext
/usr/bin/ruby2.3 -r ./siteconf20170925-462-dsymf.rb extconf.rb
mkmf.rb can't find header files for ruby at /usr/lib/ruby/include/ruby.h
extconf failed, exit code 1
Gem files will remain installed in /usr/lib/ruby/gems/2.3.0/gems/pg-0.21.0
for inspection.
Results logged to /usr/lib/ruby/gems/2.3.0/extensions/x86_64-linux/2.3.0/pg-
0.21.0/gem_make.out
如果有人能給我一個點在正確的方向將不勝感激。
從終端安裝此軟件包。 'sudo apt-get install libpq-dev'。 –
確保你已經安裝了Ruby開發文件,如果你在基於rhel的系統上,你可以'安裝ruby-devel'。更好的選擇是使用rbenv或rvm來管理你的ruby安裝。 – ddubs
謝謝你們,我的包很好。 –