[petsc-users] PETSc Windows Installation

Mohammad Ali Yaqteen mhyaqteen at sju.ac.kr
Mon Oct 31 21:32:45 CDT 2022


I have checked the required Cygwin openmpi libraries and they are all installed. When I run ./configure --with-cc=mpicc --with-cxx=mpicxx --with-fc=mpif90, it returns:

$ ./configure --with-cc=mpicc --with-cxx=mpicxx --with-fc=mpif90
=============================================================================================
                         Configuring PETSc to compile on your system
=============================================================================================
TESTING: checkCCompiler from config.setCompilers(config/BuildSystem/config/setCompilers.py:1341)*******************************************************************************
         UNABLE to CONFIGURE with GIVEN OPTIONS    (see configure.log for details):
-------------------------------------------------------------------------------
C compiler you provided with -with-cc=mpicc cannot be found or does not work.
Cannot compile/link C with mpicc.

As for the case of WSL2, I will try to install that on my PC. Meanwhile, could you please look into this issue

Thank you

Ali

-----Original Message-----
From: Satish Balay <balay at mcs.anl.gov> 
Sent: Monday, October 31, 2022 10:56 PM
To: Satish Balay via petsc-users <petsc-users at mcs.anl.gov>
Cc: Matthew Knepley <knepley at gmail.com>; Mohammad Ali Yaqteen <mhyaqteen at sju.ac.kr>
Subject: Re: [petsc-users] PETSc Windows Installation

BTW: If you have WSL2 on windows - it might be easier to build/use PETSc.

Satish

On Mon, 31 Oct 2022, Satish Balay via petsc-users wrote:

> Make sure you have cygwin openmpi installed [and cywin blas/lapack]
> 
> $ cygcheck -cd |grep openmpi
> libopenmpi-devel              4.1.2-1
> libopenmpi40                  4.1.2-1
> libopenmpifh40                4.1.2-1
> libopenmpiusef08_40           4.1.2-1
> libopenmpiusetkr40            4.1.2-1
> openmpi                       4.1.2-1
> $ cygcheck -cd |grep lapack
> liblapack-devel               3.10.1-1
> liblapack0                    3.10.1-1
> 
> 
> > ./configure --with-cc=gcc --with-cxx=0 --with-fc=0 
> > --download-f2cblaslapack
> 
> Should be:
> 
> > > $ ./configure --download-scalapack --download-mumps
> 
> i.e [default] --with-cc=mpicc --with-cxx=mpicxx --with-fc=mpif90 [an 
> default cygwin blas/lapack]
> 
> Satish
> 
> 
> On Mon, 31 Oct 2022, Matthew Knepley wrote:
> 
> > On Mon, Oct 31, 2022 at 1:56 AM Mohammad Ali Yaqteen 
> > <mhyaqteen at sju.ac.kr>
> > wrote:
> > 
> > > Dear Satish
> > >
> > > When I configure PETSc with (./configure --with-cc=gcc 
> > > --with-cxx=0
> > > --with-fc=0 --download-f2cblaslapack) it runs as I shared 
> > > initially which you said is not an issue anymore. But when I add  
> > > (--download-scalapack
> > > --download-mumps) or configure with these later, it gives the 
> > > following
> > > error:
> > >
> > > $ ./configure --download-scalapack --download-mumps
> > >
> > > =============================================================================================
> > >                          Configuring PETSc to compile on your 
> > > system
> > >
> > > ==================================================================
> > > ===========================
> > > TESTING: FortranMPICheck from
> > > config.packages.MPI(config/BuildSystem/config/packages/MPI.py:614)*******************************************************************************
> > >          UNABLE to CONFIGURE with GIVEN OPTIONS    (see configure.log for
> > > details):
> > >
> > > ------------------------------------------------------------------
> > > ------------- Fortran error! mpi_init() could not be located!
> > >
> > > ******************************************************************
> > > *************
> > >
> > > What could be the problem here?
> > >
> > 
> > Without configure.log we cannot tell what went wrong. However, from 
> > the error message, I would guess that your MPI was not built with 
> > Fortran bindings. You need these for those packages.
> > 
> >   Thanks,
> > 
> >      Matt
> > 
> > 
> > > Your help is highly appreciated.
> > >
> > > Thank you
> > > Ali
> > >
> > > -----Original Message-----
> > > From: Satish Balay <balay at mcs.anl.gov>
> > > Sent: Saturday, October 29, 2022 2:11 PM
> > > To: Mohammad Ali Yaqteen <mhyaqteen at sju.ac.kr>
> > > Cc: Matthew Knepley <knepley at gmail.com>; petsc-users at mcs.anl.gov
> > > Subject: Re: [petsc-users] PETSc Windows Installation
> > >
> > > On Sat, 29 Oct 2022, Mohammad Ali Yaqteen wrote:
> > >
> > > > I haven’t accessed PETSC or given any command of my own. I was 
> > > > just
> > > installing by following the instructions. I don’t know why it is 
> > > attaching the debugger. Although it says “Possible error running 
> > > C/C++
> > > src/snes/tutorials/ex19 with 1 MPI process” which I think is 
> > > indicating of missing of MPI!
> > >
> > > The diff is not smart enough to detect the extra message from 
> > > cygwin/OpenMPI - hence it assumes there is a potential problem - 
> > > and prints the above message.
> > >
> > > But you can assume its installed properly - and use it.
> > >
> > > Satish
> > > >
> > > > From: Matthew Knepley <knepley at gmail.com>
> > > > Sent: Friday, October 28, 2022 10:31 PM
> > > > To: Mohammad Ali Yaqteen <mhyaqteen at sju.ac.kr>
> > > > Cc: petsc-users at mcs.anl.gov
> > > > Subject: Re: [petsc-users] PETSc Windows Installation
> > > >
> > > > On Fri, Oct 28, 2022 at 9:11 AM Mohammad Ali Yaqteen <
> > > mhyaqteen at sju.ac.kr<mailto:mhyaqteen at sju.ac.kr>> wrote:
> > > > Dear Sir,
> > > >
> > > > During the Installation of PETSc in windows, I installed Cygwin 
> > > > and the
> > > required libraries as mentioned on your website:
> > > > [cid:image001.png at 01D8EB93.7C17E410]
> > > > However, when I install PETSc using the configure commands 
> > > > present on
> > > the petsc website:
> > > >
> > > > ./configure --with-cc=gcc --with-cxx=0 --with-fc=0
> > > --download-f2cblaslapack --download-mpich
> > > >
> > > > it gives me the following error:
> > > >
> > > > [cid:image002.png at 01D8EB93.7C17E410]
> > > >
> > > > I already installed OpenMPI using Cygwin installer but it still 
> > > > asks me
> > > to. When I configure without “—download-mpich” and run “make check”
> > > command, it gives me the following errors:
> > > >
> > > > [cid:image003.png at 01D8EB93.7C17E410]
> > > >
> > > > Could you kindly look into this and help me with this? Your 
> > > > prompt
> > > response will highly be appreciated.
> > > >
> > > > The runs look fine.
> > > >
> > > > The test should not try to attach the debugger. Do you have that 
> > > > in the
> > > PETSC_OPTIONS env variable?
> > > >
> > > >   Thanks,
> > > >
> > > >      Matt
> > > >
> > > > Thank you!
> > > > Mohammad Ali
> > > > Researcher, Sejong University
> > > >
> > > >
> > > > --
> > > > What most experimenters take for granted before they begin their
> > > experiments is infinitely more interesting than any results to 
> > > which their experiments lead.
> > > > -- Norbert Wiener
> > > >
> > > > https://www.cse.buffalo.edu/~knepley/<
> > > http://www.cse.buffalo.edu/~knepley/>
> > > >
> > >
> > 
> > 
> > 
> 


More information about the petsc-users mailing list