Boost logo

Boost-Build :

Subject: [Boost-build] generating headers out of Jamfile
From: Oliver Kowalke (oliver.kowalke_at_[hidden])
Date: 2011-01-28 17:56:43

how can I generate headers out of a Jamfile (if possible)?

current Jamfile:

alias sources
    : xyz_windows.cpp
    : <architecture>abc

alias sources
    : xyz_posix.cpp
    : <architecture>uvw

explicit sources ;

lib boost_xyz
    : sources
    : <link>shared:<define>BOOST_XYZ_DYN_LINK=1

boost-install boost_xyz ;

I'd like to generate header xyz.hpp out of some template files
xyz_windows.hpp and xyz_posix.hpp.

The idea is to prevent preprocessor stuff dealing with compiler, os,
architecture etc (especially such thinks like properites <address-model>
and <instruction-set> etc.).

currently I've solvte the problem with the pimpl idiom but this requires
a memory allocation which I'd like to prevent. So generating the head
xyz.hpp depending on the properties given to Jamfile would be the best
solution (the header file must be generated in <boost-root>/boost/xyz/)..

thx, Oliver

Boost-Build list run by bdawes at, david.abrahams at, gregod at, cpdaniel at, john at