This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: Linking?
- From: Zack Weinberg <zack at codesourcery dot com>
- To: Hermione Granger <herm_oh_ninny at hotmail dot com>
- Cc: gcc at gnu dot org
- Date: Sun, 6 Oct 2002 22:21:50 -0700
- Subject: Re: Linking?
- References: <F1143tAFxZSHGxxhe1M00003443@hotmail.com>
On Mon, Oct 07, 2002 at 05:38:15AM +0100, Hermione Granger wrote:
> This is the command I run:
> g++ main.o db.o prime.o /usr/lib/libbig_num.so -o prime -ldb_cxx
> This is the error message I get:
> db.o: In function `Prime_func::store(unsigned long)':
> db.o(.text+0x39): undefined reference to `Dbt::Dbt[in-charge](void*,
> unsigned)'
Odds are that libdb_cxx was compiled with a different version of g++
than db.o. We have not yet achieved binary compatibility between g++
releases - the hope is that 3.2 will be compatible with releases after
that (in at least one mode) but as there haven't been any releases
after 3.2 yet, well...
You will need to rebuild your program with the same compiler version
used to build libdb_cxx, or vice versa.
zw