build icon indicating copy to clipboard operation
build copied to clipboard

Support negation of requirements

Open Flamefire opened this issue 5 years ago • 4 comments

If you want to build something on Windows only my current solution was: <build>no <target-os>windows:<build>yes

However this causes conflicts when any other rule (e.g. C++11 requirements) adds a <build>no too

Hence it would be great if negation like <target-os>!windows:<build>no would be supported

The current solution involves a rather clunky conditional and a function

Flamefire avatar May 19 '20 11:05 Flamefire

#594 is related as per https://lists.boost.org/Archives/boost/2020/05/248931.php

mloskot avatar May 19 '20 14:05 mloskot

If I read this correctly this already exists as !<target-os>windows:<build>no. Is this correct?

Flamefire avatar May 19 '20 15:05 Flamefire

Yes, but there seems to be another quirk that prevents to use negation on the first statement. I opened a PR with the error message reporting fix #611, and you are welcome to fix the bug itself.

Kojoley avatar May 19 '20 21:05 Kojoley

Thank you for your contributions. Main development of B2 has moved to https://github.com/bfgroup/b2 This issue has been automatically marked as "transition" to indicate the potential for needing transition to the new B2 development project.

stale[bot] avatar May 29 '21 17:05 stale[bot]