title: Visual Studio run custom build tool when dependencies change
body: <p>I have a solution with two C++ projects in Visual Studio 2013.</p>
  
  <p>Project A creates a static library.  Project B produces a SWIG-generated DLL wrapper for A, linking the lib generated by A.  The complicating factor is that B generates code using a "Custom Build Step", set to execute before ClCompile. The custom build step calls out to an external tool to generate wrapper code based on classes defined in header files in project A.  If the generation completes successfully, project B builds a DLL from the generated code, linking against the .lib generated in project A.</p>
  
  <p>The problem I have is that the custom step in B is occurring on every build (as one would expect), but I'd like to make it happen when there are changes to header files in A.  I can't see a way of defining a rule that enforces this condition.  If I add "..\project A*.h" to the Additional Dependencies field of the Custom Build Step, the missing link would be a macro that evaluates to true when any file in Additional Dependencies is newer than any file in the Outputs field.</p>
  
  <p>Does Visual Studio provide a macro that tells me when the Custom Build Step's Additional Dependencies are newer than Outputs, or am I in scripting territory here?</p>