|
Boost-Build : |
From: Hassan Mehmet (hassan_mehmet_at_[hidden])
Date: 2007-06-19 11:13:44
Matthias Troyer <troyer <at> phys.ethz.ch> writes:
>
> Hi,
>
> I have a question about linking external libraries. For example, for
> the HDF5 library we need to link two libraries: hdf5_cpp and hdf5.
>
> Is there a better way then just declaring two library targets as in:
>
> lib hdf5
> :
> : <name>hdf5 <search>/path/lib
> :
> : <include>/path/include
> ;
>
> lib hdf5cpp
> :
> : <name>hdf5_cpp <search>/path/lib <use>hdf5
> :
> : <include>/path/include
> ;
You could specify multiple libraries in a single lib target (per variant)
lib hdf5
:
: <toolset>gcc <variant>release
<file>/path/lib/libhdf5.a
<file>/path/lib/libhdf5_cpp.a
:
: <include>/path/include
;
lib hdf5
:
: <toolset>gcc <variant>debug
<file>/path/lib/libhdf5d.a
<file>/path/lib/libhdf5_cppd.a
:
: <include>/path/include
;
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