[NTLUG:Discuss] compiling with *.a libs

Cameron hrothgar at endor.hsutx.edu
Mon Dec 6 12:42:36 CST 1999


hello all,
i've downloaded BerkeleyDB (http://www.sleepycat.com) and compiled and
installed it.  when i try to compile a program, i get linker errors,
which i assume mean that ld doesn't like the libdb.a library archive (as
opposed to the .so libs).  could someone fill me in on what i'm doing
wrong or what i need to do to remedy this?

$ make
gcc -Wall -I/usr/local/BerkeleyDB.3.0/include -o dbtest dbtest.c -ldb
/tmp/ccAx4m3Q.o: In function `main':
/tmp/ccAx4m3Q.o(.text+0x12): undefined reference to `db_create'
/tmp/ccAx4m3Q.o(.text+0x21): undefined reference to `db_strerr'
collect2: ld returned 1 exit status
make: *** [dbtest] Error 1

-- 
cameron
  [ Grow up and use mutt (http://www.mutt.org) ]




More information about the Discuss mailing list