Boost logo

Boost :

Subject: Re: [boost] [Booster] Or boost is useless for library developers
From: Stewart, Robert (Robert.Stewart_at_[hidden])
Date: 2010-05-19 07:19:13


Artyom wrote:
>
> > Pre-configuration is, IMO, going backwards. If I have to
> > rely on running some tool to get to the code I want to use
> > it's *much* less likely I'll use that code.
>
> Unfortunately when your write cross platform code for
> multiple compilers
> and libraries it is impossible to do this with any kind of
> configuration.
>
> (See the size of boost/config)

And yet, Boost.Config does just that.

> However, compile time configuration is generally much more reliable
> then any other "defines-only" based.
>
> I have had issues when some important parts of Boost where broken
> on arm platform because of lack of proper configuration.

Relying on platform-specific manifest constants can prevent using certain features due to choosing conservative options by default, and code can fail spectacularly by choosing liberal options by default. Knowing the correct value by introspection is certainly beneficial.

> Simple compile time checks like "check_cxx_source_compiles" would
> save lots of headache in system configuration.
> Not talking about the fact the single config.hpp file would save lots
> of compilation time instead of browsing over tens files in
> boost/config/* directory.

I doubt there would be much compile time savings by moving from tens of files to one.

However, there is value in having an autoconfig-style tool that uses tests to determine platform capabilities and produce a report of needed configuration options. Such a tool could even include the boost/config headers to verify correct settings. It would be terrific for verifying Boost.Config and for determining settings needed for new platforms versus the guessing and trial-and-error approach now used.

> Note: Boost has lots of header only libraries, Boost::abi
> would probably
> have almost any library compiled, so it is reasonable require compile
> time configuration.

I assume you mean configuration information from a separate configure step when you use the phrase, "compile time configuration." (Boost.Config provides compile-time configuration, so the phrase is confusing.) I don't understand why compiled libraries should make a separate configuration step necessary, better, or even more acceptable. The same information is supplied either way.

_____
Rob Stewart robert.stewart_at_[hidden]
Software Engineer, Core Software using std::disclaimer;
Susquehanna International Group, LLP http://www.sig.com

IMPORTANT: The information contained in this email and/or its attachments is confidential. If you are not the intended recipient, please notify the sender immediately by reply and immediately delete this message and all its attachments. Any review, use, reproduction, disclosure or dissemination of this message or any attachment by an unintended recipient is strictly prohibited. Neither this message nor any attachment is intended as or should be construed as an offer, solicitation or recommendation to buy or sell any security or other financial instrument. Neither the sender, his or her employer nor any of their respective affiliates makes any warranties as to the completeness or accuracy of any of the information contained herein or that this message or any of its attachments is free of viruses.


Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk