Also the Elementary repo has a wrapper for main() from E17, might be useful.

On Sun, 12 Aug 2012 15:54:45 -0500, 1100110 <10equa...@gmail.com> wrote:

Would this help?
https://github.com/1100110/OpenMPI

On Sun, 12 Aug 2012 15:30:57 -0500, Andrew <andrew.sp...@gmail.com> wrote:

I'm attempting to create a wrapper for MPI, however, MPI_Init
wants to read the arguments for main():

MPI_Init(int *argv, char ***argc);

How do I get this last level of pointer reference?

So far, I have:

void main (string[] args)
{
      auto argarr = new char*[args.length];
      foreach(i, a; args)
          argarr[i] = (a.dup ~ '\0').ptr;

      int argc = to!(int)(argarr.length);
      MPI_Init(&argc, argarr.ptr);
}

Any ideas?

-Andrew




--
Using Opera's revolutionary email client: http://www.opera.com/mail/

Reply via email to