[petsc-users] compiling PETSc using c++ compiler
Satish Balay
balay at mcs.anl.gov
Tue Oct 6 17:23:12 CDT 2020
Can you send the complete logs for this build [configure.log, make.log]?
Satish
On Tue, 6 Oct 2020, Sam Guo wrote:
> Dear PETSc dev team,
> When I compile PETSc using
> --with-cc=gcc --with-cxx=g++ --with-clanguage=cxx,
> I got following error:
> ../../../petsc/src/sys/objects/pinit.c: In function ‘PetscInitialize’:
> ../../../petsc/src/sys/objects/pinit.c:913:21: error: expected declaration
> specifiers or ‘...’ before numeric constant
> 913 | PetscComplex ic(0.0,1.0);
> | ^~~
> ../../../petsc/src/sys/objects/pinit.c:913:25: error: expected declaration
> specifiers or ‘...’ before numeric constant
> 913 | PetscComplex ic(0.0,1.0);
> | ^~~
> ../../../petsc/src/sys/objects/pinit.c:914:15: error: ‘ic’ undeclared
> (first use in this function)
> 914 | PETSC_i = ic;
> | ^~
> ../../../petsc/src/sys/objects/pinit.c:914:15: note: each undeclared
> identifier is reported only once for each function it appears in
>
> Thanks,
> Sam
>
More information about the petsc-users
mailing list