Precedence in Macro Definitions

Home Page (Projects)Overview (NMAKE Reference)How Do I... Topics (Projects)

If a macro has multiple definitions, NMAKE uses the highest-precedence definition. The following list shows the order of precedence, from highest to lowest:

  1. A macro defined on the command line

  2. A macro defined in a makefile or include file

  3. An inherited environment-variable macro

  4. A macro defined in the Tools.ini file

  5. A predefined macro, such as CC and AS

Use /E to cause macros inherited from environment variables to override makefile macros with the same name. Use !UNDEF to override a command line.