Mark Sapiro writes:
 > CJ Keist wrote:

 > >I simply commented out the for p loop:
 > >
 > >         #for p in $(PACKAGES); \

 > That is a perfectly acceptable workaround, but the question is why
 > doesn't your make properly handle
 > 
 >    for p in   ; do ... ; done

Because make doesn't (shouldn't) do anything with commands except
substitute make variables, then pass them to the shell.  Bourne shells
require the tokens following "in" to constitute a list.  The idiom for
an empty list is the empty string.

One way to handle this in GNU Make is

ifeq($(PACKAGES),)
PACKAGES = ""
endif

(Untested, IIRC -- the point is that make doesn't care about the
quotation marks at all, so it passes the literal string '""' to the
shell as the value of the make variable PACKAGES.)
------------------------------------------------------
Mailman-Users mailing list [email protected]
http://mail.python.org/mailman/listinfo/mailman-users
Mailman FAQ: http://wiki.list.org/x/AgA3
Security Policy: http://wiki.list.org/x/QIA9
Searchable Archives: http://www.mail-archive.com/mailman-users%40python.org/
Unsubscribe: 
http://mail.python.org/mailman/options/mailman-users/archive%40jab.org

Reply via email to