Re: help compiling psqldobc-08.03.0400 - Mailing list pgsql-odbc
| From | Kulik, Scott |
|---|---|
| Subject | Re: help compiling psqldobc-08.03.0400 |
| Date | |
| Msg-id | 367B33A3B0BA27429CC76B74A71EECC4502CCA@snaex01.ms.severstalna.com Whole thread Raw |
| In response to | Re: help compiling psqldobc-08.03.0400 ("Albe Laurenz" <laurenz.albe@wien.gv.at>) |
| List | pgsql-odbc |
Thanks for the replies. For some reason my emails have been taking a
couple days to go through on the mailing list. I ended up commenting
out some of the ifdef statements to get it to compile:
In odbcapi.c:
#ifdef WITH_UNIXODBC
SQLROWSETSIZE *pcrow,
#else
SQLULEN *pcrow,
#endif /* WITH_UNIXODBC */
I changed to:
SQLULEN *pcrow,
In odbcapi30.c
#if defined(_WIN64)
SQLLEN *NumericAttribute
#elif defined(WITH_UNIXODBC) || defined(WIN32)
SQLPOINTER NumericAttribute
#else
SQLLEN *NumericAttribute
#endif
I changed to:
SQLLEN *NumericAttribute
And in odbcapi30w.c
#if defined(WITH_UNIXODBC) || (defined(WIN32) && ! defined(_WIN64))
SQLPOINTER pNumAttr
#else
SQLLEN *pNumAttr
#endif
I changed to:
SQLLEN *pNumAttr
For some reason even though I have unixODBC installed it didn't like
those values it was defining. I was able to setup a database link
through oracle and everything seems to be working properly. Hopefully,
this won't cause any issues down the road. I would assume anyone else
trying to compile on redhat 64-bit would have the same issues.
Scott k.
-----Original Message-----
From: Albe Laurenz [mailto:laurenz.albe@wien.gv.at]
Sent: Wednesday, July 15, 2009 3:35 AM
To: Kulik, Scott; pgsql-odbc@postgresql.org
Subject: RE: [ODBC] help compiling psqldobc-08.03.0400
Scott Kulik wrote:
> Has anyone had any success compiling psqlodbc on Redhat Linux (I'm
using
> RHEL AS4). I have pretty much tried compiling with with every
> combination of odbc and postgres versions but never had any luck.
>
> I've been trying to figure this out for a few weeks but I think we may
> just have to end up paying the $500/server for the openlink
> driver/support.
>
> Anyone have any suggestions that might save us a few thousand dollars?
I never had any problems with it.
This is my log of a session where I installed 08.02.0500 on a 32-bit
RHEL4 machine:
Prerequisites:
(The first two packages are our own RPMs for PostgreSQL, you can use the
standard "libs" and "devel" packages)
# rpm -U adv-postgres-8.2.5-libs-1-1.i386.rpm
# rpm -U adv-postgres-8.2.5-devel-1-1.i386.rpm
# yum install unixODBC unixODBC-devel
Unpack and compile the software:
(Our packages install PostgreSQL into /magwien/postgres-8.2.5, so you
can just omit these settings with the standard RPMs)
$ cd /home/laurenz
$ export PATH=/magwien/postgres-8.2.5/bin:$PATH
$ tar -xzvf psqlodbc-08.02.0500.tar.gz
$ cd psqlodbc-08.02.0500
$ LDFLAGS=-Wl,-rpath,/magwien/postgres-8.2.5/lib ./configure
--prefix=/magwien/postgres-8.2.5
$ make
Install:
# cd /home/laurenz/psqlodbc-08.02.0500
# make install
You wrote that you encountered problems, but did not describe them.
Yours,
Laurenz Albe
pgsql-odbc by date: