pg.ddx.io  pgsql-interfaces@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Stephen Whinston <swhinston@pillardata.com>
To: pgsql-interfaces@postgresql.org
Subject: Simple compile question
Date: Wed, 6 Nov 2002 14:42:54 -0700
Message-ID: <0565CAF35FADD64DA09B86C3637BE7291492C2@coex01.trans.corp> (raw)


I just installed pgsql this morning and already encountered some difficulties. How do I compile a C/C++ client application with pgsql? Here's what I do:

gcc -c -I/usr/local/pgsql/include sample.cpp

and I get:

aggregate 'PGconn conn' has incomplete type and cannot be initialized
aggregate 'PGresult res' has incomplete type and cannot be initialized

The libpq-fe.h file *is* in /usr/local/pgsql/include

What other include files am I missing?

Also, a lot of messages seem to indicate that there is sample code under the src/ dir. Where is this? It is not under /usr/local/pgsql. Did I miss a step in the install?

thanks,
Stephen



view thread (3+ messages)  latest in thread

Message-ID: <0565CAF35FADD64DA09B86C3637BE7291492C2@coex01.trans.corp>
Permalink:  ../0565CAF35FADD64DA09B86C3637BE7291492C2@coex01.trans.corp/
Also on:    postgresql.org/message-id/0565CAF35FADD64DA09B86C3637BE7291492C2@coex01.trans.corp

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-interfaces@postgresql.org
  Cc: swhinston@pillardata.com
  Subject: Re: Simple compile question
  In-Reply-To: <0565CAF35FADD64DA09B86C3637BE7291492C2@coex01.trans.corp>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox