Skip to content

Pull request for postgresql-plruby #5

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 16 commits into
base: master
Choose a base branch
from
Open

Conversation

globegit
Copy link

Hi,

This pull request includes the addition of a gemspec, including a post install message, a Rakefile, some code cleanup to eliminate most warnings, and has merged changes from tfoldl and graaf.

Please accept these changes if you don't have any objections, and then please push out a gem. :)

graaff and others added 12 commits June 27, 2010 09:38
… implementations or versions are the default ruby library.
possible to return SETOF types in contexts, which does not supports
SFRM_Materialize.

This was required to support functions which returns multiple SETOF
records from a single function calls in column definitions, eg.:

test1=# SELECT ruby_function(column);
 ruby_function
--------------------------------
 (value,2)
 (value2,1)
(2 rows)

where ruby function returns 'setof custom_type'.

A minor modification also added to avoid warning message with ruby19
@jaylevitt
Copy link

Coupla problems - probably not new, but since yours seems to be the active fork... :) I'm building on OS X 10.6.8, homebrew-installed Postgresql 9.0.4.

  1. The makefiles hardcode /opt/local. Could you just have them use the PATH for include/lib, and /usr/bin/env to find ginstall?
  2. make test fails because LANCOMPILER is no longer valid.
  3. Once I remove the lancompiler argument, make test under Ruby 1.8.7 crashes Postgres: https://gist.github.com/1260777
  4. If I rebuild under 1.9.2, it fails to create the language; I don't see this output (or any sign of the 'create') in test.out, but if I do it manually, it complains about _Init_stack, and there was much unhappiness in mkmf.log: https://gist.github.com/1260784

Any ideas? I'm happy to troubleshoot.

…t. The lancompiler option was only valid in postgres 7 and even there, it was not used
@tsenying
Copy link

tsenying commented Oct 6, 2011

Jay;

  1. not seeing the /opt/local hardcoding in the code.
  2. 'lancompiler' was only valid in postgres 7, and even there, it was not used. Took it out in commit '5818d6'
  3. Only test suite that currently passes for postgres 9.1.1 is conv_network.
    This is on OS X 10.6.8 and ruby 1.8.7.
  4. On Ubuntu, having problems linking the shared library:
    gcc -shared -o plruby.so plruby.o plplan.o plpl.o pltrans.o -L. -L/usr/local/lib -Wl,-R/usr/local/lib -L. -rdynamic -Wl,-export-dynamic -lruby-static -lpq -lrt -ldl -lcrypt -lm -lc
    /usr/bin/ld: /usr/local/lib/libruby-static.a(array.o): relocation R_X86_64_32 against `.rodata.str1.1' can not be used when making a shared object; recompile with -fPIC
    /usr/local/lib/libruby-static.a: could not read symbols: Bad value
    collect2: ld returned 1 exit status
    make[1]: *** [plruby.so] Error 1

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants