PL/pgSQL in template1?

Started by Nonameover 27 years ago4 messages
#1Noname
jwieck@debis.com

Hi,

I wonder if anyone ever played around with PL/pgSQL. So far
(except for the missing Makefile) I got no response if it
compiles/works on other platforms than my Linux.

Since there are only a few details left in the rewrite code
for 6.4 I would like to get back on it. I think 6.4 BETA is
the right time to check if it works on all the platforms (6.4
is the first time we ship it).

I would do it by adding a build/install with (errors ignored
first) to the Makefiles. Then another regression test could
check if it works.

Comments?

Jan

--

#======================================================================#
# It's easier to get forgiveness for being wrong than for being right. #
# Let's break this rule - forgive me. #
#======================================== jwieck@debis.com (Jan Wieck) #

#2David Hartwig
daveh@insightdist.com
In reply to: Noname (#1)
Re: [HACKERS] PL/pgSQL in template1?

Jan,

I have been hacking around trying to get a clean build without much luck. I
have adjusted the compile options and fixed one casting problem to get all C
code compiled. I also extracted all the external symbols successfully.
(AIX requirement) However, I get the following message at link time:

ld: 0711-362 ERROR: Glink code cannot be added for function: _ptrgl
This function is used by compilers and must be called directly.

Shared libraries are a bit more tricky on AIX, but I thought I had the
routine pretty well figured out. I am at a complete loss here.

Andreas, could you give it a try?

Jan Wieck wrote:

Show quoted text

Hi,

I wonder if anyone ever played around with PL/pgSQL. So far
(except for the missing Makefile) I got no response if it
compiles/works on other platforms than my Linux.

Since there are only a few details left in the rewrite code
for 6.4 I would like to get back on it. I think 6.4 BETA is
the right time to check if it works on all the platforms (6.4
is the first time we ship it).

I would do it by adding a build/install with (errors ignored
first) to the Makefiles. Then another regression test could
check if it works.

Comments?

#3Noname
jwieck@debis.com
In reply to: David Hartwig (#2)
Re: [HACKERS] PL/pgSQL in template1?

Jan,

I have been hacking around trying to get a clean build without much luck. I
have adjusted the compile options and fixed one casting problem to get all C
code compiled. I also extracted all the external symbols successfully.
(AIX requirement) However, I get the following message at link time:

ld: 0711-362 ERROR: Glink code cannot be added for function: _ptrgl
This function is used by compilers and must be called directly.

Shared libraries are a bit more tricky on AIX, but I thought I had the
routine pretty well figured out. I am at a complete loss here.

Andreas, could you give it a try?

That's really interesting. The only difference (of interest)
I can see between my Makefile and that of contrib/spi (where
refint and autoinc are located which afaik are used in the
regression test) is that I missed to add CFLAGS_SL to the
CFLAGS. Seems that one only contains -fpic.

Could you try to use

CFLAGS+= $(CFLAGS_SL) -I$(LIBPQDIR) -I$(SRCDIR)/include

in line 22 of my Makefile?

Jan

--

#======================================================================#
# It's easier to get forgiveness for being wrong than for being right. #
# Let's break this rule - forgive me. #
#======================================== jwieck@debis.com (Jan Wieck) #

#4Keith Parks
emkxp01@mtcc.demon.co.uk
In reply to: Noname (#3)
Re: [HACKERS] PL/pgSQL in template1?

Jan,

It builds and runs fine on S/Linux (Linux on a Sun SPARC)

I must admit I was mighty impressed with it's capabilities,
courtesy of the demo/test database.

One day I'll find a problem that I can solve using PL/pgSQL,
until then It's comforting to know it's there.

For anyone who hasn't taken a look yet, it's well worth it.

Keith.

jwieck@debis.com (Jan Wieck)

Show quoted text

Hi,

I wonder if anyone ever played around with PL/pgSQL. So far
(except for the missing Makefile) I got no response if it
compiles/works on other platforms than my Linux.

Since there are only a few details left in the rewrite code
for 6.4 I would like to get back on it. I think 6.4 BETA is
the right time to check if it works on all the platforms (6.4
is the first time we ship it).

I would do it by adding a build/install with (errors ignored
first) to the Makefiles. Then another regression test could
check if it works.

Comments?