Boost logo

Boost :

From: Tobias Schwinger (tschwinger_at_[hidden])
Date: 2006-04-12 13:02:28


Rene Rivera wrote:
>
> #ifdef __WIN32__
> #include <win32/myfile.hpp>
> #elif ...
> ...
> #endif
>
>
> So that dependency analysis works with Boost.Build without yet more
> special case kludges ;-) And so that people with smart text editors can
> select the include file and open it directly. And so that other people
> reading the code have a chance at understanding it.
>

;-)

I still prefer having an appropriate include path set by the build system.
However, the OP asked how to #include files with macro-ized names...

The code above looks like a copy-and-paste solution (given the project has
more than one platform dependent translation unit).
But while we're at it: it's probably not too bad of an idea to have
BOOST_PLATFORM_<PLATFORM> or something like that defined by Boost.Config to
normalize between the different name/underscore combinations there are (see
boost/config/select_platform_config.hpp)...

Regards,

Tobias


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