Re: Cygwin PostgreSQL with TCL support (was Re: hi)

From: s0lao(at)netscape(dot)net (S(dot) L(dot))
To: Jason(dot)Tishler(at)dothill(dot)com
Cc: guard(at)ficnet(dot)net, pgsql-cygwin(at)postgresql(dot)org
Subject: Re: Cygwin PostgreSQL with TCL support (was Re: hi)
Date: 2001-06-19 10:33:52
Message-ID: 6DE6F116.09FDD448.00013D13@netscape.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-cygwin

[I thought this thread was closed ;]

Jason Tishler <Jason(dot)Tishler(at)dothill(dot)com> wrote:
>
> On Sun, Jun 17, 2001 at 10:35:49PM +0800, guard wrote:
> > please help me,
> > I have urgent question,I can not install pgsql 7.1 in cygwin + tcl support
> > I have look you reply mail In
> > http://www.ca.postgresql.org/mhonarc/pgsql-ports/2001-05/msg00024.html
> > but I can not download and not install,please tell me detailed step install
> > pgsql 7.1+cygwin+tcl
> > very thanks

guard,

To quote from your last private message related to the above pgsql-ports thread:

> I have make ok pgsql
> have make pgtcl.dll
> but i create pltcl Error
>
> My step......
>
> $psql database
>     CREATE FUNCTION pltcl_call_handler () RETURNS OPAQUE AS
>         '/usr/local/pgsql/lib/pgtcl.dll' LANGUAGE 'C';
>
> Error: ERROR: Can't find function pltcl_call_handler in file
> /usr/local/pgsql/lib/pgtcl.dll
>

This looks like you don't want to use PostgreSQL from tcl/tk scripts (where pgtcl.dll is needed), but you'd rather want to use tcl programming language from inside PostgreSQL (where should be needed pltcl.dll). To use a language from those in src/pl, you should first either do a createlang command, or a CREATE LANGUAGE statement for a database.

Here's how you should build pltcl.dll.
The source is found in src/pl/tcl. There are some differences from building pgtcl, but here are the steps:

1. You should edit by hand Makefile.tcldefs
a. You must set TCL_SHARED_BUILD = 1 , else the make would notice the extension can't be build.
b. For the other lines having right values in form @VALUE@, you should delete the @VALUES(at)(dot)

2. Like the case of pgtcl, the dllwrap command won't add "-ltcl80" option, so you must add it by hand. In my case, I had to add "-L../../backend -lpostgres" also.

My dllwrap command was:

"dllwrap -o pltcl.dll --def pltcl.def pltcl.o ../../../src/utils/dllinit.o -lcygipc -lcrypt -ltcl80 -L../../backend -lpostgres"

That should be it.

SLao
__________________________________________________________________
Get your own FREE, personal Netscape Webmail account today at http://webmail.netscape.com/

In response to

Responses

Browse pgsql-cygwin by date

  From Date Subject
Next Message Jason Tishler 2001-06-19 15:44:15 Re: Configuration of PostgrSQL on NT server
Previous Message S. L. 2001-06-19 05:56:34 Re: Problem with pgsql-cygwin