This section summarizes internal macros, modifiers, string substitution, and special macros.
$? | The list of prerequisites that have been changed more recently than the current target. Can be used only in normal description file entries--not suffix rules. |
$@ | The name of the current target, except in description file entries for making libraries, where it becomes the library name. Can be used both in normal description file entries and in suffix rules. |
$$@ | The name of the current target. Can be used only to the right of the colon in dependency lines. (May not work on all versions of make.) |
$< | The name of the current prerequisite that has been modified more recently than the current target. Can be used only in suffix rules and in the .DEFAULT: entry. |
$* | The name--without the suffix--of the current prerequisite that has been modified more recently than the current target. Can be used only in suffix rules. |
$% | The name of the corresponding .o file when the current target is a library module. Can be used both in normal description file entries and in suffix rules. |
Macro modifiers are not available in all variants of make.
$(*D) $$(@D) $(<D) $(%D) $(@D)
$(*F) $$(@F) $(<F) $(%F) $(@F)
String substitution is not available in all variants of make.
MAKEFLAGS | Contains the flags inherited in the environment variable MAKEFLAGS, plus any command-line options. Used to pass the flags to subsequent invocations of make, usually via command lines in a makefile that contain $(MAKE). |
SHELL | Sets the shell that interprets commands. If this macro isn't defined in the description file, the value depends on your system. Some Unix implementations use the shell from the user's environment (as with other macros). Other implementations (including SVR4) set the default SHELL to /bin/sh. |
VPATH | (Not available in all variants of make.) Specifies a list of directories to search for prerequisites when not found in the current directory. |
Copyright © 2003 O'Reilly & Associates. All rights reserved.