问题
I need to call "target_1" from "target_2" plus also pass on a variable to the "target_1".
.PHONY:target_1
target_1:
ifeq ($(RQM_SETUP),ci)
mkdir /tmp/$1
chown 1000:1000 /tmp/$1
else
@echo "Nothing to do"
endif
.PHONY:target_2
target_2:
$(MAKE) target_1(dags)
So like in this eg, target_2 would call target_1 and also pass on value as "dags" to it. So that it would create a "/tmp/dags" folder
来源:https://stackoverflow.com/questions/63884790/calling-one-target-from-another-and-also-pass-a-variable-or-value-in-makefile