X-Original-To: pgsql-ports-postgresql.org@postgresql.org Received: from localhost (mx1.hub.org [200.46.208.251]) by postgresql.org (Postfix) with ESMTP id E5DDD9FA5D2 for ; Thu, 15 Jun 2006 19:29:12 -0300 (ADT) Received: from postgresql.org ([200.46.204.71]) by localhost (mx1.hub.org [200.46.208.251]) (amavisd-new, port 10024) with ESMTP id 61459-01 for ; Thu, 15 Jun 2006 19:29:03 -0300 (ADT) X-Greylist: from auto-whitelisted by SQLgrey- Received: from remote-print.com (ms92.mailserviceslc.com [216.243.195.92]) by postgresql.org (Postfix) with ESMTP id 326839FA160 for ; Thu, 15 Jun 2006 19:29:02 -0300 (ADT) Received: (qmail 7746 invoked by uid 89); 15 Jun 2006 22:28:47 -0000 Received: from unknown (HELO ?192.168.1.86?) (avick@remote-print.com@192.168.1.86) by www.remote-print.com with SMTP; 15 Jun 2006 22:28:47 -0000 Message-ID: <4491DEEC.8080708@remote-print.com> Date: Thu, 15 Jun 2006 17:27:56 -0500 From: Andrew Vick User-Agent: Mozilla Thunderbird 1.0.2 (X11/20050317) X-Accept-Language: en-us, en MIME-Version: 1.0 To: Tom Lane CC: pgsql-ports@postgresql.org Subject: Re: errcode redefinition References: <4491C692.9080401@remote-print.com> <936.1150405283@sss.pgh.pa.us> <4491D023.7050407@remote-print.com> <1247.1150407088@sss.pgh.pa.us> In-Reply-To: <1247.1150407088@sss.pgh.pa.us> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Virus-Scanned: Maia Mailguard 1.0.1 X-Archive-Number: 200606/10 X-Sequence-Number: 2451 Tom Lane wrote: > Andrew Vick writes: > >>Tom Lane wrote: >> >>>Why are these drivers trying to include elog.h? That's a backend-only >>>header. If the reason is that they're including postgres.h, they should >>>likely be including postgres_fe.h instead. > > >>That is the case. I tried switching it to postgres_fe.h, but then I >>got errors about the pg_type structure not being defined. > > > 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. I believe Qt is just wrapping the C interface to the Postgres libraries; maybe the problem is that this version of Qt (3.3.6) is too old for this version of Postgres (8.1 stable). Perhaps the Postgres headers have changed since the 8.0 release to cause this, and this release of Qt predates the change. If it weren't for that problem with errcode, I might be using an earlier version of Postgres. -Andrew