|
Boost Users : |
Subject: Re: [Boost-users] [thread] mixing boost::mutex from different boost versions
From: Anthony Williams (anthony.ajw_at_[hidden])
Date: 2009-05-13 17:35:30
klaus triendl <klaus_at_triendl.eu> writes:
> Anthony Williams schrieb:
>> klaus triendl <klaus_at_triendl.eu> writes:
>>
>>> are boost::mutexes from different boost versions ABI compatible,
>>> provided that the modules (boost thread library, my own) are compiled
>>> with the same compiler?
>>
>> In general, no. In particular cases, yes: the boost::mutex
>> implementation changes very rarely.
>>
>> The breaking changes I can remember were 1.34.1/1.35.0 and
>> 1.35.0/1.36.0
>>
>>> My question arises because I'm creating a windows DLL with class
>>> methods taking a boost::mutex& from let's say boost 1.38, but an
>>> application (the EXE) might use e.g. boost 1.39.
>>
>> Boost 1.38 and 1.39 should be compatible; the code is almost completely
>> unchanged (I think there was a fix for some broken code, but the old
>> version was broken).
>
> Do the breaking changes concerning the ABI get announced somewhere?
If I remember then they go in the release announcement and thread
docs. In general, you cannot rely on boost libraries being ABI
compatible between releases (though some libraries do try to maintain
compatibility).
> The DLL compiled with boost mutex from 1.38 and the application using
> boost 1.39 are just examples.
> If I could specify a boost version range for the DLL's usage howto,
> this would be helpful.
I understand.
Anthony
-- Author of C++ Concurrency in Action | http://www.manning.com/williams just::thread C++0x thread library | http://www.stdthread.co.uk Just Software Solutions Ltd | http://www.justsoftwaresolutions.co.uk 15 Carrallack Mews, St Just, Cornwall, TR19 7UL, UK. Company No. 5478976
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