2014-10-26 64 views
2

安裝PL /紅寶石我想使用PL/Ruby的程序語言,但它似乎Git倉庫,不能很好地維護: https://github.com/Absolight/postgresql-plruby/tree/fixup-9-3上的PostgreSQL 9.3

當我創造新的語言:

create function plruby_call_handler() returns language_handler 
as '/var/lib/postgresql/.rvm/rubies/ruby-2.1.3/lib/ruby/site_ruby/2.1.0/x86_64-linux/plruby' 
language 'c'; -- Warning: the 'c' has to be lowercase, unlike the example on git. 

我得到以下錯誤:

ERROR: could not load library "/var/lib/postgresql[...]plruby": undefined symbol: plruby_s_load 

我在Ubuntu 14.10使用Ruby 2.1.4在PostgreSQL 9.3。

+0

你能指定你的PostgreSQL服務器使用哪個操作系統嗎? – vyegorov 2014-10-29 13:34:22

+0

Ubuntu 14.10,問題更新。 – Victor 2014-10-29 19:36:19

回答

2

請檢查您是否編譯從分支修正-9-3是源和運行PostgreSQL 9.3版本

git clone https://github.com/Absolight/postgresql-plruby.git 
    cd postgresql-plruby 
    git checkout fixup-9-3 

因爲我從主分支安裝時幾乎同樣的問題。另外嘗試安裝libpq-dev。我使用的是OSX 10.10,我只需要安裝PostgreSQL庫就可以使用brew install postgresql,而且這個工作可以在我的機器上運行。