Consider the makfile below.

OUT_DIR = my_dir
OUT_FILE = $(OUT_DIR)/hello.txt

$(OUT_FILE): | $(dir $(OUT_FILE))
echo Hello World > $@

my_dir:
mkdir $@

Running with make v3.81 results in:
mkdir my_dir
echo Hello World > my_dir/hello.txt

Running with Make v4.1 results in:
make: *** No rule to make target 'my_dir/', needed by 'my_dir/hello.txt'.
Stop.

Is this intentional?
_______________________________________________
Bug-make mailing list
[email protected]
https://lists.gnu.org/mailman/listinfo/bug-make

Reply via email to