[build2] Reverse Dependency via Defines

Boris Kolpackov boris at codesynthesis.com
Tue Dec 4 14:15:14 UTC 2018

Kalle Møller <build2.org at k-moeller.dk> writes:

> My problem arises as I'm building a library that uses Boost, and depends on
> Booot.Config, and therefore implicit depends on the user supplied config
> (if it is defined).
> As an exercise I thought I would package just the Boost.Config  (as it has
> no other Boost dependencies),  and let my library just depend on that. This
> is where I got stuck. I saw no good way to package and make the
> dependencies, and also let the consumer provide the user config.

The only sensible way to handle this is for the "ultimate consumer"
(i.e., the user that is building things) to provide this configuration.
In which case, a -D option via config.cxx.poptions looks like a good way:


More information about the users mailing list