Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

Re: 3.1.0beta make install problem



Zoltan Hidvegi wrote:
>> not.) - it does a "for dir in $(MODULE_DIRS); do", but that variable is empty,
>> and so sh gets pouty.
>
>Isn't that $(MONULE_DIRS)?  sh should do nothing in for dir in ; do ... done.
>What system do you use?  It seems that you /bin/sh is buggy.

A lot of sh's don't like it.  I've always avoided doing that in
Makefile scripts, including the ones I've been writing for zsh.  There
are two usual workarounds:

list='$(POSSIBLY_EMPTY_VARIABLE)'
for foo in $list; do
  ...
done

for foo in .. $(POSSIBLY_EMPTY_VARIABLE); do
  if $foo != ..; then
    ...
  fi
done

-zefram



Messages sorted by: Reverse Date, Date, Thread, Author