Hi,

I have noticed that there is a difference between the two scenarios
listed below:

i) make  CC=arm-linux-gnueabihf-gcc CPPFLAGS=[..]

ii) export CPPFLAGS=[..] [RET]
    make CC=arm-linux-gnueabihf-gcc

I was told that the difference is that in the second case Make
will append stuff to the CPPFLAGS variable exported while in the first
case the command line argument will override the settings contained
in the makefile itself.

The following example, literally pasted from another thread could
clarify the matter :

var := $(shell echo "echo hi" >say_hi.sh; chmod +x say_hi.sh; say_hi.sh)
all: ; @echo $(var)

Calling make with the PATH environment variable either way yields:

$ make PATH=$PATH:.
/bin/sh: 1: say_hi.sh: not found

$ PATH=$PATH:. make
hi

Is this working as intended ? What is the difference between the two ?

I have posted a question at the general make mailing list and I was told
that this might be a bug, I would love to have a clarification - is it a bug ?


Thanks
P.


_______________________________________________
Bug-make mailing list
Bug-make@gnu.org
https://lists.gnu.org/mailman/listinfo/bug-make

Reply via email to