Tim,

   As usual, a too short error message without enough information. I've changed 
it so that it will now give you

Barrys-MacBook-Pro:petsc-dev barrysmith$ make -j 3 ccmake
********************* ERROR *************************
PETSc compiles are automatically parallel, do not 
provide the -j option to make  
******************************************************
make: *** [chk_makej] Error 1
Barrys-MacBook-Pro:petsc-dev barrysmith$ make -j 3 all-legacy
********************* ERROR *************************
Parallel build with 'make -j' is not supported
for PETSc legacy builds. Run without -j <np>
or ./configure PETSc with --download-cmake
to enable parallel builds with PETSc
******************************************************
make[1]: *** [chk_makej] Error 1
make: *** [all-legacy] Error 2
Barrys-MacBook-Pro:petsc-dev barrysmith$ 

Explanations: 
When PETSc is using cmake makefiles from the top level makefiles we pass our 
own -j <np> down, make doesn't like having two levels of -j and at best prints 
a confusing warning message about the parallel build. 

When using PETSc's legacy make system it uses a recursive make that is not able 
to be parallelized (yes it is bad and hence the cmake version is used by 
default now). 

Notes:
It would be nice if we could somehow remove the -j <np> at the top level so 
that it didn't generate the error message and just ran but make doesn't allow 
this type of thing. 

It would be nice if we could eliminate the messages like 

make[1]: *** [chk_makej] Error 1
make: *** [all-legacy] Error 2

that make generates automatically but I cannot figure out how to do that.

So the current situation is a compromise where most users get automatically a 
parallel build and the users who knowingly provide a -j <np> option get 
slightly peeved. (My guess is 90+% of people who install PETSc don't know about 
the -j option).  At least now it will explain that it is doing a parallel build.

I'll check on the -k option next.

  Barry

On Feb 25, 2013, at 2:58 PM, Jed Brown <jedbrown at mcs.anl.gov> wrote:

> This is to support different backends. If configure found CMake, then normal 
> "make" will use multiple jobs, or you can do it explicitly with make -j3 
> $PETSC_ARCH.
> 
> CMake would be terrible as a hard dependency (it's terrible enough as it is) 
> but it's less bad than some alternatives.
> 
> 
> On Mon, Feb 25, 2013 at 3:30 PM, Tim Tautges <tautges at mcs.anl.gov> wrote:
> tautges at chronos:~/code/petsc-dev-moab$ make -j 8
> ********************* ERROR *************************
> Parallel build with 'make -j' is not supported
> ******************************************************
> make: *** [chk_makej] Error 1
> tautges at chronos:~/code/petsc-dev-moab$
> 
> 
> Why??? I can almost understand petsc's justification for its own 
> autotools-looking python-based build system, but why its need to not support 
> otherwise-standard make options?  Similarly, PETSC_MAKE_STOP_ON_ERROR instead 
> of make -k?
> 
> - tim
> 
> -- 
> ================================================================
> "You will keep in perfect peace him whose mind is
>   steadfast, because he trusts in you."               Isaiah 26:3
> 
>              Tim Tautges            Argonne National Laboratory
>          (tautges at mcs.anl.gov)      (telecommuting from UW-Madison)
>  phone (gvoice): (608) 354-1459      1500 Engineering Dr.
>             fax: (608) 263-4499      Madison, WI 53706
> 
> 

Reply via email to