Re: sim/arm/Makefile.in fix for non-GNU make

Michael Elizabeth Chastain
2001-11-15T17:16:55Z

Ben Harris writes:

> sim/arm/Makefile.in currently uses $< in a non-implicit rule. This
> doesn't work with non-GNU makes (at least NetBSD's one) since $< isn't set
> for non-implicit rules.

I got curious, so I checked the Single Unix Spec for make:

http://www.opengroup.org/onlinepubs/007908799/xcu/make.html

It says:

$<
In an inference rule, $< evaluates to the filename whose
existence allowed the inference rule to be chosen for the
target. In the .DEFAULT rule, the $< macro evaluates to the
current target name. The $< macro is evaluated only for
inference rules. For example, in the .c.a inference rule, $<
represents the prerequisite .c file.

So I think this is a good patch.

My two cents,

Michael C