Subject: Re: [Boost-build] Would like help debugging MinGW problem
From: Vladimir Prus (ghost_at_[hidden])
Date: 2010-04-20 11:18:22
On Monday 19 April 2010 22:42:02 Jeremiah Willcock wrote:
> On Mon, 19 Apr 2010, Vladimir Prus wrote:
> > On Monday 19 April 2010 20:08:07 Jeremiah Willcock wrote:
> >> The regression test libs/graph/test/graphviz_test.cpp is failing on all
> >> MinGW platforms by throwing an unhandled exception. The code is supposed
> >> to throw an exception, but it is wrapped in a try block that specifically
> >> catches the exception being thrown; this code is around line 193 in the
> >> test case. The test passes on almost all other platforms, including other
> >> GCC configurations and VC++ on Windows. Is this a problem in the
> >> platform? Are there known issues with exceptions on MinGW?
> >> <URL:http://wiki.netbeans.org/MinGWInCCDevelopmentPack> suggests that the
> >> compiler needs -mthreads for exceptions to work properly. Does the
> >> regression test (that doesn't use threads) work with this flag?
> > If you use <threading>multi for your tests, that flag will be used (and
> > that's what the flag actually does). I don't know whether exceptions
> > and multithreading are really mixed like that on mingw.
> Is this problem something that needs to be fixed for Boost in general on
> this platform? If the issue is exceptions being broken without certain
> flags, shouldn't those flags always be provided even without multiple
I don't think so. That flag *is* MT support, so adding it for threading=single
would be mightly confusing. It's possible, both technically and in principle,
to force threading=multi on mingw, if folks familiar with mingw deem that
reasonable. Can somebody comment on this?
It appears that other libraries are also unhappy with mingw exceptions,
e.g. even the simplest compiled library in boost is:
-- Vladimir Prus http://vladimir_prus.blogspot.com Boost.Build: http://boost.org/boost-build2
Boost-Build list run by bdawes at acm.org, david.abrahams at rcn.com, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk