Boost logo

Boost Users :

Subject: Re: [Boost-users] issues with unit tests on intel 32 bit, gcc 4.3, undefined reference to `__sync_fetch_and_add_4'
From: Gennadiy Rozental (rogeeff_at_[hidden])
Date: 2009-04-13 17:10:35


Maróy Ákos <akos <at> maroy.hu> writes:

>
> Hi,
>
> I'm having an issue to link a boost unit test application on a Linux
> box, which is 64 bit - but I want to create a 32 bit application.

How did you build Boot.Test library? what variant r u using? Static or shared?

> I'm trying to compile & link the following simple sample app:
>
> #include <boost/test/unit_test.hpp>
>
> using namespace boost::unit_test;
>
> test_suite *
> init_unit_test_suite(int, char ** const) {
> test_suite *ts = BOOST_TEST_SUITE("test_suite");
> framework::master_test_suite().add(ts);
>
> return 0;
> }
>
> I get the following results:

...

/home/maroy/src/tyrell/src/darksweep/usr/lib/
libboost_test_exec_monitor-gcc43-mt-s.a(framework.o):

You should not use test_exec_monitor. You should link with
boost_unit_test_framework.

I'd suggest you to try to use single header variant of Boost.Test
and thus avoid any linking issues.

> $ g++ --version
> g++ (Ubuntu 4.3.2-1ubuntu12) 4.3.2
> $ uname -a
> Linux tomodachi 2.6.27-11-generic #1 SMP Wed Apr 1 20:53:41 UTC 2009
> x86_64 GNU/Linux

I can try to reproduce this. But I'll need to find vmware image for that.
Do you know where i can find one?

Gennadiy


Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net