我尝试使用gem install pg
安装pg gem并返回:
gcc -dynamic -bundle -o pg_ext.bundle pg.o pg_connection.o pg_result.o -L. -L/Users/macuser/.rvm/rubies/ruby-1.9.2-p180/lib -L. -L/usr/local/lib -L/usr/local/Cellar/postgresql/9.1.2/lib -Wl,-undefined,dynamic_lookup -Wl,-multiply_defined,suppress -Wl,-flat_namespace -lruby.1.9.1 -lpq -lpthread -ldl -lobjc
ld: in /usr/local/lib/libssl.0.9.8.dylib, missing required architecture x86_64 in file
collect2: ld returned 1 exit status
make: *** [pg_ext.bundle] Error 1
我试过这个:
目前,我相信我的Mac上有三种不同版本的postgres。其中一个是一键安装程序,其他安装程序与Brew一起安装。也许这就是问题?
我用这个安装宝石:
export CONFIGURE_ARGS="with-pg-include=/usr/local/Cellar/postgresql/9.0.3/include"
然后再使用较新的版本:
export CONFIGURE_ARGS="with-pg-include=/usr/local/Cellar/postgresql/9.1.2/include"
同样的错误。
然后我尝试使用ARCHFLAGS:
env ARCHFLAGS="-arch x86_64" gem install pg
仍然是同样的错误。不知道该怎么做..我也使用RVM。也许这是一个原因?
我在哪里可以找到此文件的较新版本? libssl.0.9.8.dylib
感谢〜