help-make
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: foreach/ordering help


From: Mark Therieau
Subject: Re: foreach/ordering help
Date: Tue, 5 Nov 2002 07:37:56 -0800 (PST)

--- "Paul D. Smith" <address@hidden> wrote:
> Another option would be to do it N files at a time,
> rather than one at a time; that would invoke only
> M/N shells instead of M shells.

Agreed. Definitely would be faster.

> You'd need to work out how to break the list up
> into parts using the $(words ...) etc functions.

O.K. it's pretty easy to break things up using
$(wordlist), if I assume N=50, and know that M is
never bigger than say, 1000:

c.pfs:
        @echo $(wordlist 1,50,$(CSRCS)) > $@
        @echo $(wordlist 51,100,$(CSRCS)) >> $@
...
        @echo $(wordlist 951,1000,$(CSRCS)) >> $@

But what if I don't know how big M will be? (and
want to tune N as needed?)  Not sure if gmake
would allow the "@echo $(wordlist..." commands to be:

- created on the fly (e.g. $(shell)/external script)
- and then expand the $(wordlist...) functions
- and then execute the commands with one shell per
command

Or maybe I'm missing something?

regards,
markt


__________________________________________________
Do you Yahoo!?
HotJobs - Search new jobs daily now
http://hotjobs.yahoo.com/




reply via email to

[Prev in Thread] Current Thread [Next in Thread]