Menu

#30 $(eval) does not redefine variables (GNU make incompatibil)

v1.18
closed-rejected
nobody
None
5
2017-08-06
2012-04-16
No

The $(eval VAR:=sth) is not evaluated correctly (variable value does not change). That is different behavior than GNU make.

See the example:

Makefile:
FOO:=bar
$(eval FOO:=alpha)
$(eval $(warning $(FOO)))
all:
@echo "FOO: $(FOO)"
-------------------------------------
desired result:
$ make
Makefile:5: alpha
FOO: alpha
___________________
current result:
$ makepp
makepp: Loading makefile `/home/mbialowas/src/devices/M0/android/Makefile'
makepp: warning: bar at `/home/mbialowas/src/devices/M0/android/Makefile:5'
makepp: Entering directory `/home/mbialowas/src/devices/M0/android'
FOO: bar

Discussion

  • Daniel Pfeiffer

    Daniel Pfeiffer - 2012-04-19

    In https://sourceforge.net/tracker/?func=detail&atid=437093&aid=3518447&group_id=43679 $(eval ...) is documented as not being implemented.

    However I have received a patch that makes it possible to run the gmake regression tests against makepp, so there will be another release improving this situation.

     
  • Daniel Pfeiffer

    Daniel Pfeiffer - 2017-08-06
    • status: open --> closed-rejected
    • Group: --> v1.18
     

Log in to post a comment.

MongoDB Logo MongoDB