Hi Sonya,

As this is Fortran 90, I think you should be using the double colon to allocate 
variables:

PetscReal :: norm

Regards,
Wadud.

-----Original Message-----
From: petsc-users-bounces at mcs.anl.gov 
[mailto:[email protected]] On Behalf Of Sonya Blade
Sent: 29 April 2013 13:10
To: petsc-users at mcs.anl.gov
Subject: EXTERNAL: Re: [petsc-users] EXTERNAL: How to run Petsc in Fortran

> What is the compilation command you are executing? It is probably?
> because you are not running the pre-processor in Fortran which is 
> switched off in the PGI compiler by default. 
> Regards, 
> 
> Wadud. 
> 
?
What it's got anything to do with PGI compiler I'm using Gnu Fortran?
I try to compile program with the given command lines executions.

-------------- Build: Debug in Petsc_Fortran (compiler: GNU GFortran 
Compiler)---------------

gfortran.exe -Wall ?-g ?-Wall ? 
-IC:\Users\....\Downloads\petsc-3.3-p6\include\finclude 
-IC:\Users\...\Downloads\petsc-3.3-p6\arch-mswin-c-debug\include ?-c 
D:\....\PROJECTS\CBFortran\Petsc_Fortran\main.f90 -o obj\Debug\main.o




>Are you sure that your compiler is preprocessing the file? You usually need
>to name it *.F.
>
>   Matt

I've tried with every possible fortran file extension, I'm sure that file is 
being?
pre-processed because if I comment the line of "PetscReal norm" it compiles and 
runs?
normally and produces the print statement on console screen.

Regards,                                          

___________________________________________________
____________________________

The information in this email and in any attachment(s) is 
commercial in confidence. If you are not the named addressee(s) 
or 
if you receive this email in error then any distribution, copying or 
use of this communication or the information in it is strictly 
prohibited. Please notify us immediately by email at 
admin.internet(at)awe.co.uk, and then delete this message from 
your computer. While attachments are virus checked, AWE plc 
does not accept any liability in respect of any virus which is not 
detected.

AWE Plc
Registered in England and Wales
Registration No 02763902
AWE, Aldermaston, Reading, RG7 4PR

Reply via email to