Changes between Version 3 and Version 4 of AlternativeSelection


Ignore:
Timestamp:
Mar 26, 2007, 3:52:29 AM (19 years ago)
Author:
Dave Abrahams
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • AlternativeSelection

    v3 v4  
    33This page describes a proposal for a change to the way target alternatives are selected.
    44
    5 '''Note:''' the proposal is intended to be a ''pure extension''.  That is, I believe it doesn't change the semantics of any {{{bjam}}} invocation that works today -- it only changes {{{bjam}}} invocations that are currently errors into non-errors.
    6 
    75== Motivation ==
    86
    9 It seems there are a significant number of {{{bjam}}} invocations for which there is a sensible interpretation, but for which Boost.Build currently generates an error instead and refuses to build.  For example, given the following Jamfile:
     7It seems there are a significant number of {{{bjam}}} invocations for which there is a sensible interpretation, but for which Boost.Build currently generates an error instead and refuses to build. 
     8
     9=== Example 1 ===
     10
     11Given the following Jamfile:
    1012
    1113{{{
    12 lib a : a.cpp : <debug-symbols>off ;
    13 lib a : a-dbg.cpp : <debug-symbols>on <profiling>on ;
     14lib a : a.cpp : <debug-symbols>off ;                   # alternative 1
     15lib a : a-dbg.cpp : <debug-symbols>on <profiling>on ;  # alternative 2
    1416}}}
    1517
     
    2931        not matched
    3032}}}
     33 
     34My claim is that it would be more appropriate to build the 2nd alternative because it is a better match for the explicit build request.
     35
     36Boost.Build generates an error because the default value of the {{{<profiling>}}} feature is {{{off}}}.  It combines that default value with the explicit build request to get {{{<debug-symbols>on <profiling>off}}}, which does not match the 2nd alternative.