|
Boost Users : |
Subject: [Boost-users] can't build an official example on eclipse
From: loveley (lolveley_at_[hidden])
Date: 2009-12-11 19:26:06
hello,
I have an issue while trying to run boost for the first time.
I downloaded boost on my mac snow leopard, with eclipse.
I compiled the sources(with bjam, without options), and I added the
"include" directory (ie boost_1_41_0/boost)and the "libs" one (ie
boost_1_41_0/libs) in eclipse.
the example I used is the one provided by the official tutorial :
******************************************************
#define BOOST_TEST_MODULE MyTest
#include <boost/test/unit_test.hpp>
int add( int i, int j ) { return i+j; }
BOOST_AUTO_TEST_CASE( my_test )
{
// seven ways to detect and report the same error:
BOOST_CHECK( add( 2,2 ) == 4 ); // #1 continues on error
BOOST_REQUIRE( add( 2,2 ) == 4 ); // #2 throws on error
if( add( 2,2 ) != 4 )
BOOST_ERROR( "Ouch..." ); // #3 continues on error
if( add( 2,2 ) != 4 )
BOOST_FAIL( "Ouch..." ); // #4 throws on error
if( add( 2,2 ) != 4 ) throw "Ouch..."; // #5 throws on error
BOOST_CHECK_MESSAGE( add( 2,2 ) == 4, // #6 continues on error
"add(..) result: " << add( 2,2 ) );
BOOST_CHECK_EQUAL( add( 2,2 ), 4 ); // #7 continues on error
}
******************************************************
and the error is:
http://pastebin.com/m4c85af13 .
can you help me?
thank you,
olivier.
******************************************************
___________________________________________________________________________
Yahoo! Mail réinvente le mail ! Découvrez le nouveau Yahoo! Mail et son interface révolutionnaire.
http://fr.mail.yahoo.com
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