Loading...
You are not logged-in Login/Register





  • Posts   Search Threads
  • karpenNovember 2, 2009 8:58 AM PST   
    MPICH2 install problem

    Hi, I am trying to install and compile MPICH2 v1.2 on my Mac running OS10.5.8, and am running into a problem involving different versions of ifort vs gcc. When I run the script that comes with MPICH2 to compile it with the Intel Fortran compiler, I get the following error message: configure: error: ****  Incompatible Fortran and C Object File Types!  ****
    F77 Object File Type produced by "ifort  -O2" is : : Mach-O 64-bit object x86_64.
    C  Object File Type produced by "gcc  -O2" is : : Mach-O object i386.

    Apparently the built-in C++ compiler option is for 32-bit machines, but this is a 64-bit machine (Quad-Core Intel Xeon chips). Ifort recognizes this but Apple's gcc does not.

    I have a license for Intel Fortran but not for the C++ compiler because I never write code in C++. Can this problem be solved by installing a different version of gcc than is automatically installed with the OS (and is that really a good idea), by somehow changing the gcc compiler options so it will recognize 64-bit applications (ditto), or it the only solution to buy Intel's C++ compiler? Thanks alot for your help!


    Ronald W. Green (Intel)November 2, 2009 9:09 AM PST
    Rate
     
    Re: MPICH2 install problem

    Quoting - karpen
    Hi, I am trying to install and compile MPICH2 v1.2 on my Mac running OS10.5.8, and am running into a problem involving different versions of ifort vs gcc. When I run the script that comes with MPICH2 to compile it with the Intel Fortran compiler, I get the following error message: configure: error: ****  Incompatible Fortran and C Object File Types!  ****
    F77 Object File Type produced by "ifort  -O2" is : : Mach-O 64-bit object x86_64.
    C  Object File Type produced by "gcc  -O2" is : : Mach-O object i386.

    Apparently the built-in C++ compiler option is for 32-bit machines, but this is a 64-bit machine (Quad-Core Intel Xeon chips). Ifort recognizes this but Apple's gcc does not.

    I have a license for Intel Fortran but not for the C++ compiler because I never write code in C++. Can this problem be solved by installing a different version of gcc than is automatically installed with the OS (and is that really a good idea), by somehow changing the gcc compiler options so it will recognize 64-bit applications (ditto), or it the only solution to buy Intel's C++ compiler? Thanks alot for your help!

    the gcc and g++ compilers take -m64 and -m32 to choose 64bit or 32bit.  So use -m64 for CFLAGS and CXXFLAGS when you build mpich2 if you want it to create 64bit binaries.

    ron



    How to attach files to a posting
    Private posts and threads how-to


    karpenNovember 2, 2009 2:21 PM PST
    Rate
     
    Re: MPICH2 install problem


    the gcc and g++ compilers take -m64 and -m32 to choose 64bit or 32bit.  So use -m64 for CFLAGS and CXXFLAGS when you build mpich2 if you want it to create 64bit binaries.

    ron

    Thanks for the help Ron! If I had read the README thoroughly, I would have answered most of my own question. It is not obvious how to implement the above however, so for anyone else in this situation, here is what you have to do: add the options "CFLAGS=-m64 CXXFLAGS=-m64" to the ./configure command mentioned in the install instructions and the README file.


Forum jump:  

Intel Software Network Forums Statistics

16,377 users have contributed to 46,364 threads and 164,041 posts to date.

In the past 24 hours, we have 9 new thread(s) 31 new posts(s), and 20 new user(s).

In the past 3 days, the most popular thread for everyone has been Program compiles in release but not debug The most posts were made to You need to show us the whole The post with the most views is vectorization of sin/cos results in wrong values

Please welcome our newest member fruitbrown


For more complete information about compiler optimizations, see our Optimization Notice.