W3C home > Mailing lists > Public > www-archive@w3.org > December 2011

Boost::Graph patch for MSVC++ compatibility

From: Bjoern Hoehrmann <derhoermi@gmx.net>
Date: Sat, 17 Dec 2011 04:54:03 +0100
To: bug-boost-graph@rt.cpan.org
Message-ID: <vp1oe7h6he5a92cfcf4uv47q1697hnlvnl@hive.bjoern.hoehrmann.de>
Hi,

  Currently Boost::Graph hardcodes g++ as compiler. The attached patch
has some crude logic that picks MSVC++ as compiler on Win32 systems.
With that, the right, in my case anyway, compiler is used, but then
there are a bunch of compilation problems, mostly relating to symbols
that overlap between the Windows, C++ runtime, Boost, and Perl. I've
re-ordered things and added some #undef instructions to work around.
Then boost has two overloads, one with a `char` argument and one with
the same argument as `bool`. In MSVC++ `bool` is a `char`, so it does
not like that. I've commented that out.

With all that, the module compiles and links, but the #53 test in
`t/Graph.t` results in segmentation violation. Somehow the `_changed`
member does not seem to be updated properly, if I change the method
`BoostGraph_undirected_i<G>::connectedComponents()` so it also checks
for `this->boostGraph` being null, all tests pass. I don't see what
might be causing this.

regards,
-- 
Björn Höhrmann · mailto:bjoern@hoehrmann.de · http://bjoern.hoehrmann.de
Am Badedeich 7 · Telefon: +49(0)160/4415681 · http://www.bjoernsworld.de
25899 Dagebüll · PGP Pub. KeyID: 0xA4357E78 · http://www.websitedev.de/ 

Received on Saturday, 17 December 2011 03:54:38 UTC

This archive was generated by hypermail 2.4.0 : Friday, 17 January 2020 22:34:11 UTC