Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.server -> Problem Linking Pro*C apps on a RedHat 5.2 Machine

Problem Linking Pro*C apps on a RedHat 5.2 Machine

From: Chuck <chuck_at_c64058-c.plstn1.sfba.home.com>
Date: Fri, 16 Apr 1999 14:49:29 GMT
Message-ID: <Z5IR2.225$sP6.437@news.rdc1.sfba.home.com>


I am new to Pro*C and Oracle development and I am trying to develop some simple applications that query my 805 database running on a RedHat 5.0.2 machine.

The code precompiles without any problems using Oracle's precompiler, proc.

I then try and compile the resulting source file with GCC 2.7.2.3 and get complaints about undefined references which I am sure are caused by a library I am not linking. I have tried linking just about every library in the Oracle lib directories to no avail.

Here are the compiler messages:

/tmp/cca152341.o: In function `main':
/tmp/cca152341.o(.text+0x1bf): undefined reference to `sqlcxt'
/tmp/cca152341.o(.text+0x3a4): undefined reference to `sqlcxt'
/tmp/cca152341.o(.text+0x445): undefined reference to `sqlcxt'

The source code is real simple, containing only a simple select statement using no variables. I am just trying to get a connection to the database and display what was returned.

What would be the exact syntax I would use to link this library during compile time? Also, I have collected nearly every piece of Oracle documentation I can find and everything refers to this library as LIBSQL. I am no stranger to linking libraries and using the GCC compiler, but the answer to this eludes me.

Thanks a bunch,
Chuck Received on Fri Apr 16 1999 - 09:49:29 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US