Thread (10 messages) 10 messages, 6 authors, 2016-06-15

Re: [PATCH 2/2] Makefile: work around ksh's failure to handle missing list argument to for loop

flat view

From: Michael J Gruber <hidden>
Date: 2016-06-15 22:49:04

Possibly related (same subject, not in this thread)

Brandon Casey venit, vidit, dixit 02.07.2010 20:50:
From: Brandon Casey <redacted>

ksh does not like it when the list argument is missing in a for loop.  This
can happen when NO_CURL is set which causes REMOTE_CURL_ALIASES to be unset.
In this case, the for loop in the Makefile expands to look like this:

   for p in ; do

and ksh complains like this:

   /bin/ksh: syntax error at line 15 : `;' unexpected

The existing attempt to work around this issue, introduced by 70b89f87,
tried to protect the for loop by first testing whether REMOTE_CURL_ALIASES
was empty, but it does not seem to work.  So adopt Bruce Stephens's
What does that mean? Either it works or it doesn't. I did work back
then. Does it (i.e.: the test for emtyness) fail to work for certain shells?

Michael
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help