conditions:
- a makefile passed make:
make -f ../makefile hi
- the
hi
target callsmake
i need way propagate value -f
sub-make command running inside hi
.
bye: echo 'whatever' hi: ${make} bye
the possibility i'm aware of use makefile_list
variable:
curr_makefile:=$(lastword $(makefile_list)) bye: echo 'whatever' hi: +$(make) -f $(curr_makefile) bye
but note, written in official documentation, variable records parsed makefiles, including include
ed ones. value of variable reliable when queried @ top of makefile, before includes.