I want to make a GNU Makefile, in which for every targets like
<dirname>/stamp-<stampname>:
the following command is executed:
cd <dirname> && make stamp-<stampname>
As I've read here, the so-named pattern rules can do some quite similar, i.e. for example to call a C compiler to produce the .o-s from any sources (.c):
%.o: %.c
$(CC) -o ...
They could solve my problem, but as you can see, in my case, multiple % directives would be needed. Ideally, if a syntax element like
%1/stamp-%2:
cd %1 && make stamp-%2
would exist, it would solve everything. But it doesn't. Does some workaround exist for the task?