I can use += to append to recursive-expanded variable and it works well.
In real world it's sometimes required to prepend or to wrap variable into some code without expanding.
I've found similar question here GNU make: prepend a recursively expanded variable? But was unable to change it quickly for my case.
Basically I need something like this:
define Xdef
@echo $(1)
endef
define Xdef
@echo Before
# Value of original Xdef is here. i.e. echo $(1)
@echo After
endef
all:
$(call Xdef,Hello world)
With next results:
$ make
Before
Hello world
After
Thanks.