> I'm not sure I understand the problem. The ale3d program from
> LLNL operates exactly as you describe and it can be built
> with mpich, lam, or openmpi.
I'm not sure what reply would be most helpful, so here's an attempt.
It sounds like we're on the same page with regard to the desired behavior. Historically, we've been able to detect serial vs. parallel launch of the binary foo, with a whole host of implementations, including those you mention, as well as some vendor-specific implementations (possibly including DEC/OSF, SGI, Sun, and AIX/poe, though I don't know all the details). We typically distinguish serial from parallel executions on the basis of environment variables set only in the MPI runtime environment. I was just trying to ascertain what variable would be best to test for in an OpenMPI environment, and I think Ralph helped with that.
If the ale3d code takes a different approach, I'd love to hear about it, off-list if necessary.