GlobalArrays / ga

Partitioned Global Address Space (PGAS) library for distributed arrays
http://hpc.pnl.gov/globalarrays/
Other
97 stars 38 forks source link

How to compile a single file through the MPI compiler #214

Closed daydayup-echo closed 1 month ago

daydayup-echo commented 3 years ago

Hi,all, I would like to know how to compile a single file through the MPI (mpich_3.3.2) compiler mpicc? After consulting the user manual, I found that it does not support copying a single file to ~/global/testing to compile through “make myfile.x”.

  1. I successfully compiled the GA library according to the tutorial. The following is my execution process:  mkdir bld  cd bld  ../configure --prefix=‘pwd‘  make  make install

  2. I also successfully built and ran the test sample in the following way:  make check MPIEXEC="mpirun -np 4" image

  3. I add the include directory and lib directory to the environment variable and source it, and use “mpicc -o mytestc mytestc.c” to report an error when compiling: image

  4. I added the absolute path of the include directory and lib directory to the above "mytestc.c" and reported the following error: image

So, how can I run the program in my environment to call the GA library. Here is the information of my environment: Linux version 2.6.32-754.9.1.el6.x86_64 (mockbuild@x86-01.bsys.centos.org) (gcc version 4.4.7 20120313 (Red Hat 4.4.7-23) (GCC) ) #1 SMP Thu Dec 6 08:02:15 UTC 2018

Looking forward to your answer, thanks!

Zhang,