Skip to content

Conversation

@roystgnr
Copy link
Member

We currently end up in an inconsistent state when configuring against the repo libpetsc3.4.2-dev on Ubuntu 14.10 - PETSc is there, and configured with MPI, but doesn't define MPIEXEC, so we assume it's configured in serial, and we don't try to detect MPI.

This PR fixes the configure for me, by trying ACX_MPI in that case. It's possible that this PR will break cases in which the user has an autodetectable MPI but wants to configure against a mpiuni PETSc, but in those cases "--with-mpi=false" ought to be an adequate workaround.

This appears to be the case with the current default PETSc build on
Ubuntu 14.10
@roystgnr
Copy link
Member Author

Forgot to mention: thanks go to Zhenyu (more id omitted since I don't know his github username and I want to spare his email address from spammers) for finding this problem. I'm running on Ubuntu 14.10 myself but haven't been using the default repo PETSc for a long time.

@jwpeterson
Copy link
Member

So are we wrong to be grepping for MPIEXEC in petscvariables as a way to snoop MPI? It looks like we've been doing it that way since time immemorial...

I can definitely see why Ubuntu can't simply tie its PETSc dpkg to a single mpiexec since it has no idea what a user might install...

@jwpeterson
Copy link
Member

I don't suppose Ubuntu's petscvariables file provides MPI_INCLUDE, MPICXX_SHOW, or MPICC_SHOW variables either?

@roystgnr
Copy link
Member Author

Nothing in petscvariables, or in the rest of /usr/lib/petsc/conf/* as far as grep can tell.

@roystgnr
Copy link
Member Author

I can't imagine that merely omitting config variables produces an MPI-independent PETSc, though. IIRC the MPI standard doesn't specify enough of an ABI to make that possible. I guess I'll try swapping between openmpi and mpich2 and find out for myself, though.

@moosebuild
Copy link

Results of testing ecc0616 using libmesh_PR_test recipe:

Passed on: linux-gnu

View the results here: https://www.moosebuild.com/view_job/13917

@moosebuild
Copy link

Results of testing ecc0616 using libmesh_PR_test_dbg recipe:

Passed on: linux-gnu

View the results here: https://www.moosebuild.com/view_job/13918

@roystgnr
Copy link
Member Author

Trying to use Ubuntu PETSc with mpich2 ends up adding mpich2 compile/link flags via ACX_MPI autodetection and openmpi compile/link flags via PETSCINCLUDEDIRS/PETSCLINKLIBS. I'm not going to bother testing that case. This works for the Ubuntu PETSc+openmpi case, though, so ready to merge.

roystgnr added a commit that referenced this pull request Mar 31, 2015
@roystgnr roystgnr merged commit c6797ac into libMesh:master Mar 31, 2015
@roystgnr roystgnr deleted the another_acx_mpi_fallback branch March 31, 2015 18:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants