Home > Archive > PostgreSQL Bugs > December 2005 > BUG #2136: plperl doesn't work, plperlu - yes









You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

 

Author BUG #2136: plperl doesn't work, plperlu - yes
Robert Osowiecki

2005-12-31, 3:23 am


The following bug has been logged online:

Bug reference: 2136
Logged by: Robert Osowiecki
Email address: robson@cavern.pl
PostgreSQL version: 8.1.1
Operating system: Linux 2.6.14-gentoo-r5 #2 SMP Thu Dec 22 11:58:01 CET
2005 i686 Intel(R) Xeon(TM) CPU 3.20GHz GenuineIntel GNU/Linux
Description: plperl doesn't work, plperlu - yes
Details:

Creation of any plperl function gives error message:

ERROR: creation of Perl function failed: Can't locate object method "new"
via package "Safe" at line 1.
(in cleanup) Can't call method "reval" on an undefined value at line
1.

The same function created in plperlu language compiles and works fine.

I've recompiled Postgres to be sure about library versions.

Perl version: v5.8.6 built for i686-linux
ldd output:
#ldd /opt/pgsql/lib/plperl.so
linux-gate.so.1 => (0xffffe000)
libperl.so.1 => /usr/lib/perl5/5.8.6/i686-linux/CORE/libperl.so.1
(0xb7e6f000)
libpthread.so.0 => /lib/libpthread.so.0 (0xb7e19000)
libnsl.so.1 => /lib/libnsl.so.1 (0xb7e04000)
libdl.so.2 => /lib/libdl.so.2 (0xb7e00000)
libm.so.6 => /lib/libm.so.6 (0xb7ddd000)
libcrypt.so.1 => /lib/libcrypt.so.1 (0xb7daf000)
libutil.so.1 => /lib/libutil.so.1 (0xb7daa000)
libc.so.6 => /lib/libc.so.6 (0xb7c92000)
/lib/ld-linux.so.2 (0x80000000)

---------------------------(end of broadcast)---------------------------
TIP 1: if posting/reading through Usenet, please send an appropriate
subscribe-nomail command to majordomo@postgresql
.org so that your
message can get through to the mailing list cleanly

Michael Fuhr

2005-12-31, 1:23 pm

On Fri, Dec 30, 2005 at 09:43:52AM +0000, Robert Osowiecki wrote:
> Creation of any plperl function gives error message:
>
> ERROR: creation of Perl function failed: Can't locate object method "new"
> via package "Safe" at line 1.
> (in cleanup) Can't call method "reval" on an undefined value at line
> 1.


Can you use the Safe module in standalone Perl scripts? What happens
if you run the following?

#!/usr/bin/perl
use strict;
require Safe;
print "Safe::VERSION = $Safe::VERSION\n";
my $foo = new Safe('foo');
print "test = ", $foo->reval("test"), "\n";

--
Michael Fuhr

---------------------------(end of broadcast)---------------------------
TIP 3: Have you checked our extensive FAQ?

http://www.postgresql.org/docs/faq

Sponsored Links





Also available: Server administration forum archive | Web Design forum archive | Software forum archive | Hardware reviews archive | Programming forum archive

Copyright 2008 droptable.com