bin/154769: [make] :L modifier broken in quoted strings
Anonymous
swell.k at gmail.com
Mon Feb 14 12:10:11 UTC 2011
The following reply was made to PR bin/154769; it has been noted by GNATS.
From: Anonymous <swell.k at gmail.com>
To: Garrett Cooper <gcooper at FreeBSD.org>
Cc: bug-followup at FreeBSD.org
Subject: Re: bin/154769: [make] :L modifier broken in quoted strings
Date: Mon, 14 Feb 2011 15:05:38 +0300
Garrett Cooper <gcooper at FreeBSD.org> writes:
>> cat Makefile.1
> FOO?= bar
> .if "${FOO:L}" == "bar"
> .warning "match!"
> .else
> .warning "no match!"
> .endif
>> make -f Makefile.1 FOO=bar
> "Makefile.1", line 2: Malformed conditional ("${FOO:L}" == "bar")
> "Makefile.1", line 3: "match!"
>
> .. unquoting the variable works though without the malformed
> conditional noise...
You can reduce example to
.if "bar" == "bar"
.warning "match!"
.endif
and make(1) would still produce
$ make
"Makefile", line 1: Malformed conditional ("bar" == "bar")
"Makefile", line 2: warning: "match!"
"Makefile", line 3: if-less endif
It was fixed in bmake circa 2004
http://mail-index.netbsd.org/source-changes/2004/04/13/msg145128.html
More information about the freebsd-bugs
mailing list