[Pw_forum] installing OpenMPI and Quantum Espresso on a Mac OS X system

Gabriele Sclauzero sclauzer at sissa.it
Fri Jun 12 14:25:49 CEST 2009


Sorry Michael,

   I can't understand why you're continuing having problems in compiling. It should be not 
a "mission-impossible" kind of task, you simply need to have working compilers and mpi 
wrappers (which you seem to have now) and maybe tweak a bit with the configure options.

I compiled openmpi 1.3 on top of gfortran and Apple's gcc on MacOSX 10.5.7 (although I 
really _strongly_ suggest you to use Intel compilers if you want to do serious 
calculations on your Intel desktop... you may discover that you're wasting half of the 
time just to save an hundred dollars or so), and I haven't met any problem.

Michael Hayden wrote:
> Alain,
> 
> Again, thanks for your efforts and time.
> 
> I 
> have successfully installed and tested OpenMPI.  I also configured Quant Espresso and received the "Parallel environment detected successfully, configured  for compilation of parallel executables" 
> response at the end of the config process.
> 
> I then compiled it,but the end of a very long output read:
> 
> ld: in /usr/local/lib, can't map file, errno=22
> collect2: ld returned 1 exit status
> make[1]: *** [pw.x] Error 1
> make: *** [pw] Error 2

Most probably you have a problem in your environment variables (check if PATH, 
LD_LIBRARY_PATH and DYLD_LIBRARY_PATH are what you expect them to be, i.e. with the path 
to the MPI version you want to use listed _first_) or you miscompiled openmpi.
Honestly I don't see any need to feed so many parameters as suggested by Alain to the 
configure of openmpi (unless you know exactly what they mean, maybe Alain does, I do 
not...). You simply need to specify CC, CXX, F77, FC (and --prefix option, since it is not 
wise to overwrite Apple's compiler files). If something goes wrong in the configure you 
may need to add some others.

Cheers

GS

> 
> This doesn't look good and I can't find any list of these errors in the 
> user guide.  I tried example01 and received (of course) this output:
> ERROR: /usr/local/espresso-4.0.5/bin/pw.x not existent or not executable
> Aborting
> 
> Any ideas?
> 
> cheers,
> Mike
> 
> 
> On Jun 10, 2009, at 7:05 PM, Alain Jacques wrote:
> 
>> Hello Mike,
>>
>> Humm, sorry it didn't work as expected. My development platform runs 
>> OSX 10.5.7. I have compiled many working openmpi versions with the 
>> following recipe:
>>
>> export LD_LIBRARY_PATH=/opt/gcc-4.3.2/lib:$LD_LIBRARY_PATH && export 
>> PATH=/opt/gcc-4.3.2/bin:$PATH
>>
>> ./configure --prefix=/opt/openmpi-1.2.8_gcc-4.3.2_m32 --enable-static 
>> --enable-shared --disable-dependency-tracking --with-devel-headers 
>> --with-wrapper-ldflags="-Wl,-search_paths_first" 
>> CC=/opt/gcc-4.3.2/bin/gcc LDFLAGS="-L/opt/gcc-4.3.2/lib" 
>> FC=/opt/gcc-4.3.2/bin/gfortran F77=/opt/gcc-4.3.2/bin/gfortran 
>> CXX=/opt/gcc-4.3.2/bin/g++ CPP=/opt/gcc-4.3.2/bin/cpp CFLAGS="-m32 -O3 
>> -march=native" CXXFLAGS="-m32 -O3 -march=native" FCFLAGS="-m32 -O3 
>> -march=native" FFLAGS="-m32 -O3 -march=native"
>>
>> As you understand, my homemade gcc/gfortran lives in 
>> /opt/gcc-4.3.2/bin and I install the corresponding openmpi in 
>> /opt/openmpi-1.2.8_gcc-4.3.2_m32. Same story with openmpi up to 
>> version 1.3.2 and gcc up to 4.4.0. The -m32 flag is there to specify 
>> 32bit binaries (-m64 will build 64bit openmpi for the corresponding 
>> binaries, adapt the LDFLAGS too). I am quite convinced that the error 
>> message you receive comes from a mixture with Apple provided openmpi 
>> libs without gfortran support.
>> And when it is done,  in order to compile or run mpi software, I add 
>> the path to the new openmpi binaries and libs in front with a:
>>
>> export PATH=/opt/openmpi-1.2.8_gcc-4.3.2_m32/bin:$PATH && export 
>> DYLD_LIBRARY_PATH=/opt/openmpi-1.2.8_gcc-4.3.2_m32/lib:$DYLD_LIBRARY_PATH
>>
>> i.e. I end with a 
>> PATH=/opt/openmpi-1.2.8_gcc-4.3.2_m32/bin:/opt/gcc-4.3.2/bin:xxx and  
>> DYLD_LIBRARY_PATH=/opt/openmpi-1.2.8_gcc-4.3.2_m32/lib:/opt/gcc-4.3.2:xxx 
>> where xxx is the original content of the variables.
>>
>> Kind regards,
>>
>> Alain
>>
> 
> 
> ------------------------------------------------------------------------
> 
> _______________________________________________
> Pw_forum mailing list
> Pw_forum at pwscf.org
> http://www.democritos.it/mailman/listinfo/pw_forum

-- 


o ------------------------------------------------ o
| Gabriele Sclauzero, PhD Student                  |
| c/o:   SISSA & CNR-INFM Democritos,              |
|        via Beirut 2-4, 34014 Trieste (Italy)     |
| email: sclauzer at sissa.it                         |
| phone: +39 040 3787 511                          |
| skype: gurlonotturno                             |
o ------------------------------------------------ o



More information about the users mailing list