Boost logo

Boost Users :

From: Vladimir Prus (ghost_at_[hidden])
Date: 2006-11-16 01:54:37


Gennadiy Rozental wrote:

>
> "Chris Hoeppler" <hoeppler_at_[hidden]> wrote in message
> news:200611160706.29326.hoeppler_at_gmx.net...
>
>> /usr/lib/gcc/i586-suse-linux/4.1.0/../../../crt1.o: In function `_start':
>> init.c:(.text+0x18): undefined reference to `main'
>> collect2: ld returned 1 exit status
>>
>>
>> Addidtional information:
>> This is gcc-4.1.0 on linux. The boost libs were built with the boost
>> build system. I am setting up test_suits as follows:
>>
>> test_suite*
>> init_unit_test_suite( int, char* [] ) {
>> test_suite* test(BOOST_TEST_SUITE("Unit test macros"));
>>
>> // <snip>
>>
>> return test;
>> }
>>
>>
>> Any idea what's going wrong?
>
> I am not sure how did it work before,

It worked before because V2 was building DLL without setting
BOOST_TEST_DYN_LINK, so Boost.Test was defining the main function, and it
worked.

> but above code couldn't be used with
> DLL design that comes with 1.34. My guess is you somehow were using old
> dynamic library that only worked on non-NT platforms, but included main.
> With latest Volodia's changes you are now forced to comply to the proper
> interfaces in latest design.

And the primary reason for Jamfile change was that they worked differently
from V1 Jamfiles. I have no opinion whether additional inconvenience on
Linux outweight advantages of portability to Windows -- that's Gennadiy's
design decision.

- Volodya


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