%% gk <[EMAIL PROTECTED]> writes:

  g> I'm using 'ls' simply to get a pretty list in my 'SOURCE.mk'
  g> makefile: one file per line, instead of the single line output that
  g> $(wildcard ...)  generates. More readable.

Hm... you have a strange dichotomy between wanting make to be a "black
box" etc. on one hand, and wanting the makefiles to be "more readable"
on the other hand :).

  g> Can you say any more about why $(wildcard ...) is preferred?

More efficient.

  g> Since my rules execute in a shell anyway I don't see much overhead
  g> to using 'ls';

ls itself has a lot more overhead than wildcard, because not only is ls
a separate process but it does a lot more than just return the names of
files.  If you don't bother with the formatting you can do the whole
thing in one shell (plus a /bin/echo if it's not builtin to your shell)
if you use wildcard, rather than two shells, at least 6 echos, 2 ls's
and 2 xargs; that's 2 process invocations vs. 12 :).

-- 
-------------------------------------------------------------------------------
 Paul D. Smith <[EMAIL PROTECTED]>          Find some GNU make tips at:
 http://www.gnu.org                      http://make.paulandlesley.org
 "Please remain calm...I may be mad, but I am a professional." --Mad Scientist


_______________________________________________
Help-make mailing list
[EMAIL PROTECTED]
http://mail.gnu.org/mailman/listinfo/help-make

Reply via email to