Received: from fw.wintelcom.net (bright@ns1.wintelcom.net [209.1.153.20]) by hub.org (8.10.1/8.11.0) with ESMTP id e9RMFLZ36861 for ; Fri, 27 Oct 2000 18:15:21 -0400 (EDT) (envelope-from bright@fw.wintelcom.net) Received: (from bright@localhost) by fw.wintelcom.net (8.10.0/8.10.0) id e9RMFCB11696; Fri, 27 Oct 2000 15:15:12 -0700 (PDT) Date: Fri, 27 Oct 2000 15:15:12 -0700 From: Alfred Perlstein To: "Gustavo R. Bonet" Cc: pgsql-interfaces@postgresql.org Subject: Re: C program compilation Message-ID: <20001027151511.J28123@fw.wintelcom.net> References: Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.2.4i In-Reply-To: ; from gbonet@bna.com.ar on Fri, Oct 27, 2000 at 01:07:12PM -0300 X-Archive-Number: 200010/247 X-Sequence-Number: 1606 * Gustavo R. Bonet [001027 14:54] wrote: > I'm a beginner in PostGreSQL and I'm trying to meka my first interface with > a C > program. > > Like the documentation says, I'm using the following sentence to compile: > > gcc -o output_name -I /usr/include/pgsql -lpq myprogram.c > > But, in two diferent Linux servers the answer was: > > /usr/lib/libpq.so: undefined reference to `crypt' > collect2: ld returned 1 exit status try adding '-lcrypt' to the compile flags. -Alfred (who also stumbled on this)