Providing Build Help

It's often very useful to be able to give users some help that describes the specific targets, build options, etc., that can be used for your build. SCons provides the Help function to allow you to specify this help text:

      Help("""
      Type: 'scons program' to build the production program,
            'scons debug' to build the debug version.
      """)
   

(Note the above use of the Python triple-quote syntax, which comes in very handy for specifying multi-line strings like help text.)

When the SConstruct or SConscript files contain such a call to the Help function, the specified help text will be displayed in response to the SCons -h option:

      % scons -h
      scons: Reading SConscript files ...
      scons: done reading SConscript files.
      
      Type: 'scons program' to build the production program,
            'scons debug' to build the debug version.
      
      Use scons -H for help about command-line options.
   

If there is no Help text in the SConstruct or SConscript files, SCons will revert to displaying its standard list that describes the SCons command-line options. This list is also always displayed whenever the -H option is used.