View Single Post
  #2  
Old 03-13-2003, 08:32 AM
kinook kinook is online now
Administrator
 
Join Date: 03-06-2001
Location: Colorado
Posts: 6,003
Cool

Build rules are evaluated from the bottom up, so even though the parent step is skipped, the child step's build rule is evaluated first to determine if that step will be skipped. It's implemented this way to support the options to nest or not nest build rules and checked status of steps.

There are a couple ways to get around this:

1) Move the child steps of Build Progs into a subroutine and call that subroutine from a child step of Build Progs. Build rules in subroutines are not evaluated if the subroutine isn't called.

2) Use a separate Run Script step to prompt for whether to build, which sets a temporary macro value according to the input, and then have the child step's conditional build rule reference that macro. The prompt step will be skipped if the parent was skipped.

Both methods are demonstrated in the attached file.
Attached Files
File Type: bld conditionalbranching2.bld (2.9 KB, 1501 views)
Reply With Quote