Skip site navigation (1) Skip section navigation (2)

Re: errcode redefinition

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Andrew Vick <avick(at)remote-print(dot)com>
Cc: pgsql-ports(at)postgresql(dot)org
Subject: Re: errcode redefinition
Date: 2006-06-16 00:36:26
Message-ID: (view raw, whole thread or download thread mbox)
Lists: pgsql-ports
Andrew Vick <avick(at)remote-print(dot)com> writes:
> Tom Lane wrote:
>> Where were those coming from?  I'm trying to burrow down to what they're
>> really after that's forcing them to include headers they shouldn't be
>> including ...

> In Postgres, the errors were coming from pg_type.h.
> In Qt. they were coming from src/sql/drivers/psql/qsql_psql.cpp.

> I've glanced through the Qt source, and I don't see any places where
> they try to access the members of any Postgres structures.

If you remove the inclusion of pg_type.h, does it build?  I'm thinking
maybe the reason for this pushup is that they need access to the type
OID macros in pg_type.h (INT4OID and friends).  I've been thinking
that we need to provide a way for frontend apps to use those macros
without including a bunch of backend-only stuff --- if that's what's
going on here, that would be ammunition to propose a change.

I'd appreciate it if you include postgres_fe.h instead of postgres.h,
remove any other PG header inclusions that cause errors without
postgres.h, and then see what errors are left in the Qt code.

			regards, tom lane

In response to

pgsql-ports by date

Next:From: Marc LepageDate: 2006-06-26 18:34:05
Subject: gettimeofday problem with mingw
Previous:From: Andrew VickDate: 2006-06-15 22:27:56
Subject: Re: errcode redefinition

Privacy Policy | About PostgreSQL
Copyright © 1996-2017 The PostgreSQL Global Development Group