Re: [petsc-users] Configuration error during OpenBLAS

2020-07-31 Thread Eda Oktay
Dear Satish,

Thank you so much for your replies. I installed git and I was able to
configure PETSc.

Thanks again!

Eda

Satish Balay , 30 Tem 2020 Per, 18:32 tarihinde şunu yazdı:
>
> On Thu, 30 Jul 2020, Eda Oktay wrote:
>
> > Dear Satish,
> >
> > I am sorry but I couldn't understand what should I do. Am I getting this
> > error because of case insensitivity?
>
> Its a bug in configure. I sent the fix [diff - 2 different fixes, you can try 
> any one of them] in a different reply.
>
> >
> > If I am, why now? I mean I configured Petsc with exact same options before
> > in 2 machines. What can be the reason?
>
> Likely you have git installed on the other 2 machines - so this issue didn't 
> come up. Without git - a tarball gets used, this issue is with tarball usage.
>
> [or if don't have git on these machines as well - they likely have case 
> insensitive file system - aka MacOS]
>
> Satish


Re: [petsc-users] Configuration error during OpenBLAS

2020-07-30 Thread Satish Balay via petsc-users
On Thu, 30 Jul 2020, Eda Oktay wrote:

> Dear Satish,
> 
> I am sorry but I couldn't understand what should I do. Am I getting this
> error because of case insensitivity?

Its a bug in configure. I sent the fix [diff - 2 different fixes, you can try 
any one of them] in a different reply.

> 
> If I am, why now? I mean I configured Petsc with exact same options before
> in 2 machines. What can be the reason?

Likely you have git installed on the other 2 machines - so this issue didn't 
come up. Without git - a tarball gets used, this issue is with tarball usage.

[or if don't have git on these machines as well - they likely have case 
insensitive file system - aka MacOS]

Satish


Re: [petsc-users] Configuration error during OpenBLAS

2020-07-30 Thread Eda Oktay
Dear Satish,

I am sorry but I couldn't understand what should I do. Am I getting this
error because of case insensitivity?

If I am, why now? I mean I configured Petsc with exact same options before
in 2 machines. What can be the reason?

Thanks!

Eda

On Thu, Jul 30, 2020, 6:21 PM Satish Balay via petsc-users <
petsc-users@mcs.anl.gov> wrote:

> Generally we recommend using system blas/lapack
>
> Wrt: Blis - the usage is slightly complicated. It needs additional lapack
>
> So I think - if using blis - the following 2 modes might work
>
> --download-blis --download-f2cblaslapack
> --download-blis [system lapack]
>
> Satish
>
> On Thu, 30 Jul 2020, Victor Eijkhout wrote:
>
> >
> >
> > On , 2020Jul30, at 07:17, Matthew Knepley  knep...@gmail.com>> wrote:
> >
> > Shouldn't we be
> >
> > Be recommending Blis instead of OpenBlas?
> >
> > Victor.
> >
> >
>
>


Re: [petsc-users] Configuration error during OpenBLAS

2020-07-30 Thread Satish Balay via petsc-users
Generally we recommend using system blas/lapack

Wrt: Blis - the usage is slightly complicated. It needs additional lapack

So I think - if using blis - the following 2 modes might work

--download-blis --download-f2cblaslapack
--download-blis [system lapack]

Satish

On Thu, 30 Jul 2020, Victor Eijkhout wrote:

> 
> 
> On , 2020Jul30, at 07:17, Matthew Knepley 
> mailto:knep...@gmail.com>> wrote:
> 
> Shouldn't we be
> 
> Be recommending Blis instead of OpenBlas?
> 
> Victor.
> 
> 



Re: [petsc-users] Configuration error during OpenBLAS

2020-07-30 Thread Satish Balay via petsc-users
Normally - when the name is picked up from PACKAGENAME.py - and it can be 
overwritten by - for ex:

diff --git a/config/BuildSystem/config/packages/openblas.py 
b/config/BuildSystem/config/packages/openblas.py
index 97fd5da67e..2f65b94fde 100644
--- a/config/BuildSystem/config/packages/openblas.py
+++ b/config/BuildSystem/config/packages/openblas.py
@@ -15,6 +15,7 @@ class Configure(config.package.Package):
 self.gitcommit  = 'e7c4d6705a41910240dd19b9e7082a422563bf15'
 self.versionname= 'OPENBLAS_VERSION'
 self.download   = 
['git://https://github.com/xianyi/OpenBLAS.git','https://github.com/xianyi/OpenBLAS/archive/'+self.gitcommit+'.tar.gz']
+self.downloaddirnames   = ['OpenBLAS','openblas']
 self.optionalincludes   = ['openblas_config.h']
 self.functions  = ['openblas_get_config']
 self.liblist= [['libopenblas.a']]


And fixing this to do the check in a 'case insensitive way' should be fine.

diff --git a/config/BuildSystem/config/package.py 
b/config/BuildSystem/config/package.py
index 130ef1db3e..5066f53e42 100644
--- a/config/BuildSystem/config/package.py
+++ b/config/BuildSystem/config/package.py
@@ -638,7 +638,7 @@ class Package(config.base.Configure):
   def matchExcludeDir(self,dir):
 '''Check is the dir matches something in the excluded directory list'''
 for exdir in self.excludedDirs:
-  if dir.startswith(exdir):
+  if dir.lower().startswith(exdir.lower()):
 return 1
 return 0
 
@@ -718,7 +718,7 @@ If its a remote branch, use: origin/'+self.gitcommit+' for 
commit.')
   Dir.append(hgpkg)
 for d in pkgdirs:
   for j in self.downloaddirnames:
-if d.startswith(j) and os.path.isdir(os.path.join(packages, d)) and 
not self.matchExcludeDir(d):
+if d.lower().startswith(j.lower()) and 
os.path.isdir(os.path.join(packages, d)) and not self.matchExcludeDir(d):
   Dir.append(d)
 
 if len(Dir) > 1:


Ok - the MR is at https://gitlab.com/petsc/petsc/-/merge_requests/3011

Satish

On Thu, 30 Jul 2020, Matthew Knepley wrote:

> Satish,
> 
> Shouldn't we be checking in a case insensitive way, or do we want case
> sensitivity here?
> 
>   Looking for OPENBLAS at git.openblas, hg.openblas or
> a directory starting with ['openblas']
>   Could not locate an existing copy of OPENBLAS:
> ['Chaco-2.2-p2', 'slepc-v3.13.2',
> 'petsc-pkg-metis-ca7a59e6283f',
> 'OpenBLAS-e7c4d6705a41910240dd19b9e7082a422563bf15',
> 'petsc-pkg-parmetis-475d8facbb32', 'mpich-3.3.2']
> 
>   Thanks,
> 
>  Matt
> 
> On Thu, Jul 30, 2020 at 5:07 AM Eda Oktay  wrote:
> 
> > Hi all,
> >
> > I am trying to configure petsc-3.13.2 to ubuntu with the following line:
> >
> > ./configure --with-cc=gcc --with-cxx=g++ --with-fc=gfortran
> > --download-mpich --download-openblas --download-metis
> > --download-parmetis --download-chaco
> > --download-slepc=/home/eda/slepc-v3.13.2.tar.gz  --with-X=1
> >
> > However, I am getting the following error message:
> >
> >
> >
> >  
> > ***
> >  UNABLE to CONFIGURE with GIVEN OPTIONS(see configure.log
> > for details):
> >
> > ---
> > Error during download/extract/detection of OPENBLAS:
> > Could not locate downloaded package OPENBLAS in
> > /home/eda/petsc-3.13.2/arch-linux-c-debug/externalpackages
> >
> > **
> >
> > I attached the configure.log, too.
> >
> > Should I download OpenBLAS separately and then use
> > --download-opeblas=/home/.?
> >
> > If so, which version should I use for petsc-3.13.2?
> >
> > Thanks!
> >
> > Eda
> >
> 
> 
> 



Re: [petsc-users] Configuration error during OpenBLAS

2020-07-30 Thread Victor Eijkhout


On , 2020Jul30, at 07:17, Matthew Knepley 
mailto:knep...@gmail.com>> wrote:

Shouldn't we be

Be recommending Blis instead of OpenBlas?

Victor.



Re: [petsc-users] Configuration error during OpenBLAS

2020-07-30 Thread Matthew Knepley
Satish,

Shouldn't we be checking in a case insensitive way, or do we want case
sensitivity here?

  Looking for OPENBLAS at git.openblas, hg.openblas or
a directory starting with ['openblas']
  Could not locate an existing copy of OPENBLAS:
['Chaco-2.2-p2', 'slepc-v3.13.2',
'petsc-pkg-metis-ca7a59e6283f',
'OpenBLAS-e7c4d6705a41910240dd19b9e7082a422563bf15',
'petsc-pkg-parmetis-475d8facbb32', 'mpich-3.3.2']

  Thanks,

 Matt

On Thu, Jul 30, 2020 at 5:07 AM Eda Oktay  wrote:

> Hi all,
>
> I am trying to configure petsc-3.13.2 to ubuntu with the following line:
>
> ./configure --with-cc=gcc --with-cxx=g++ --with-fc=gfortran
> --download-mpich --download-openblas --download-metis
> --download-parmetis --download-chaco
> --download-slepc=/home/eda/slepc-v3.13.2.tar.gz  --with-X=1
>
> However, I am getting the following error message:
>
>
>
>  
> ***
>  UNABLE to CONFIGURE with GIVEN OPTIONS(see configure.log
> for details):
>
> ---
> Error during download/extract/detection of OPENBLAS:
> Could not locate downloaded package OPENBLAS in
> /home/eda/petsc-3.13.2/arch-linux-c-debug/externalpackages
>
> **
>
> I attached the configure.log, too.
>
> Should I download OpenBLAS separately and then use
> --download-opeblas=/home/.?
>
> If so, which version should I use for petsc-3.13.2?
>
> Thanks!
>
> Eda
>


-- 
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/ 


Re: [petsc-users] configuration error

2017-10-31 Thread Satish Balay
I've already replied to this issue

Try a fresh build - and do not reuse --prefix for different version builds.

Have you tried doing this?

Satish

On Tue, 31 Oct 2017, Manav Bhatia wrote:

> Thanks, Barry. 
> 
> Does this also address the mumps compilation issue that I had shared in the 
> same thread: 
> 
> mumps_c.c:307:53: error: no member named 'nnz' in 'CMUMPS_STRUC_C'; did you 
> mean 'nz'?
> mumps_par->n=0; mumps_par->nz=0; mumps_par->nnz=0; 
> mumps_par->nz_loc=0; mumps_par->nnz_loc=0; 
> mumps_par->nelt=0;mumps_par->instance_number=0;mumps_par->deficiency=0;mumps_par->lwk_user=0;mumps_par->size_schur=0;mumps_par->lrhs=0;
>  mumps_par->lredrhs=0; mumps_par->nrhs=0; mumps_par->nz_rhs=0; 
> mumps_par->lsol_loc=0;
> ^~~
> nz
> /Users/manav/Documents/codes/numerical_lib/petsc/include/cmumps_c.h:56:20: 
> note: 'nz' declared here
> MUMPS_INT  nz;
>^
> mumps_c.c:307:92: error: no member named 'nnz_loc' in 'CMUMPS_STRUC_C'; did 
> you mean 'nz_loc'?
> mumps_par->n=0; mumps_par->nz=0; mumps_par->nnz=0; 
> mumps_par->nz_loc=0; mumps_par->nnz_loc=0; 
> mumps_par->nelt=0;mumps_par->instance_number=0;mumps_par->deficiency=0;mumps_par->lwk_user=0;mumps_par->size_schur=0;mumps_par->lrhs=0;
>  mumps_par->lredrhs=0; mumps_par->nrhs=0; mumps_par->nz_rhs=0; 
> mumps_par->lsol_loc=0;
>   
>  ^~~
>   
>  nz_loc
> /Users/manav/Documents/codes/numerical_lib/petsc/include/cmumps_c.h:62:20: 
> note: 'nz_loc' declared here
> MUMPS_INT  nz_loc;
>^
> mumps_c.c:419:42: error: no member named 'nnz' in 'CMUMPS_STRUC_C'; did you 
> mean 'nz'?
>   &(mumps_par->nz), &(mumps_par->nnz), irn, _avail, jcn, 
> _avail, a, _avail,
>  ^~~
>  nz
> /Users/manav/Documents/codes/numerical_lib/petsc/include/cmumps_c.h:56:20: 
> note: 'nz' declared here
> MUMPS_INT  nz;
>^
> mumps_c.c:420:46: error: no member named 'nnz_loc' in 'CMUMPS_STRUC_C'; did 
> you mean 'nz_loc'?
>   &(mumps_par->nz_loc), &(mumps_par->nnz_loc), irn_loc, 
> _loc_avail, jcn_loc, _loc_avail,
>  ^~~
>  nz_loc
> /Users/manav/Documents/codes/numerical_lib/petsc/include/cmumps_c.h:62:20: 
> note: 'nz_loc' declared here
> MUMPS_INT  nz_loc;
>^
> mumps_c.c:419:29: warning: incompatible pointer types passing 'int *' to 
> parameter of type 'int64_t *' (aka 'long long *') 
> [-Wincompatible-pointer-types]
>   &(mumps_par->nz), &(mumps_par->nnz), irn, _avail, jcn, 
> _avail, a, _avail,
> ^
> mumps_c.c:99:28: note: passing argument to parameter 'nnz' here
>MUMPS_INT8 *nnz,
>^
> mumps_c.c:420:33: warning: incompatible pointer types passing 'int *' to 
> parameter of type 'int64_t *' (aka 'long long *') 
> [-Wincompatible-pointer-types]
>   &(mumps_par->nz_loc), &(mumps_par->nnz_loc), irn_loc, 
> _loc_avail, jcn_loc, _loc_avail,
> ^
> mumps_c.c:107:28: note: passing argument to parameter 'nnz_loc' here
>MUMPS_INT8 *nnz_loc,
>^
> 2 warnings and 4 errors generated.
> 
> 
> > On Oct 31, 2017, at 4:25 PM, Smith, Barry F.  wrote:
> > 
> > 
> >  Manav,
> > 
> >Thanks for reporting the problem 
> > 
> >  Fande,
> > 
> >Thanks for the pointer.
> > 
> >Satish determined the correct long term fix and it is in the branch 
> > barry/fix-lto_library-option-maint and will be put in the maint branch and 
> > master branch if it passes the testing tonight.
> > 
> >   Barry
> > 
> > 
> >> On Oct 30, 2017, at 11:36 AM, Kong, Fande  wrote:
> >> 
> >> We had exactly the same issue when upgraded compilers.  I guess this is 
> >> somehow related to gfortran.  A simple way to work around for us is to 
> >> change if with_rpath: to  if False at line 54 of 
> >> config/BuildSystem/config/libraries.py. 
> >> 
> >> Not sure if it works for you.
> >> 
> >> Fande,
> >> 
> >> 
> >> 
> >> 
> >> On Mon, Oct 30, 2017 at 10:14 AM, Manav Bhatia  
> >> wrote:
> >> Hi, 
> >> 
> >>  I am trying to install pets 3.8 on a new MacBook machine with OS 10.13. I 
> >> have installed openmpi from macports and I am getting this error on 
> >> configuration. Attached is also the configure.log file. 
> >> 
> >>  I am not sure how to proceed with this. Any advice will be greatly 
> >> appreciated!
> >> 
> >> Regards,
> >> Manav
> >> 
> >> 

Re: [petsc-users] configuration error

2017-10-31 Thread Manav Bhatia
Thanks, Barry. 

Does this also address the mumps compilation issue that I had shared in the 
same thread: 

mumps_c.c:307:53: error: no member named 'nnz' in 'CMUMPS_STRUC_C'; did you 
mean 'nz'?
mumps_par->n=0; mumps_par->nz=0; mumps_par->nnz=0; mumps_par->nz_loc=0; 
mumps_par->nnz_loc=0; 
mumps_par->nelt=0;mumps_par->instance_number=0;mumps_par->deficiency=0;mumps_par->lwk_user=0;mumps_par->size_schur=0;mumps_par->lrhs=0;
 mumps_par->lredrhs=0; mumps_par->nrhs=0; mumps_par->nz_rhs=0; 
mumps_par->lsol_loc=0;
^~~
nz
/Users/manav/Documents/codes/numerical_lib/petsc/include/cmumps_c.h:56:20: 
note: 'nz' declared here
MUMPS_INT  nz;
   ^
mumps_c.c:307:92: error: no member named 'nnz_loc' in 'CMUMPS_STRUC_C'; did you 
mean 'nz_loc'?
mumps_par->n=0; mumps_par->nz=0; mumps_par->nnz=0; mumps_par->nz_loc=0; 
mumps_par->nnz_loc=0; 
mumps_par->nelt=0;mumps_par->instance_number=0;mumps_par->deficiency=0;mumps_par->lwk_user=0;mumps_par->size_schur=0;mumps_par->lrhs=0;
 mumps_par->lredrhs=0; mumps_par->nrhs=0; mumps_par->nz_rhs=0; 
mumps_par->lsol_loc=0;

   ^~~

   nz_loc
/Users/manav/Documents/codes/numerical_lib/petsc/include/cmumps_c.h:62:20: 
note: 'nz_loc' declared here
MUMPS_INT  nz_loc;
   ^
mumps_c.c:419:42: error: no member named 'nnz' in 'CMUMPS_STRUC_C'; did you 
mean 'nz'?
  &(mumps_par->nz), &(mumps_par->nnz), irn, _avail, jcn, 
_avail, a, _avail,
 ^~~
 nz
/Users/manav/Documents/codes/numerical_lib/petsc/include/cmumps_c.h:56:20: 
note: 'nz' declared here
MUMPS_INT  nz;
   ^
mumps_c.c:420:46: error: no member named 'nnz_loc' in 'CMUMPS_STRUC_C'; did you 
mean 'nz_loc'?
  &(mumps_par->nz_loc), &(mumps_par->nnz_loc), irn_loc, _loc_avail, 
jcn_loc, _loc_avail,
 ^~~
 nz_loc
/Users/manav/Documents/codes/numerical_lib/petsc/include/cmumps_c.h:62:20: 
note: 'nz_loc' declared here
MUMPS_INT  nz_loc;
   ^
mumps_c.c:419:29: warning: incompatible pointer types passing 'int *' to 
parameter of type 'int64_t *' (aka 'long long *') [-Wincompatible-pointer-types]
  &(mumps_par->nz), &(mumps_par->nnz), irn, _avail, jcn, 
_avail, a, _avail,
^
mumps_c.c:99:28: note: passing argument to parameter 'nnz' here
   MUMPS_INT8 *nnz,
   ^
mumps_c.c:420:33: warning: incompatible pointer types passing 'int *' to 
parameter of type 'int64_t *' (aka 'long long *') [-Wincompatible-pointer-types]
  &(mumps_par->nz_loc), &(mumps_par->nnz_loc), irn_loc, _loc_avail, 
jcn_loc, _loc_avail,
^
mumps_c.c:107:28: note: passing argument to parameter 'nnz_loc' here
   MUMPS_INT8 *nnz_loc,
   ^
2 warnings and 4 errors generated.


> On Oct 31, 2017, at 4:25 PM, Smith, Barry F.  wrote:
> 
> 
>  Manav,
> 
>Thanks for reporting the problem 
> 
>  Fande,
> 
>Thanks for the pointer.
> 
>Satish determined the correct long term fix and it is in the branch 
> barry/fix-lto_library-option-maint and will be put in the maint branch and 
> master branch if it passes the testing tonight.
> 
>   Barry
> 
> 
>> On Oct 30, 2017, at 11:36 AM, Kong, Fande  wrote:
>> 
>> We had exactly the same issue when upgraded compilers.  I guess this is 
>> somehow related to gfortran.  A simple way to work around for us is to 
>> change if with_rpath: to  if False at line 54 of 
>> config/BuildSystem/config/libraries.py. 
>> 
>> Not sure if it works for you.
>> 
>> Fande,
>> 
>> 
>> 
>> 
>> On Mon, Oct 30, 2017 at 10:14 AM, Manav Bhatia  wrote:
>> Hi, 
>> 
>>  I am trying to install pets 3.8 on a new MacBook machine with OS 10.13. I 
>> have installed openmpi from macports and I am getting this error on 
>> configuration. Attached is also the configure.log file. 
>> 
>>  I am not sure how to proceed with this. Any advice will be greatly 
>> appreciated!
>> 
>> Regards,
>> Manav
>> 
>> ===
>> Configuring PETSc to compile on your system  
>>  
>> ===
>> ===
>>  
>>   

Re: [petsc-users] configuration error

2017-10-31 Thread Smith, Barry F.

  Manav,

Thanks for reporting the problem 

  Fande,

Thanks for the pointer.

Satish determined the correct long term fix and it is in the branch 
barry/fix-lto_library-option-maint and will be put in the maint branch and 
master branch if it passes the testing tonight.

   Barry


> On Oct 30, 2017, at 11:36 AM, Kong, Fande  wrote:
> 
> We had exactly the same issue when upgraded compilers.  I guess this is 
> somehow related to gfortran.  A simple way to work around for us is to change 
> if with_rpath: to  if False at line 54 of 
> config/BuildSystem/config/libraries.py. 
> 
> Not sure if it works for you.
> 
> Fande,
> 
> 
> 
> 
> On Mon, Oct 30, 2017 at 10:14 AM, Manav Bhatia  wrote:
> Hi, 
> 
>   I am trying to install pets 3.8 on a new MacBook machine with OS 10.13. I 
> have installed openmpi from macports and I am getting this error on 
> configuration. Attached is also the configure.log file. 
> 
>   I am not sure how to proceed with this. Any advice will be greatly 
> appreciated!
> 
> Regards,
> Manav
> 
> ===
>  Configuring PETSc to compile on your system  
>  
> ===
> ===
>   
>   
> * WARNING: Using default optimization C flags -g -O3  
>   
>  You 
> might consider manually setting optimal optimization flags for your system 
> with  
>  
> COPTFLAGS="optimization flags" see config/examples/arch-*-opt.py for examples 
>   
>   
> ===
>   
> 
> ===
>   
>   
> * WARNING: Using default C++ optimization flags -g -O3
>   
>  You 
> might consider manually setting optimal optimization flags for your system 
> with  
>  
> CXXOPTFLAGS="optimization flags" see config/examples/arch-*-opt.py for 
> examples  
>  
> ===
>   
> 
> ===
>   
>   
> * WARNING: Using default FORTRAN optimization flags -g -O 
>   
>  You 
> might consider manually setting optimal optimization flags for your system 
> with  
>  
> FOPTFLAGS="optimization flags" see config/examples/arch-*-opt.py for examples 
>   
>   
> ===
>   
> 
> ===
>   

Re: [petsc-users] configuration error

2017-10-30 Thread Satish Balay
The compiler library detection code is a bit messy. Its there to help
with interlanguage linking.

One workarround [to such failures] is to tell configure not to guess,
and specify the relavent info.

For eg:

balay@ipro^~/petsc(master) $ ./configure --download-mpich --download-hypre 
CC=clang CXX=clang++ FC=gfortran --with-clib-autodetect=0 
--with-fortranlib-autodetect=0 --with-cxxlib-autodetect=0 
LIBS='-L/usr/local/Cellar/gcc/7.2.0/lib/gcc/7/gcc/x86_64-apple-darwin17.0.0/7.2.0/../../..
 -lgfortran -lc++'

Satish


On Mon, 30 Oct 2017, Kong, Fande wrote:

> We had exactly the same issue when upgraded compilers.  I guess this is
> somehow related to gfortran.  A simple way to work around for us is to
> change* if with_rpath*: to * if False *at line 54 of
> config/BuildSystem/config/libraries.py.
> 
> Not sure if it works for you.
> 
> Fande,
> 
> 
> 
> 
> On Mon, Oct 30, 2017 at 10:14 AM, Manav Bhatia 
> wrote:
> 
> > Hi,
> >
> >   I am trying to install pets 3.8 on a new MacBook machine with OS 10.13.
> > I have installed openmpi from macports and I am getting this error on
> > configuration. Attached is also the configure.log file.
> >
> >   I am not sure how to proceed with this. Any advice will be greatly
> > appreciated!
> >
> > Regards,
> > Manav
> >
> > 
> > ===
> >  Configuring PETSc to compile on your system
> >
> > 
> > ===
> > ===
> >
> >
> >   * WARNING: Using default optimization C flags -g -O3
> >
> >
> > You might consider manually setting optimal optimization flags for your
> > system with
> >
> >   COPTFLAGS="optimization flags" see config/examples/arch-*-opt.py for
> > examples
> >
> >   
> > ===
> >
> >
> > ===
> >
> >
> >   * WARNING: Using default C++ optimization flags -g -O3
> >
> >
> > You might consider manually setting optimal optimization flags for your
> > system with
> >
> >   CXXOPTFLAGS="optimization flags" see config/examples/arch-*-opt.py
> > for examples
> >
> > 
> > ===
> >
> >
> > ===
> >
> >
> >   * WARNING: Using default FORTRAN optimization flags -g -O
> >
> >
> > You might consider manually setting optimal optimization flags for your
> > system with
> >
> >   FOPTFLAGS="optimization flags" see config/examples/arch-*-opt.py for
> > examples
> >
> >   
> > ===
> >
> >
> > ===
> >
> >
> > WARNING! Compiling PETSc with no debugging, this should
> >
> >
> > only be done for timing and production runs. All
> > development should
> >
> > be done when configured using
> > --with-debugging=1
> >
> >   ==
> > =
> >
> >   TESTING: checkCLibraries
> > from config.compilers(config/BuildSystem/config/compilers.py:171)
> >
> >
> > 
> > ***
> >  UNABLE to CONFIGURE with GIVEN OPTIONS(see configure.log for
> > details):
> > 
> > ---
> > C libraries cannot directly be used from Fortran
> > 
> > ***
> >
> >
> >
> >
> >
> >
> 



Re: [petsc-users] configuration error

2017-10-30 Thread Satish Balay
--prefix=/Users/manav/Documents/codes/numerical_lib/petsc/petsc-3.8.0/../

You have a strange prefix. You are basically using:

--prefix=/Users/manav/Documents/codes/numerical_lib/petsc

The general convention is to use a different prefix for different versions of 
libraries [or different type of builds]

Can you redo a clean build [i.e rm -rf PETSC_ARCH]  into a clean prefix 
location?

Satish

On Mon, 30 Oct 2017, Manav Bhatia wrote:

> I am not getting errors with mumps (please see below). 
> Interestingly, I just compiled this on another machine with clang-3.8 and 
> gfortran-6.7 without problems.
> 
> -Manav
> 
> mumps_c.c:307:53: error: no member named 'nnz' in 'CMUMPS_STRUC_C'; did you 
> mean 'nz'?
> mumps_par->n=0; mumps_par->nz=0; mumps_par->nnz=0; 
> mumps_par->nz_loc=0; mumps_par->nnz_loc=0; 
> mumps_par->nelt=0;mumps_par->instance_number=0;mumps_par->deficiency=0;mumps_par->lwk_user=0;mumps_par->size_schur=0;mumps_par->lrhs=0;
>  mumps_par->lredrhs=0; mumps_par->nrhs=0; mumps_par->nz_rhs=0; 
> mumps_par->lsol_loc=0;
> ^~~
> nz
> /Users/manav/Documents/codes/numerical_lib/petsc/include/cmumps_c.h:56:20: 
> note: 'nz' declared here
> MUMPS_INT  nz;
>^
> mumps_c.c:307:92: error: no member named 'nnz_loc' in 'CMUMPS_STRUC_C'; did 
> you mean 'nz_loc'?
> mumps_par->n=0; mumps_par->nz=0; mumps_par->nnz=0; 
> mumps_par->nz_loc=0; mumps_par->nnz_loc=0; 
> mumps_par->nelt=0;mumps_par->instance_number=0;mumps_par->deficiency=0;mumps_par->lwk_user=0;mumps_par->size_schur=0;mumps_par->lrhs=0;
>  mumps_par->lredrhs=0; mumps_par->nrhs=0; mumps_par->nz_rhs=0; 
> mumps_par->lsol_loc=0;
>   
>  ^~~
>   
>  nz_loc
> /Users/manav/Documents/codes/numerical_lib/petsc/include/cmumps_c.h:62:20: 
> note: 'nz_loc' declared here
> MUMPS_INT  nz_loc;
>^
> mumps_c.c:419:42: error: no member named 'nnz' in 'CMUMPS_STRUC_C'; did you 
> mean 'nz'?
>   &(mumps_par->nz), &(mumps_par->nnz), irn, _avail, jcn, 
> _avail, a, _avail,
>  ^~~
>  nz
> /Users/manav/Documents/codes/numerical_lib/petsc/include/cmumps_c.h:56:20: 
> note: 'nz' declared here
> MUMPS_INT  nz;
>^
> mumps_c.c:420:46: error: no member named 'nnz_loc' in 'CMUMPS_STRUC_C'; did 
> you mean 'nz_loc'?
>   &(mumps_par->nz_loc), &(mumps_par->nnz_loc), irn_loc, 
> _loc_avail, jcn_loc, _loc_avail,
>  ^~~
>  nz_loc
> /Users/manav/Documents/codes/numerical_lib/petsc/include/cmumps_c.h:62:20: 
> note: 'nz_loc' declared here
> MUMPS_INT  nz_loc;
>^
> mumps_c.c:419:29: warning: incompatible pointer types passing 'int *' to 
> parameter of type 'int64_t *' (aka 'long long *') 
> [-Wincompatible-pointer-types]
>   &(mumps_par->nz), &(mumps_par->nnz), irn, _avail, jcn, 
> _avail, a, _avail,
> ^
> mumps_c.c:99:28: note: passing argument to parameter 'nnz' here
>MUMPS_INT8 *nnz,
>^
> mumps_c.c:420:33: warning: incompatible pointer types passing 'int *' to 
> parameter of type 'int64_t *' (aka 'long long *') 
> [-Wincompatible-pointer-types]
>   &(mumps_par->nz_loc), &(mumps_par->nnz_loc), irn_loc, 
> _loc_avail, jcn_loc, _loc_avail,
> ^
> mumps_c.c:107:28: note: passing argument to parameter 'nnz_loc' here
>MUMPS_INT8 *nnz_loc,
>^
> 2 warnings and 4 errors generated.
> 
> 
> 
> > On Oct 30, 2017, at 11:36 AM, Kong, Fande  wrote:
> > 
> > We had exactly the same issue when upgraded compilers.  I guess this is 
> > somehow related to gfortran.  A simple way to work around for us is to 
> > change if with_rpath: to  if False at line 54 of 
> > config/BuildSystem/config/libraries.py. 
> > 
> > Not sure if it works for you.
> > 
> > Fande,
> > 
> > 
> > 
> > 
> > On Mon, Oct 30, 2017 at 10:14 AM, Manav Bhatia  > > wrote:
> > Hi, 
> > 
> >   I am trying to install pets 3.8 on a new MacBook machine with OS 10.13. I 
> > have installed openmpi from macports and I am getting this error on 
> > configuration. Attached is also the configure.log file. 
> > 
> >   I am not sure how to proceed with this. Any advice will be greatly 
> > appreciated!
> > 
> > Regards,
> > Manav
> > 
> > ===
> >  Configuring PETSc to compile on your system

Re: [petsc-users] configuration error

2017-10-30 Thread Manav Bhatia
I am not getting errors with mumps (please see below). 
Interestingly, I just compiled this on another machine with clang-3.8 and 
gfortran-6.7 without problems.

-Manav

mumps_c.c:307:53: error: no member named 'nnz' in 'CMUMPS_STRUC_C'; did you 
mean 'nz'?
mumps_par->n=0; mumps_par->nz=0; mumps_par->nnz=0; mumps_par->nz_loc=0; 
mumps_par->nnz_loc=0; 
mumps_par->nelt=0;mumps_par->instance_number=0;mumps_par->deficiency=0;mumps_par->lwk_user=0;mumps_par->size_schur=0;mumps_par->lrhs=0;
 mumps_par->lredrhs=0; mumps_par->nrhs=0; mumps_par->nz_rhs=0; 
mumps_par->lsol_loc=0;
^~~
nz
/Users/manav/Documents/codes/numerical_lib/petsc/include/cmumps_c.h:56:20: 
note: 'nz' declared here
MUMPS_INT  nz;
   ^
mumps_c.c:307:92: error: no member named 'nnz_loc' in 'CMUMPS_STRUC_C'; did you 
mean 'nz_loc'?
mumps_par->n=0; mumps_par->nz=0; mumps_par->nnz=0; mumps_par->nz_loc=0; 
mumps_par->nnz_loc=0; 
mumps_par->nelt=0;mumps_par->instance_number=0;mumps_par->deficiency=0;mumps_par->lwk_user=0;mumps_par->size_schur=0;mumps_par->lrhs=0;
 mumps_par->lredrhs=0; mumps_par->nrhs=0; mumps_par->nz_rhs=0; 
mumps_par->lsol_loc=0;

   ^~~

   nz_loc
/Users/manav/Documents/codes/numerical_lib/petsc/include/cmumps_c.h:62:20: 
note: 'nz_loc' declared here
MUMPS_INT  nz_loc;
   ^
mumps_c.c:419:42: error: no member named 'nnz' in 'CMUMPS_STRUC_C'; did you 
mean 'nz'?
  &(mumps_par->nz), &(mumps_par->nnz), irn, _avail, jcn, 
_avail, a, _avail,
 ^~~
 nz
/Users/manav/Documents/codes/numerical_lib/petsc/include/cmumps_c.h:56:20: 
note: 'nz' declared here
MUMPS_INT  nz;
   ^
mumps_c.c:420:46: error: no member named 'nnz_loc' in 'CMUMPS_STRUC_C'; did you 
mean 'nz_loc'?
  &(mumps_par->nz_loc), &(mumps_par->nnz_loc), irn_loc, _loc_avail, 
jcn_loc, _loc_avail,
 ^~~
 nz_loc
/Users/manav/Documents/codes/numerical_lib/petsc/include/cmumps_c.h:62:20: 
note: 'nz_loc' declared here
MUMPS_INT  nz_loc;
   ^
mumps_c.c:419:29: warning: incompatible pointer types passing 'int *' to 
parameter of type 'int64_t *' (aka 'long long *') [-Wincompatible-pointer-types]
  &(mumps_par->nz), &(mumps_par->nnz), irn, _avail, jcn, 
_avail, a, _avail,
^
mumps_c.c:99:28: note: passing argument to parameter 'nnz' here
   MUMPS_INT8 *nnz,
   ^
mumps_c.c:420:33: warning: incompatible pointer types passing 'int *' to 
parameter of type 'int64_t *' (aka 'long long *') [-Wincompatible-pointer-types]
  &(mumps_par->nz_loc), &(mumps_par->nnz_loc), irn_loc, _loc_avail, 
jcn_loc, _loc_avail,
^
mumps_c.c:107:28: note: passing argument to parameter 'nnz_loc' here
   MUMPS_INT8 *nnz_loc,
   ^
2 warnings and 4 errors generated.



> On Oct 30, 2017, at 11:36 AM, Kong, Fande  wrote:
> 
> We had exactly the same issue when upgraded compilers.  I guess this is 
> somehow related to gfortran.  A simple way to work around for us is to change 
> if with_rpath: to  if False at line 54 of 
> config/BuildSystem/config/libraries.py. 
> 
> Not sure if it works for you.
> 
> Fande,
> 
> 
> 
> 
> On Mon, Oct 30, 2017 at 10:14 AM, Manav Bhatia  > wrote:
> Hi, 
> 
>   I am trying to install pets 3.8 on a new MacBook machine with OS 10.13. I 
> have installed openmpi from macports and I am getting this error on 
> configuration. Attached is also the configure.log file. 
> 
>   I am not sure how to proceed with this. Any advice will be greatly 
> appreciated!
> 
> Regards,
> Manav
> 
> ===
>  Configuring PETSc to compile on your system  
>  
> ===
> ===
>   
>   
> * WARNING: Using default optimization C flags -g -O3  
>   
>  You 
> might consider manually setting optimal optimization flags for your 

Re: [petsc-users] configuration error

2017-10-30 Thread Manav Bhatia
Fande, 

  I made the change you recommended and it seems to have moved past that stage 
in the configuration.

  Thanks for your help!

Regards,
Manav


> On Oct 30, 2017, at 11:36 AM, Kong, Fande  wrote:
> 
> We had exactly the same issue when upgraded compilers.  I guess this is 
> somehow related to gfortran.  A simple way to work around for us is to change 
> if with_rpath: to  if False at line 54 of 
> config/BuildSystem/config/libraries.py. 
> 
> Not sure if it works for you.
> 
> Fande,
> 
> 
> 
> 
> On Mon, Oct 30, 2017 at 10:14 AM, Manav Bhatia  > wrote:
> Hi, 
> 
>   I am trying to install pets 3.8 on a new MacBook machine with OS 10.13. I 
> have installed openmpi from macports and I am getting this error on 
> configuration. Attached is also the configure.log file. 
> 
>   I am not sure how to proceed with this. Any advice will be greatly 
> appreciated!
> 
> Regards,
> Manav
> 
> ===
>  Configuring PETSc to compile on your system  
>  
> ===
> ===
>   
>   
> * WARNING: Using default optimization C flags -g -O3  
>   
>  You 
> might consider manually setting optimal optimization flags for your system 
> with  
>  
> COPTFLAGS="optimization flags" see config/examples/arch-*-opt.py for examples 
>   
>   
> ===
>   
> 
> ===
>   
>   
> * WARNING: Using default C++ optimization flags -g -O3
>   
>  You 
> might consider manually setting optimal optimization flags for your system 
> with  
>  
> CXXOPTFLAGS="optimization flags" see config/examples/arch-*-opt.py for 
> examples  
>  
> ===
>   
> 
> ===
>   
>   
> * WARNING: Using default FORTRAN optimization flags -g -O 
>   
>  You 
> might consider manually setting optimal optimization flags for your system 
> with  
>  
> FOPTFLAGS="optimization flags" see config/examples/arch-*-opt.py for examples 
>   
>   
> ===
>   
> 
> ===
>   
>

Re: [petsc-users] configuration error

2017-10-30 Thread Kong, Fande
We had exactly the same issue when upgraded compilers.  I guess this is
somehow related to gfortran.  A simple way to work around for us is to
change* if with_rpath*: to * if False *at line 54 of
config/BuildSystem/config/libraries.py.

Not sure if it works for you.

Fande,




On Mon, Oct 30, 2017 at 10:14 AM, Manav Bhatia 
wrote:

> Hi,
>
>   I am trying to install pets 3.8 on a new MacBook machine with OS 10.13.
> I have installed openmpi from macports and I am getting this error on
> configuration. Attached is also the configure.log file.
>
>   I am not sure how to proceed with this. Any advice will be greatly
> appreciated!
>
> Regards,
> Manav
>
> 
> ===
>  Configuring PETSc to compile on your system
>
> 
> ===
> ===
>
>
>   * WARNING: Using default optimization C flags -g -O3
>
>
> You might consider manually setting optimal optimization flags for your
> system with
>
>   COPTFLAGS="optimization flags" see config/examples/arch-*-opt.py for
> examples
>
>   
> ===
>
>
> ===
>
>
>   * WARNING: Using default C++ optimization flags -g -O3
>
>
> You might consider manually setting optimal optimization flags for your
> system with
>
>   CXXOPTFLAGS="optimization flags" see config/examples/arch-*-opt.py
> for examples
>
> 
> ===
>
>
> ===
>
>
>   * WARNING: Using default FORTRAN optimization flags -g -O
>
>
> You might consider manually setting optimal optimization flags for your
> system with
>
>   FOPTFLAGS="optimization flags" see config/examples/arch-*-opt.py for
> examples
>
>   
> ===
>
>
> ===
>
>
> WARNING! Compiling PETSc with no debugging, this should
>
>
> only be done for timing and production runs. All
> development should
>
> be done when configured using
> --with-debugging=1
>
>   ==
> =
>
>   TESTING: checkCLibraries
> from config.compilers(config/BuildSystem/config/compilers.py:171)
>
>
> 
> ***
>  UNABLE to CONFIGURE with GIVEN OPTIONS(see configure.log for
> details):
> 
> ---
> C libraries cannot directly be used from Fortran
> 
> ***
>
>
>
>
>
>


[petsc-users] configuration error on Windows with VS2005

2011-11-16 Thread Satish Balay
Please send the corresponding configure.log to petsc-maint at mcs.anl.gov

Satish

On Wed, 16 Nov 2011, Yixun Liu wrote:

 Hi,
 I have a configuration error as I install PETSc.
 
 According to the installation instructions, I first *Setup cygwin bash
 shell with Working Compilers:*
 
 C:\Program Files (x86)\Microsoft Visual Studio 8\VCc:\cygwin\bin\bash.exe
 --login
 
 I got the following message:
 
 Your group is currently mkpasswd.  This indicates that your
 gid is not in /etc/group and your uid is not in /etc/passwd.
 The /etc/passwd (and possibly /etc/group) files should be rebuilt.
 See the man pages for mkpasswd and mkgroup then, for example, run
 mkpasswd -l [-d]  /etc/passwd
 mkgroup  -l [-d]  /etc/group
 Note that the -d switch is necessary for domain users.
 
 Then I run the commands:
 mkpasswd -l  /etc/passwd and
 mkpasswd -l  /etc/group
 
 at last, as I run command cl, I got message:
 
 Microsoft (R) 32-bit C/C++ Optimizing Compiler Version 14.00.50727.762 for
 80x86
 Copyright (C) Microsoft Corporation.  All rights reserved.
 usage: cl [ option... ] filename... [ /link linkoption... ]
 
 So, I think it works now.
 
 Then I configure PETSc with the following command, but get the error C
 compiler you provided with -with-cc=win32fe cl does not work.
 
 
 liuy14 at CC1DR1C515W05 /cygdrive/c/Yixun/VC/petsc-3.2-p5#  ./configure
 --with-cc='win32fe cl' --with-fc='win32fe ifort'  --with-cxx='win 32fe cl'
 --download-f-blas-lapack=1
 
 ===
  Configuring PETSc to compile on your system
 ===
 TESTING: configureExternalPackagesDir from
 config.framework(config/BuildSystem/c
 TESTING: configureDebuggers from
 PETSc.utilities.debuggers(config/PETSc/utilitie
 TESTING: configureCMake from
 PETSc.utilities.CMake(config/PETSc/utilities/CMake.
 TESTING: configureCLanguage from
 PETSc.utilities.languages(config/PETSc/utilitie
 TESTING: configureLanguageSupport from
 PETSc.utilities.languages(config/PETSc/ut
 TESTING: configureExternC from
 PETSc.utilities.languages(config/PETSc/utilities/
 TESTING: configureFortranLanguage from
 PETSc.utilities.languages(config/PETSc/ut
 TESTING: configureMake from
 config.programs(config/BuildSystem/config/programs.p
 TESTING: configureMkdir from
 config.programs(config/BuildSystem/config/programs.
 TESTING: configurePrograms from
 config.programs(config/BuildSystem/config/progra
 TESTING: configureMercurial from
 config.sourceControl(config/BuildSystem/config/
 TESTING: configureCVS from
 config.sourceControl(config/BuildSystem/config/source
 TESTING: configureSubversion from
 config.sourceControl(config/BuildSystem/config
 TESTING: configureDirectories from
 PETSc.utilities.petscdir(config/PETSc/utiliti
 TESTING: configureExternalPackagesDir from
 PETSc.utilities.petscdir(config/PETSc
 TESTING: configureInstallationMethod from
 PETSc.utilities.petscdir(config/PETSc/
 TESTING: configureETags from
 PETSc.utilities.Etags(config/PETSc/utilities/Etags.
 TESTING: getDatafilespath from
 PETSc.utilities.dataFilesPath(config/PETSc/utilit
 TESTING: resetEnvCompilers from
 config.setCompilers(config/BuildSystem/config/se
 TESTING: checkMPICompilerOverride from
 config.setCompilers(config/BuildSystem/co
 TESTING: checkVendor from
 config.setCompilers(config/BuildSystem/config/setCompi
 TESTING: checkInitialFlags from
 config.setCompilers(config/BuildSystem/config/se
 TESTING: checkCCompiler from
 config.setCompilers(config/BuildSystem/config/setCo
   File
 /cygdrive/c/Yixun/VC/petsc-3.2-p5/config/BuildSystem/config/setCompilers
 .py, line 508, in checkCCompiler
 self.checkCompiler('C')
   File
 /cygdrive/c/Yixun/VC/petsc-3.2-p5/config/BuildSystem/config/setCompilers
 .py, line 410, in checkCompiler
 raise RuntimeError(msg)
 ***
  UNABLE to CONFIGURE with GIVEN OPTIONS(see configure.log for
 detail
 s):
 ---
 C compiler you provided with -with-cc=win32fe cl does not work
 ***
 
 
 Thank you for your help.
 
 Best,
 
 Yixun