Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 30 Jun 2010 10:01:21 -0700
From:      Garrett Cooper <yanefbsd@gmail.com>
To:        FreeBSD-Hackers <freebsd-hackers@freebsd.org>
Subject:   Non-POSIX compliant pmake with secondary expansion?
Message-ID:  <AANLkTikPXTmlsT43LGXGFTWFoAxKmvUMegap443-Lvgk@mail.gmail.com>

next in thread | raw e-mail | index | archive | help
Hi guys,
    I currently set:

.POSIX=

    In a Makefile thinking that it would enable only POSIX
functionality, and was fidgeting around with the Makefile trying to
get it to work. In short, I used secondary expansion, it worked, then
compared the output from gmake and it failed (because they have the
.SECONDEXPANSION keyword). POSIX doesn't mention secondary expansion,
so obviously it's not a POSIX feature.
    So I was wondering if secondary expansion is enabled by default
with .POSIX instead of being disabled like it should on pmake?
Thanks,
-Garrett

$ cat test_Makefile
.POSIX=

TARGETS=

all: $$(TARGETS)

TARGETS+=	idontexist

idontexist:
	@echo $@
$ make -f test_Makefile all
idontexist
$ gmake -f test_Makefile
gmake: *** No rule to make target `$(TARGETS)', needed by `all'.  Stop.
$ uname -a
FreeBSD bayonetta.local 9.0-CURRENT FreeBSD 9.0-CURRENT #0 r206173M:
Mon Apr 26 22:45:06 PDT 2010
root@bayonetta.local:/usr/obj/usr/src/sys/BAYONETTA.ata  amd64



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?AANLkTikPXTmlsT43LGXGFTWFoAxKmvUMegap443-Lvgk>