Compile MPICH2 with PGI 6.1

I’m pretty new to this so please bear with me. :)

I installed the PGI compilers and am trying to compile mpich2. I’ve set the following and using csh:

setenv PATH /usr/local/pgi/linux86/6.1/bin:$PATH
setenv CFLAGS “-fast -fpic”
setenv CXXFLAGS “-fast -fpic”
setenv FFLAGS “-fast -fpic”
setenv F90FLAGS “-fast -fpic”
setenv LDFLAGS “-fast -fpic”
setenv OPTFLAGS “-fast -fpic”
setenv CC pgcc
setenv CXX pgCC
setenv F90 pgf90
setenv FC pgf77
setenv CPP “pgCC -E”

And when I run the configure script I get:

checking for gcc… pgcc
checking for C compiler default output file name… configure: error: C compiler cannot create executables

The config.log output looks like all is set correctly. I can’t find anyone else having this problem, so I’m wondering if I’ve done something wrong with the PGI compiler installation. I did compile mpich1 successfully.

Any ideas are welcome and appreciated…

John

Hi John,

We just tried configuring MPICH2 here using the varaibles you listed and all seemed fine. Typically when I’ve seen this error, for some reason pgcc is not working correctly. Maybe the PATH isn’t set correctly or there is license problem?

Are you able to compile a hello world program? Also, you can look at the configure log to see exactly what the script was trying to execute.

  • Mat

Hello World compiles OK. The previous version of mpich compiled OK. All the compilers are in my path. If you have any more suggestions please let me know.

Here is the end of my config.log:


#define HAVE_ERROR_CHECKING MPID_ERROR_LEVEL_ALL
#define HAVE_ROMIO 1
#define HAVE_RUNTIME_THREADCHECK 1
#define MPICH_ERROR_MSG_LEVEL MPICH_ERROR_MSG_ALL
#define MPICH_THREAD_LEVEL MPI_THREAD_MULTIPLE
#define PACKAGE_BUGREPORT “”
#define PACKAGE_NAME “”
#define PACKAGE_STRING “”
#define PACKAGE_TARNAME “”
#define PACKAGE_VERSION “”
#define USE_LOGGING MPID_LOGGING_NONE
#define USE_THREAD_IMPL MPICH_THREAD_IMPL_GLOBAL_MUTEX

configure: exit 77



Thanks,

John