help-make
[Top][All Lists]
Advanced

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

Re: Does GNU Make support for parallel compiling?


From: Sam Ravnborg
Subject: Re: Does GNU Make support for parallel compiling?
Date: Wed, 3 Dec 2008 06:38:52 +0100
User-agent: Mutt/1.4.2.1i

On Wed, Dec 03, 2008 at 11:22:53AM +0800, Jack wrote:
> Hi, Make team
> 
>   Let me give you an example first. My project Make with following steps:
>   1. make $(HOME)/$(HOME)/lib/; make src/;  make $(HOME)/util/;
>   2. make $(HOME)/
> 
>   In the first step, lib/, src/, util/ could be Maked parallel, after
> the first step finished, then Make execute step 2 to produce exe-file.
>   As multi-core cpu is popular today, I think it is a wonderful for
> Make to support parallel compiling.

Use the parameter -j to enable parallel build of your targets.
-j takes an optional parameter that limits the number of
parallel processes. As a rule of thumb specify twice the amount of
processors (cores) you have.

        Sam




reply via email to

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