Hi Samar,

 

Thanks for your suggestion. Unfortunately, it does not work. I checked the 
mpif90 wrapper and the option "-Wl,-flat_namespace” is present. 

 

(base) ➜  bin ./mpif90 -show

ifort -I/Users/danyangsu/Soft/PETSc/petsc-3.16.3/macos-intel-dbg/include 
-Wl,-flat_namespace -Wl,-commons,use_dylibs 
-I/Users/danyangsu/Soft/PETSc/petsc-3.16.3/macos-intel-dbg/lib 
-L/Users/danyangsu/Soft/PETSc/petsc-3.16.3/macos-intel-dbg/lib -lmpi_usempif08 
-lmpi_usempi_ignore_tkr -lmpi_mpifh -lmpi

 

Thanks anyway,

 

Danyang

From: Samar Khatiwala <[email protected]>
Date: Wednesday, January 12, 2022 at 2:01 PM
To: Danyang Su <[email protected]>
Cc: PETSc <[email protected]>
Subject: Re: [petsc-users] PETSc configuration error on macOS Monterey with 
Intel oneAPI

 

Hi Danyang,

 

I had trouble configuring PETSc on MacOS Monterey with ifort when using mpich 
(which I was building myself). I tracked it down to an errant 
"-Wl,-flat_namespace” 

option in the mpif90 wrapper. I rebuilt mpich with the 
"--enable-two-level-namespace” configuration option and the problem went away. 
I don’t know if there’s a similar 

issue with openmpi but you could check the corresponding mpif90 wrapper (mpif90 
-show) whether "-Wl,-flat_namespace” is present or not. If so, perhaps passing 

"--enable-two-level-namespace” to PETSc configure might fix the problem 
(although I don’t know how you would set this flag *just* for building openmpi).

 

Samar



On Jan 12, 2022, at 9:41 PM, Danyang Su <[email protected]> wrote:

 

Hi All,

I got an error in PETSc configuration on macOS Monterey with Intel oneAPI using 
the following options:

 

./configure --with-cc=icc --with-cxx=icpc --with-fc=ifort 
--with-blas-lapack-dir=/opt/intel/oneapi/mkl/2022.0.0/lib/ --with-debugging=1 
PETSC_ARCH=macos-intel-dbg --download-mumps --download-parmetis 
--download-metis --download-hypre --download-superlu --download-hdf5=yes 
--download-openmpi

 

Error with downloaded OpenMPI: Cannot compile/link FC with 
/Users/danyangsu/Soft/PETSc/petsc-3.16.3/macos-intel-dbg/bin/mpif90.

 

Any suggestions for that?

 

There is no problem if I use GNU compiler and MPICH.

 

Thanks,

 

Danyang 

 

Reply via email to