2011-08-28 62 views
0

我已经通过谷歌和Stackoverflow,并且尚未解决我安装将程序部署到Heroku所需的pg gem的问题。如何知道使用哪些配置选项在OSX上安装pg gem?

我已经通过Macport安装Postgresql,但也许我安装它在错误的路径下?

我说,因为我收到follwing当我这样做gem install pg -- --with-pg-config=/user/local/bin/pg_config

extconf.rb:24:in ``': No such file or directory - /users/******/postgresql/bin/pg_config --includedir (Errno::ENOENT) 

还是我没有做一个完整的安装,因为我不断获取此:

*** 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. 

Provided configuration options: 
    --with-opt-dir 
    --without-opt-dir 
    --with-opt-include 
    --without-opt-include=${opt-dir}/include 
    --with-opt-lib 
    --without-opt-lib=${opt-dir}/lib 
    --with-make-prog 
    --without-make-prog 
    --srcdir=. 
    --curdir 
    --ruby=/Users/TonyNg/.rvm/rubies/ruby-1.9.2-p180/bin/ruby 
    --with-pg 
    --without-pg 
    --with-pg-dir 
    --without-pg-dir 
    --with-pg-include 
    --without-pg-include=${pg-dir}/include 
    --with-pg-lib 
    --without-pg-lib=${pg-dir}/lib 
    --with-pg-config 

应该如何我着手解决这个问题?

回答