Skip to Content.
Sympa Menu

freetds - [freetds] Undefined references to all database functions

freetds AT lists.ibiblio.org

Subject: FreeTDS Development Group

List archive

Chronological Thread  
  • From: panssarikomppania AT gmail.com
  • To: freetds AT lists.ibiblio.org
  • Subject: [freetds] Undefined references to all database functions
  • Date: Wed, 21 May 2008 18:02:42 +0300

I'm currently coding some software that uses Microsoft SQL as it's database.
The language used is C. The coding itself wasn't a problem at all, but I get
numerous errors when compiling the code. And as this new place where I work
has a strict OS policy, I'm forced to use a Windows machine and an IDE
called Dev-C++. The boss didn't want to make any exceptions like bringing my
own Linux coding laptop where everything works just fine. I somewhat managed
to install FreeTDS on this machine, but the compiling process doesn't go
well at all. I get a total of 71 errors, below are some examples.

main.c: Undefined reference to 'dbinit'.
main.c: Undefined reference to 'dblogin'.
main.c: Undefined reference to 'dbsetluser'.
main.c: Undefined reference to 'dbsetlpwd'.
main.c: Undefined reference to 'dbfcmd'.
main.c: Undefined reference to 'dbsqlexec'.

I think this is a linker problem. I checked that I have included all
necessary header files (sybfront.h and sybdb.h) and that they are where they
should be (C:\path\to\dev-cpp\include\). The linker also knows that it
should link -lsybdb. So what could be wrong? Am I missing some other header
files? Am I missing some libraries? Is the compiler/linker that Dev-C++ uses
just rubbish? Or is this Windows' fault? If I knew what logs or other
informative pieces of text I could include here to make this easier for you,
I'd do it. If only I'd know where to find everything important in this
unlogical directory structure.

Thanks in advance for your time.




Archive powered by MHonArc 2.6.24.

Top of Page