- Simple Assignment (
=
):-
It assigns a value to a variable.
-
The value of the variable is evaluated when the variable is used, not when it's declared.
-
This means that if you reference other variables in the assignment, their values will be expanded at the time of use, not at the time of assignment.
FOO = $(BAR) BAR = Hello all:
-
@echo $(FOO) # This will output "Hello"