Exporting variable to $(shell).

2017-01-11 Thread Sergey Organov
Hello, It looks like exporting variables to $(shell) function doesn't work. Here is a test to demonstrate the issue: $ cat Makefile override MY_VAR := OK export MY_VAR var := $(shell echo "Exported to shell in function: [$$MY_VAR]") all: @echo "In make: [$(MY_VAR)]" @echo "Expor

Re: Exporting variable to $(shell).

2017-01-11 Thread Sergey Organov
Paul Smith writes: > On Wed, 2017-01-11 at 17:49 +0300, Sergey Organov wrote: >> It looks like exporting variables to $(shell) function >> doesn't work. > > This is https://savannah.gnu.org/bugs/?10593 > > It should be made to work, but unfortunately it's n

Re: Exporting variable to $(shell).

2017-01-11 Thread Sergey Organov
Paul Smith writes: > On Wed, 2017-01-11 at 19:10 +0300, Sergey Organov wrote: >> > Some sort of loop detection on variable expansion needs to be >> > implemented. >> >> Can't it rather be solved by exporting variables to the $(shell) >> unexpanded? &