Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

TclAqua, Snow Leopard, pgtcl -- port install fail -- TDBC??

Status
Not open for further replies.

RootlessAgrarian

Programmer
Dec 1, 2013
2
CA
I've been out of the software world for a handful of years and am now attempting to reconstruct my favourite toolkit -- Tcl/Tk, TclX (and a few other extensions), and database connectivity extensions for mysql and postgresql.

I'm working on a bit of a legacy platform here -- Snow Leopard (fully patched). This leaves me at postgresql83 and tcl8.4, if that matters.

I'd like to be doing some postgres app development but I am having difficulty getting the toolkit together. Installed my Tcl suite by way of TclAqua, which doesn't seem to include any database support other than generic ODBC. I tried "port install pgtcl" on the Mac -- this attempted to run, but then failed with obscure compiler errors

:info:build ./generic/pgtclCmds.c: In function ‘Pg_lo_read’:
:info:build ./generic/pgtclCmds.c:1948: warning: pointer targets in passing argument 1 of ‘tclStubsPtr->tcl_NewByteArrayObj’ differ in signedness
:info:build ./generic/pgtclCmds.c: In function ‘Pg_lo_write’:
:info:build ./generic/pgtclCmds.c:1997: warning: pointer targets in assignment differ in signedness
:info:build ./generic/pgtclCmds.c: In function ‘Pg_lo_export’:
:info:build ./generic/pgtclCmds.c:2305: warning: pointer targets in passing argument 3 of ‘tclStubsPtr->tcl_GetIntFromObj’ differ in signedness
:info:build ./generic/pgtclCmds.c: In function ‘Pg_select’:
:info:build ./generic/pgtclCmds.c:2437: error: ‘Tcl_Interp’ has no member named ‘errorLine’
:info:build ./generic/pgtclCmds.c: In function ‘Pg_escapeBytea’:
:info:build ./generic/pgtclCmds.c:3215: warning: passing argument 2 of ‘tclStubsPtr->tcl_GetByteArrayFromObj’ from incompatible pointer type
:info:build ./generic/pgtclCmds.c:3225: warning: pointer targets in passing argument 1 of ‘tclStubsPtr->tcl_NewStringObj’ differ in signedness
:info:build ./generic/pgtclCmds.c: In function ‘Pg_unescapeBytea’:
:info:build ./generic/pgtclCmds.c:3272: warning: pointer targets in assignment differ in signedness
:info:build ./generic/pgtclCmds.c:3273: warning: passing argument 2 of ‘PQunescapeBytea’ from incompatible pointer type
:info:build make: *** [pgtclCmds.o] Error 1

I then read a bit about a recent extension TDBC which seems to offer support for many different database servers, but afaik it is rolled into Tcl8.6 -- for which I think there is no Aqua, or at least not one for my Snow Leopard platform.

So I'm kinda stuck here. It's been a looong time since I had to crawl around inside the source code for extensions (the builds were getting pretty reliable) and I'm not keen on spending hours or days trying to debug this compile error. Any advice would be extremely welcome!

1) does TDBC offer multiple database server support? can I install it for Tcl84?
2) has anyone seen this pgtcl error before and is there a known fix?
3) is there any other version of TclAqua that does include database support?
 
I have not experience with MacOS, but maybe you could be successful with other Tcl distribution: ActiveTcl
There is an package managemet called TEAPOT with client called TEACUP.
It gives me following result when I tried to query it for TDBC and postgres?

Code:
$ teacup search TDBC

entity   name           version platform
-------- -------------- ------- ----------------------
redirect tdbc           1.0.0   aix-powerpc            Business Edition Only --- License required
redirect tdbc           1.0.0   hpux-parisc            Business Edition Only --- License required
package  tdbc           1.0.0   linux-glibc2.3-ix86
package  tdbc           1.0.0   linux-glibc2.3-x86_64
package  tdbc           1.0.0   macosx-universal
package  tdbc           1.0.0   macosx10.5-i386-x86_64
redirect tdbc           1.0.0   solaris2.8-sparc       Business Edition Only --- License required
redirect tdbc           1.0.0   solaris2.10-ix86       Business Edition Only --- License required
package  tdbc           1.0.0   win32-ix86
redirect tdbc           1.0.0   win32-x86_64           Business Edition Only --- License required
redirect tdbc           1.0b15  aix-powerpc            Business Edition Only --- License required
redirect tdbc           1.0b15  hpux-parisc            Business Edition Only --- License required
package  tdbc           1.0b15  linux-glibc2.3-ix86
package  tdbc           1.0b15  linux-glibc2.3-x86_64
package  tdbc           1.0b15  macosx-universal
package  tdbc           1.0b15  macosx10.5-i386-x86_64
redirect tdbc           1.0b15  solaris2.8-sparc       Business Edition Only --- License required
redirect tdbc           1.0b15  solaris2.10-ix86       Business Edition Only --- License required
package  tdbc           1.0b15  win32-ix86
redirect tdbc           1.0b15  win32-x86_64           Business Edition Only --- License required
redirect tdbc           1.0b16  aix-powerpc            Business Edition Only --- License required
redirect tdbc           1.0b16  hpux-parisc            Business Edition Only --- License required
package  tdbc           1.0b16  linux-glibc2.3-ix86
package  tdbc           1.0b16  linux-glibc2.3-x86_64
package  tdbc           1.0b16  macosx-universal
package  tdbc           1.0b16  macosx10.5-i386-x86_64
redirect tdbc           1.0b16  solaris2.8-sparc       Business Edition Only --- License required
redirect tdbc           1.0b16  solaris2.10-ix86       Business Edition Only --- License required
redirect tdbc           1.0b17  aix-powerpc            Business Edition Only --- License required
redirect tdbc           1.0b17  hpux-parisc            Business Edition Only --- License required
package  tdbc           1.0b17  linux-glibc2.3-ix86
package  tdbc           1.0b17  linux-glibc2.3-x86_64
package  tdbc           1.0b17  macosx-universal
package  tdbc           1.0b17  macosx10.5-i386-x86_64
redirect tdbc           1.0b17  solaris2.8-sparc       Business Edition Only --- License required
redirect tdbc           1.0b17  solaris2.10-ix86       Business Edition Only --- License required
redirect tdbc::mysql    1.0.0   hpux-parisc            Business Edition Only --- License required
package  tdbc::mysql    1.0.0   linux-glibc2.3-ix86
package  tdbc::mysql    1.0.0   linux-glibc2.3-x86_64
package  tdbc::mysql    1.0.0   macosx-universal
package  tdbc::mysql    1.0.0   macosx10.5-i386-x86_64
redirect tdbc::mysql    1.0.0   solaris2.8-sparc       Business Edition Only --- License required
redirect tdbc::mysql    1.0.0   solaris2.10-ix86       Business Edition Only --- License required
package  tdbc::mysql    1.0.0   win32-ix86
redirect tdbc::mysql    1.0.0   win32-x86_64           Business Edition Only --- License required
redirect tdbc::mysql    1.0b15  aix-powerpc            Business Edition Only --- License required
redirect tdbc::mysql    1.0b15  hpux-parisc            Business Edition Only --- License required
package  tdbc::mysql    1.0b15  linux-glibc2.3-ix86
package  tdbc::mysql    1.0b15  linux-glibc2.3-x86_64
package  tdbc::mysql    1.0b15  macosx-universal
package  tdbc::mysql    1.0b15  macosx10.5-i386-x86_64
redirect tdbc::mysql    1.0b15  solaris2.8-sparc       Business Edition Only --- License required
redirect tdbc::mysql    1.0b15  solaris2.10-ix86       Business Edition Only --- License required
package  tdbc::mysql    1.0b15  win32-ix86
redirect tdbc::mysql    1.0b15  win32-x86_64           Business Edition Only --- License required
redirect tdbc::odbc     1.0.0   hpux-parisc            Business Edition Only --- License required
package  tdbc::odbc     1.0.0   linux-glibc2.3-ix86
package  tdbc::odbc     1.0.0   linux-glibc2.3-x86_64
package  tdbc::odbc     1.0.0   macosx-universal
package  tdbc::odbc     1.0.0   macosx10.5-i386-x86_64
redirect tdbc::odbc     1.0.0   solaris2.8-sparc       Business Edition Only --- License required
redirect tdbc::odbc     1.0.0   solaris2.10-ix86       Business Edition Only --- License required
package  tdbc::odbc     1.0.0   win32-ix86
redirect tdbc::odbc     1.0.0   win32-x86_64           Business Edition Only --- License required
redirect tdbc::odbc     1.0b15  aix-powerpc            Business Edition Only --- License required
redirect tdbc::odbc     1.0b15  hpux-parisc            Business Edition Only --- License required
package  tdbc::odbc     1.0b15  linux-glibc2.3-ix86
package  tdbc::odbc     1.0b15  linux-glibc2.3-x86_64
package  tdbc::odbc     1.0b15  macosx-universal
package  tdbc::odbc     1.0b15  macosx10.5-i386-x86_64
redirect tdbc::odbc     1.0b15  solaris2.8-sparc       Business Edition Only --- License required
redirect tdbc::odbc     1.0b15  solaris2.10-ix86       Business Edition Only --- License required
package  tdbc::odbc     1.0b15  win32-ix86
redirect tdbc::odbc     1.0b15  win32-x86_64           Business Edition Only --- License required
redirect tdbc::postgres 1.0.0   hpux-parisc            Business Edition Only --- License required
package  tdbc::postgres 1.0.0   linux-glibc2.3-ix86
package  tdbc::postgres 1.0.0   linux-glibc2.3-x86_64
package  tdbc::postgres 1.0.0   macosx-universal
package  tdbc::postgres 1.0.0   macosx10.5-i386-x86_64
redirect tdbc::postgres 1.0.0   solaris2.8-sparc       Business Edition Only --- License required
redirect tdbc::postgres 1.0.0   solaris2.10-ix86       Business Edition Only --- License required
package  tdbc::postgres 1.0.0   win32-ix86
redirect tdbc::postgres 1.0.0   win32-x86_64           Business Edition Only --- License required
redirect tdbc::postgres 1.0b15  aix-powerpc            Business Edition Only --- License required
redirect tdbc::postgres 1.0b15  hpux-parisc            Business Edition Only --- License required
package  tdbc::postgres 1.0b15  linux-glibc2.3-ix86
package  tdbc::postgres 1.0b15  linux-glibc2.3-x86_64
package  tdbc::postgres 1.0b15  macosx-universal
package  tdbc::postgres 1.0b15  macosx10.5-i386-x86_64
redirect tdbc::postgres 1.0b15  solaris2.8-sparc       Business Edition Only --- License required
redirect tdbc::postgres 1.0b15  solaris2.10-ix86       Business Edition Only --- License required
package  tdbc::postgres 1.0b15  win32-ix86
redirect tdbc::postgres 1.0b15  win32-x86_64           Business Edition Only --- License required
package  tdbc::sqlite3  1.0.0   tcl
package  tdbc::sqlite3  1.0b15  tcl
package  tdbc::sqlite3  1.0b17  tcl
-------- -------------- ------- ----------------------
96 entities found

Code:
$ teacup search postgress

entity   name           version platform
-------- -------------- ------- ----------------------
redirect tdbc::postgres 1.0.0   hpux-parisc            Business Edition Only --- License required
package  tdbc::postgres 1.0.0   linux-glibc2.3-ix86
package  tdbc::postgres 1.0.0   linux-glibc2.3-x86_64
package  tdbc::postgres 1.0.0   macosx-universal
package  tdbc::postgres 1.0.0   macosx10.5-i386-x86_64
redirect tdbc::postgres 1.0.0   solaris2.8-sparc       Business Edition Only --- License required
redirect tdbc::postgres 1.0.0   solaris2.10-ix86       Business Edition Only --- License required
package  tdbc::postgres 1.0.0   win32-ix86
redirect tdbc::postgres 1.0.0   win32-x86_64           Business Edition Only --- License required
redirect tdbc::postgres 1.0b15  aix-powerpc            Business Edition Only --- License required
redirect tdbc::postgres 1.0b15  hpux-parisc            Business Edition Only --- License required
package  tdbc::postgres 1.0b15  linux-glibc2.3-ix86
package  tdbc::postgres 1.0b15  linux-glibc2.3-x86_64
package  tdbc::postgres 1.0b15  macosx-universal
package  tdbc::postgres 1.0b15  macosx10.5-i386-x86_64
redirect tdbc::postgres 1.0b15  solaris2.8-sparc       Business Edition Only --- License required
redirect tdbc::postgres 1.0b15  solaris2.10-ix86       Business Edition Only --- License required
package  tdbc::postgres 1.0b15  win32-ix86
redirect tdbc::postgres 1.0b15  win32-x86_64           Business Edition Only --- License required
-------- -------------- ------- ----------------------
19 entities found
 
Look at [highlight]package tdbc::postgres 1.0.0 macosx-universal[/highlight]
 
Thanks mikrom. I ended up following exactly that route -- got ActiveTcl (8.6 current rev) and put my toolkit together on that base. Everything has gone quite well -- tdbc easy to use, well documented. I'm now at a more obscure and less important impasse with an extension called "snack" -- possibly too obscure to be worth pursuing, as I have only an academic interest in Snack.

Thanks for the info, which I hope may also help others trying to get tooled up to work with Tcl and Postgres!

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top