Sure - they have so many ways of tweaking things - so one can't things will be the same across multiple users.
Most users dont' set these env variables [thats extra work - and not the default behavior anyway] - so they rely on the default behavior - i.e use mpicc for gnu and mpiicc for intel compilers. [i.e the guesses picked up by configure might not always be what the user wants - so its best to tell configure not to guess - and tell it exactly what one wants it to use. And there might be scope to improve guessing in favor of most common use cases.] Satish On Thu, 22 Mar 2018, Klaij, Christiaan wrote: > Fair enough. > > As a side note: if you want intel compilers, there's no need to > specify mpiicc, intel says to export I_MPI_CC=icc, which gives > > $ which mpicc > /opt/intel/compilers_and_libraries_2017.1.132/linux/mpi/intel64/bin/mpicc > $ mpicc -v > mpiicc for the Intel(R) MPI Library 2017 Update 1 for Linux* > Copyright(C) 2003-2016, Intel Corporation. All rights reserved. > icc version 17.0.1 (gcc version 4.8.5 compatibility) > > (otherwise they wrap the gnu compilers by default, baffling) > > Chris > > > dr. ir. Christiaan Klaij | Senior Researcher | Research & Development > MARIN | T +31 317 49 33 44 | mailto:c.kl...@marin.nl | http://www.marin.nl > > MARIN news: > http://www.marin.nl/web/News/News-items/Frequency-of-spill-model-for-area-risk-assessment-of-shipsource-oil-spills-in-Canadian-waters-1.htm > > ________________________________________ > From: Satish Balay <ba...@mcs.anl.gov> > Sent: Thursday, March 22, 2018 2:54 PM > To: Klaij, Christiaan > Cc: petsc-users > Subject: Re: [petsc-users] problem configuring 3.8.3 with intel mpi > > On Thu, 22 Mar 2018, Klaij, Christiaan wrote: > > > OK, configure works with the option --with-cc=/path/to/mpicc, > > thanks! > > > > I'm not sure you are right about checking --with-mpi-dir/bin, > > There are 2 types of options to configure: > - tell configure what to use - i.e do not guess [like --with-cc=mpicc'] > - tell configure to *guess* with partial info [like > --with-package-dir=/path/to/foo/bar] > > When configure has to guess - it will never be perfect. > > Sure - perhaps the guessing of --with-mpi-dir can be improved - but it will > never be perfect. > > > because, at least with this install, the binaries are located in > > --with-mpi-dir/intel64/bin: > > > > $ which mpicc > > /opt/intel/compilers_and_libraries_2017.1.132/linux/mpi/intel64/bin/mpicc > > So the more appropriate thing here [wrt petsc configure] is > --with-mpi-dir=/opt/intel/compilers_and_libraries_2017.1.132/linux/mpi/intel64 > > And then - what if you want to use intel compilers and not gnu > compilers [with intel mpi]? - you have to specify mpiicc - and not > mpicc - so its best to prefer 'no-guess' options like --with-cc. > [with-mpi-dir is usually convinent - but not always suitable] > > Satish > > > > > Perhaps something to do with intel supporting both 32 and > > 64bit. Anyway, our sysadmin didn't change any of these locations, > > they just run the intel installer and this is what we got. >