-
Notifications
You must be signed in to change notification settings - Fork 6
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Modified Makefile to work with both ifort or gfortran to build canopy-app (Tested on Hera for ifort) #75
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks @quaz115 , just added a few initial comments.
src/Makefile
Outdated
|
||
# Compiler | ||
FC ?= gfortran | ||
ifeq ($(FC), f77) # override possible Make default | ||
FC := ifort |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We could continue to have gfortran
here I would think, but @drnimbusrain can decide.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, lets leave gfortran here. Please revert changes.
src/Makefile
Outdated
ifeq ($(FC),gfortran) | ||
FCFLAGS := -g -Wall -Wextra -Wconversion -Og -pedantic -fcheck=bounds -fmax-errors=5 | ||
else ifeq ($(FC),ifort) | ||
#FCFLAGS := -g -warn all -implicitnone -O1 -stand f90 -error-limit 5 #Equivalent to gfortran Debug flags, builds with warnings on Hera |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we address those warnings as part of this PR?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Agreed, @quaz115 what are the warnings using ifort on Hera with those FCFLAGS?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
These are the warnings (in the next comment):
DEBUG=1 NETCDF=1 FC=ifort make -C src
where, DEBUG = -g -warn all -implicitnone -O1 -stand f90 -error-limit 5
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
DEBUG=1 NETCDF=1 FC=ifort make -C src
FC setting: 'ifort'
DEBUG setting: '1'
NETCDF setting: '1'
LIBS: ' -L/apps/netcdf/4.6.1/intel/16.1.150/lib -lnetcdff -L/apps/netcdf/4.6.1/intel/16.1.150/lib -Wl,-rpath -Wl,/apps/netcdf/4.6.1/intel/16.1.150/lib -lnetcdf -lnetcdf'
INC: ' -I/apps/netcdf/4.6.1/intel/16.1.150/include'
make: Entering directory `/scratch1/BMC/rcm2/qrasool/canopy-app/src'
ifort -g -warn all -implicitnone -O1 -stand f90 -error-limit 5 -DNETCDF -I/apps/netcdf/4.6.1/intel/16.1.150/include -c canopy_const_mod.F90
ifort -g -warn all -implicitnone -O1 -stand f90 -error-limit 5 -DNETCDF -I/apps/netcdf/4.6.1/intel/16.1.150/include -c canopy_coord_mod.F90
ifort -g -warn all -implicitnone -O1 -stand f90 -error-limit 5 -DNETCDF -I/apps/netcdf/4.6.1/intel/16.1.150/include -c canopy_canopts_mod.F90
ifort -g -warn all -implicitnone -O1 -stand f90 -error-limit 5 -DNETCDF -I/apps/netcdf/4.6.1/intel/16.1.150/include -c canopy_canmet_mod.F90
ifort -g -warn all -implicitnone -O1 -stand f90 -error-limit 5 -DNETCDF -I/apps/netcdf/4.6.1/intel/16.1.150/include -c canopy_canvars_mod.F90
ifort -g -warn all -implicitnone -O1 -stand f90 -error-limit 5 -DNETCDF -I/apps/netcdf/4.6.1/intel/16.1.150/include -c canopy_utils_mod.F90
canopy_utils_mod.F90(20): warning #8144: ASSOCIATE construct is not available in Fortran 90.
associate(n => size(x))
--------^
ifort -g -warn all -implicitnone -O1 -stand f90 -error-limit 5 -DNETCDF -I/apps/netcdf/4.6.1/intel/16.1.150/include -c canopy_files_mod.F90
ifort -g -warn all -implicitnone -O1 -stand f90 -error-limit 5 -DNETCDF -I/apps/netcdf/4.6.1/intel/16.1.150/include -c canopy_readnml.F90
canopy_readnml.F90(56): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
CALL EXIT(istat)
-------------^
canopy_readnml.F90(212): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
CALL EXIT(istat)
-------------^
canopy_readnml.F90(219): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
CALL EXIT(istat)
-------------^
ifort -g -warn all -implicitnone -O1 -stand f90 -error-limit 5 -DNETCDF -I/apps/netcdf/4.6.1/intel/16.1.150/include -c canopy_alloc.F90
ifort -g -warn all -implicitnone -O1 -stand f90 -error-limit 5 -DNETCDF -I/apps/netcdf/4.6.1/intel/16.1.150/include -c canopy_init.F90
ifort -g -warn all -implicitnone -O1 -stand f90 -error-limit 5 -DNETCDF -I/apps/netcdf/4.6.1/intel/16.1.150/include -c canopy_txt_io_mod.F90
ifort -g -warn all -implicitnone -O1 -stand f90 -error-limit 5 -DNETCDF -I/apps/netcdf/4.6.1/intel/16.1.150/include -c canopy_ncf_io_mod.F90
canopy_ncf_io_mod.F90(2051): warning #5197: Fortran 90 does not allow array constructors in square brackets
variables%lat=reshape(variables_2d%lat,[size(variables_2d%lat)])
---------------------------------------------------^
canopy_ncf_io_mod.F90(2059): warning #5197: Fortran 90 does not allow array constructors in square brackets
variables%lon=reshape(variables_2d%lon,[size(variables_2d%lon)])
---------------------------------------------------^
canopy_ncf_io_mod.F90(2069): warning #5197: Fortran 90 does not allow array constructors in square brackets
variables%clu=reshape(variables_2d%clu,[size(variables_2d%clu)])
---------------------------------------------------^
canopy_ncf_io_mod.F90(2078): warning #5197: Fortran 90 does not allow array constructors in square brackets
variables%csz=reshape(variables_2d%csz,[size(variables_2d%csz)])
---------------------------------------------------^
canopy_ncf_io_mod.F90(2087): warning #5197: Fortran 90 does not allow array constructors in square brackets
variables%ffrac=reshape(variables_2d%ffrac,[size(variables_2d%ffrac)])
-------------------------------------------------------^
canopy_ncf_io_mod.F90(2096): warning #5197: Fortran 90 does not allow array constructors in square brackets
variables%fh=reshape(variables_2d%fh,[size(variables_2d%fh)])
-------------------------------------------------^
canopy_ncf_io_mod.F90(2105): warning #5197: Fortran 90 does not allow array constructors in square brackets
variables%frp=reshape(variables_2d%frp,[size(variables_2d%frp)])
---------------------------------------------------^
canopy_ncf_io_mod.F90(2114): warning #5197: Fortran 90 does not allow array constructors in square brackets
variables%href=reshape(variables_2d%href,[size(variables_2d%href)])
-----------------------------------------------------^
canopy_ncf_io_mod.F90(2123): warning #5197: Fortran 90 does not allow array constructors in square brackets
variables%lai=reshape(variables_2d%lai,[size(variables_2d%lai)])
---------------------------------------------------^
canopy_ncf_io_mod.F90(2132): warning #5197: Fortran 90 does not allow array constructors in square brackets
variables%mol=reshape(variables_2d%mol,[size(variables_2d%mol)])
---------------------------------------------------^
canopy_ncf_io_mod.F90(2141): warning #5197: Fortran 90 does not allow array constructors in square brackets
variables%fricv=reshape(variables_2d%fricv,[size(variables_2d%fricv)])
-------------------------------------------------------^
canopy_ncf_io_mod.F90(2150): warning #5197: Fortran 90 does not allow array constructors in square brackets
variables%ugrd10m=reshape(variables_2d%ugrd10m,[size(variables_2d%ugrd10m)])
-----------------------------------------------------------^
canopy_ncf_io_mod.F90(2159): warning #5197: Fortran 90 does not allow array constructors in square brackets
variables%vgrd10m=reshape(variables_2d%vgrd10m,[size(variables_2d%vgrd10m)])
-----------------------------------------------------------^
canopy_ncf_io_mod.F90(2168): warning #5197: Fortran 90 does not allow array constructors in square brackets
variables%sfcr=reshape(variables_2d%sfcr,[size(variables_2d%sfcr)])
-----------------------------------------------------^
canopy_ncf_io_mod.F90(2177): warning #5197: Fortran 90 does not allow array constructors in square brackets
variables%vtype=reshape(variables_2d%vtype,[size(variables_2d%vtype)])
-------------------------------------------------------^
canopy_ncf_io_mod.F90(2186): warning #5197: Fortran 90 does not allow array constructors in square brackets
variables%sotyp=reshape(variables_2d%sotyp,[size(variables_2d%sotyp)])
-------------------------------------------------------^
canopy_ncf_io_mod.F90(2195): warning #5197: Fortran 90 does not allow array constructors in square brackets
variables%pressfc=reshape(variables_2d%pressfc,[size(variables_2d%pressfc)])
-----------------------------------------------------------^
canopy_ncf_io_mod.F90(2204): warning #5197: Fortran 90 does not allow array constructors in square brackets
variables%dswrf=reshape(variables_2d%dswrf,[size(variables_2d%dswrf)])
-------------------------------------------------------^
canopy_ncf_io_mod.F90(2213): warning #5197: Fortran 90 does not allow array constructors in square brackets
variables%shtfl=reshape(variables_2d%shtfl,[size(variables_2d%shtfl)])
-------------------------------------------------------^
canopy_ncf_io_mod.F90(2222): warning #5197: Fortran 90 does not allow array constructors in square brackets
variables%tmpsfc=reshape(variables_2d%tmpsfc,[size(variables_2d%tmpsfc)])
---------------------------------------------------------^
canopy_ncf_io_mod.F90(2231): warning #5197: Fortran 90 does not allow array constructors in square brackets
variables%tmp2m=reshape(variables_2d%tmp2m,[size(variables_2d%tmp2m)])
-------------------------------------------------------^
canopy_ncf_io_mod.F90(2240): warning #5197: Fortran 90 does not allow array constructors in square brackets
variables%spfh2m=reshape(variables_2d%spfh2m,[size(variables_2d%spfh2m)])
---------------------------------------------------------^
canopy_ncf_io_mod.F90(2249): warning #5197: Fortran 90 does not allow array constructors in square brackets
variables%hpbl=reshape(variables_2d%hpbl,[size(variables_2d%hpbl)])
-----------------------------------------------------^
canopy_ncf_io_mod.F90(2258): warning #5197: Fortran 90 does not allow array constructors in square brackets
variables%prate_ave=reshape(variables_2d%prate_ave,[size(variables_2d%prate_ave)])
---------------------------------------------------------------^
canopy_ncf_io_mod.F90(943): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
CALL exit (2)
-----------------^
canopy_ncf_io_mod.F90(951): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
CALL exit (2)
-----------------^
canopy_ncf_io_mod.F90(959): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
CALL exit (2)
-----------------^
canopy_ncf_io_mod.F90(982): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
CALL exit (2)
-----------------^
canopy_ncf_io_mod.F90(990): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
CALL exit (2)
-----------------^
canopy_ncf_io_mod.F90(998): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
CALL exit (2)
-----------------^
canopy_ncf_io_mod.F90(1526): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
CALL exit(2)
---------------------^
canopy_ncf_io_mod.F90(1538): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
CALL exit(2)
---------------------^
canopy_ncf_io_mod.F90(1546): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
CALL exit(2)
---------------------^
canopy_ncf_io_mod.F90(1554): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
CALL exit(2)
---------------------^
canopy_ncf_io_mod.F90(1562): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
CALL exit(2)
---------------------^
canopy_ncf_io_mod.F90(1570): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
CALL exit(2)
---------------------^
canopy_ncf_io_mod.F90(1588): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
CALL exit(2)
-------------------------^
canopy_ncf_io_mod.F90(1605): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
CALL exit(2)
-------------------------^
canopy_ncf_io_mod.F90(1622): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
CALL exit(2)
-------------------------^
canopy_ncf_io_mod.F90(1639): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
CALL exit(2)
-------------------------^
canopy_ncf_io_mod.F90(1665): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
CALL exit (2)
-------------------------^
canopy_ncf_io_mod.F90(1671): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
CALL exit (2)
-------------------------^
canopy_ncf_io_mod.F90(1688): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
CALL exit (2)
-------------------------^
canopy_ncf_io_mod.F90(1694): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
CALL exit (2)
-------------------------^
canopy_ncf_io_mod.F90(1711): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
CALL exit (2)
-------------------------^
canopy_ncf_io_mod.F90(1718): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
CALL exit (2)
-------------------------^
canopy_ncf_io_mod.F90(1725): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
CALL exit (2)
-------------------------^
canopy_ncf_io_mod.F90(1742): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
CALL exit (2)
-------------------------^
canopy_ncf_io_mod.F90(1749): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
CALL exit (2)
-------------------------^
canopy_ncf_io_mod.F90(1756): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
CALL exit (2)
-------------------------^
canopy_ncf_io_mod.F90(1768): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
CALL exit (2)
---------------------^
canopy_ncf_io_mod.F90(1850): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
CALL exit (2)
-------------------------^
canopy_ncf_io_mod.F90(1869): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
CALL exit (2)
-------------------------^
canopy_ncf_io_mod.F90(1891): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
CALL exit (2)
-------------------------^
canopy_ncf_io_mod.F90(1913): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
CALL exit (2)
-------------------------^
canopy_ncf_io_mod.F90(1926): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
CALL exit (2)
---------------------^
canopy_ncf_io_mod.F90(2008): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
call exit(2)
-----------------^
canopy_ncf_io_mod.F90(2019): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
CALL exit(2)
-----------------^
canopy_ncf_io_mod.F90(2026): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
CALL exit(2)
-----------------^
canopy_ncf_io_mod.F90(2036): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
CALL exit(2)
-----------------^
canopy_ncf_io_mod.F90(2048): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
CALL exit(2)
---------------------^
canopy_ncf_io_mod.F90(2056): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
CALL exit(2)
---------------------^
canopy_ncf_io_mod.F90(2066): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
CALL exit(2)
---------------------^
canopy_ncf_io_mod.F90(2075): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
CALL exit(2)
---------------------^
canopy_ncf_io_mod.F90(2084): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
CALL exit(2)
---------------------^
canopy_ncf_io_mod.F90(2093): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
CALL exit(2)
---------------------^
canopy_ncf_io_mod.F90(2102): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
CALL exit(2)
---------------------^
canopy_ncf_io_mod.F90(2111): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
CALL exit(2)
---------------------^
canopy_ncf_io_mod.F90(2120): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
CALL exit(2)
---------------------^
canopy_ncf_io_mod.F90(2129): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
CALL exit(2)
---------------------^
canopy_ncf_io_mod.F90(2138): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
CALL exit(2)
---------------------^
canopy_ncf_io_mod.F90(2147): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
CALL exit(2)
---------------------^
canopy_ncf_io_mod.F90(2156): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
CALL exit(2)
---------------------^
canopy_ncf_io_mod.F90(2165): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
CALL exit(2)
---------------------^
canopy_ncf_io_mod.F90(2174): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
CALL exit(2)
---------------------^
canopy_ncf_io_mod.F90(2183): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
CALL exit(2)
---------------------^
canopy_ncf_io_mod.F90(2192): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
CALL exit(2)
---------------------^
canopy_ncf_io_mod.F90(2201): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
CALL exit(2)
---------------------^
canopy_ncf_io_mod.F90(2210): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
CALL exit(2)
---------------------^
canopy_ncf_io_mod.F90(2219): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
CALL exit(2)
---------------------^
canopy_ncf_io_mod.F90(2228): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
CALL exit(2)
---------------------^
canopy_ncf_io_mod.F90(2237): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
CALL exit(2)
---------------------^
canopy_ncf_io_mod.F90(2246): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
CALL exit(2)
---------------------^
canopy_ncf_io_mod.F90(2255): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
CALL exit(2)
---------------------^
canopy_ncf_io_mod.F90(2266): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
CALL exit(2)
---------------------^
canopy_ncf_io_mod.F90(2273): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
CALL exit(2)
---------------------^
canopy_ncf_io_mod.F90(2282): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
CALL exit(2)
---------------------^
canopy_ncf_io_mod.F90(2289): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
CALL exit(2)
---------------------^
canopy_ncf_io_mod.F90(2296): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
CALL exit(2)
---------------------^
canopy_ncf_io_mod.F90(2303): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
CALL exit(2)
---------------------^
canopy_ncf_io_mod.F90(2310): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
CALL exit(2)
---------------------^
canopy_ncf_io_mod.F90(2317): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
CALL exit(2)
---------------------^
canopy_ncf_io_mod.F90(2324): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
CALL exit(2)
---------------------^
canopy_ncf_io_mod.F90(2331): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
CALL exit(2)
---------------------^
canopy_ncf_io_mod.F90(2338): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
CALL exit(2)
---------------------^
canopy_ncf_io_mod.F90(2345): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
CALL exit(2)
---------------------^
canopy_ncf_io_mod.F90(2352): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
CALL exit(2)
---------------------^
canopy_ncf_io_mod.F90(2359): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
CALL exit(2)
---------------------^
canopy_ncf_io_mod.F90(2366): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
CALL exit(2)
---------------------^
canopy_ncf_io_mod.F90(2373): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
CALL exit(2)
---------------------^
canopy_ncf_io_mod.F90(2380): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
CALL exit(2)
---------------------^
canopy_ncf_io_mod.F90(2387): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
CALL exit(2)
---------------------^
canopy_ncf_io_mod.F90(2394): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
CALL exit(2)
---------------------^
canopy_ncf_io_mod.F90(2401): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
CALL exit(2)
---------------------^
canopy_ncf_io_mod.F90(2408): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
CALL exit(2)
---------------------^
canopy_ncf_io_mod.F90(2415): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
CALL exit(2)
---------------------^
canopy_ncf_io_mod.F90(2422): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
CALL exit(2)
---------------------^
canopy_ncf_io_mod.F90(2429): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
CALL exit(2)
---------------------^
canopy_ncf_io_mod.F90(2433): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
call exit(2)
-----------------^
ifort -g -warn all -implicitnone -O1 -stand f90 -error-limit 5 -DNETCDF -I/apps/netcdf/4.6.1/intel/16.1.150/include -c canopy_check_input.F90
canopy_check_input.F90(31): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
call exit(2)
-------------^
ifort -g -warn all -implicitnone -O1 -stand f90 -error-limit 5 -DNETCDF -I/apps/netcdf/4.6.1/intel/16.1.150/include -c canopy_read_txt.F90
ifort -g -warn all -implicitnone -O1 -stand f90 -error-limit 5 -DNETCDF -I/apps/netcdf/4.6.1/intel/16.1.150/include -c canopy_dxcalc_mod.F90
ifort -g -warn all -implicitnone -O1 -stand f90 -error-limit 5 -DNETCDF -I/apps/netcdf/4.6.1/intel/16.1.150/include -c canopy_profile_mod.F90
canopy_profile_mod.F90(67): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
call exit(2)
-------------------------^
canopy_profile_mod.F90(90): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
call exit(2)
-------------------------^
canopy_profile_mod.F90(113): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
call exit(2)
-------------------------^
canopy_profile_mod.F90(136): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
call exit(2)
-------------------------^
canopy_profile_mod.F90(145): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
call exit(2)
-----------------^
canopy_profile_mod.F90(305): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
call exit(2)
---------------------^
canopy_profile_mod.F90(309): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
call exit(2)
-----------------^
ifort -g -warn all -implicitnone -O1 -stand f90 -error-limit 5 -DNETCDF -I/apps/netcdf/4.6.1/intel/16.1.150/include -c canopy_wind_mod.F90
canopy_wind_mod.F90(79): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
call exit(1)
-----------------^
canopy_wind_mod.F90(96): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
call exit(1)
-----------------^
ifort -g -warn all -implicitnone -O1 -stand f90 -error-limit 5 -DNETCDF -I/apps/netcdf/4.6.1/intel/16.1.150/include -c canopy_waf_mod.F90
canopy_waf_mod.F90(68): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
call exit(2)
---------------------^
canopy_waf_mod.F90(78): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
call exit(2)
-------------------------^
canopy_waf_mod.F90(93): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
call exit(2)
-------------------------^
canopy_waf_mod.F90(98): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
call exit(2)
-----------------^
ifort -g -warn all -implicitnone -O1 -stand f90 -error-limit 5 -DNETCDF -I/apps/netcdf/4.6.1/intel/16.1.150/include -c canopy_phot_mod.F90
ifort -g -warn all -implicitnone -O1 -stand f90 -error-limit 5 -DNETCDF -I/apps/netcdf/4.6.1/intel/16.1.150/include -c canopy_eddy_mod.F90
ifort -g -warn all -implicitnone -O1 -stand f90 -error-limit 5 -DNETCDF -I/apps/netcdf/4.6.1/intel/16.1.150/include -c canopy_bioparm_mod.F90
canopy_bioparm_mod.F90(797): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
call exit(2)
-----------------^
ifort -g -warn all -implicitnone -O1 -stand f90 -error-limit 5 -DNETCDF -I/apps/netcdf/4.6.1/intel/16.1.150/include -c canopy_bioemi_mod.F90
ifort -g -warn all -implicitnone -O1 -stand f90 -error-limit 5 -DNETCDF -I/apps/netcdf/4.6.1/intel/16.1.150/include -c canopy_calcs.F90
canopy_calcs.F90(45): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
call exit(2)
-----------------^
canopy_calcs.F90(119): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
call exit(2)
-----------------------------------------^
canopy_calcs.F90(239): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
call exit(2)
-------------------------^
canopy_calcs.F90(260): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
call exit(2)
-----------------^
canopy_calcs.F90(331): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
call exit(2)
-------------------------------------^
canopy_calcs.F90(451): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
call exit(2)
---------------------^
canopy_calcs.F90(458): warning #7416: Fortran 90 does not allow this intrinsic procedure. [EXIT]
call exit(2)
-------------^
ifort -g -warn all -implicitnone -O1 -stand f90 -error-limit 5 -DNETCDF -I/apps/netcdf/4.6.1/intel/16.1.150/include -c canopy_write_txt.F90
ifort -g -warn all -implicitnone -O1 -stand f90 -error-limit 5 -DNETCDF -I/apps/netcdf/4.6.1/intel/16.1.150/include -c canopy_dealloc.F90
ifort -g -warn all -implicitnone -O1 -stand f90 -error-limit 5 -DNETCDF -I/apps/netcdf/4.6.1/intel/16.1.150/include -c canopy_app.F90
ifort -g -warn all -implicitnone -O1 -stand f90 -error-limit 5 -DNETCDF canopy_const_mod.o canopy_coord_mod.o canopy_canopts_mod.o canopy_canmet_mod.o canopy_canvars_mod.o canopy_utils_mod.o canopy_files_mod.o canopy_readnml.o canopy_alloc.o canopy_init.o canopy_txt_io_mod.o canopy_ncf_io_mod.o canopy_check_input.o canopy_read_txt.o canopy_dxcalc_mod.o canopy_profile_mod.o canopy_wind_mod.o canopy_waf_mod.o canopy_phot_mod.o canopy_eddy_mod.o canopy_bioparm_mod.o canopy_bioemi_mod.o canopy_calcs.o canopy_write_txt.o canopy_dealloc.o canopy_app.o -o ../canopy -L/apps/netcdf/4.6.1/intel/16.1.150/lib -lnetcdff -L/apps/netcdf/4.6.1/intel/16.1.150/lib -Wl,-rpath -Wl,/apps/netcdf/4.6.1/intel/16.1.150/lib -lnetcdf -lnetcdf -I/apps/netcdf/4.6.1/intel/16.1.150/include
make: Leaving directory `/scratch1/BMC/rcm2/qrasool/canopy-app/src'
Co-authored-by: Zachary Moon <[email protected]>
src/Makefile
Outdated
|
||
# Compiler | ||
FC ?= gfortran | ||
ifeq ($(FC), f77) # override possible Make default | ||
FC := ifort |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, lets leave gfortran here. Please revert changes.
src/Makefile
Outdated
ifeq ($(FC),gfortran) | ||
FCFLAGS := -g -Wall -Wextra -Wconversion -Og -pedantic -fcheck=bounds -fmax-errors=5 | ||
else ifeq ($(FC),ifort) | ||
#FCFLAGS := -g -warn all -implicitnone -O1 -stand f90 -error-limit 5 #Equivalent to gfortran Debug flags, builds with warnings on Hera |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Agreed, @quaz115 what are the warnings using ifort on Hera with those FCFLAGS?
@quaz115 Thanks for the PR! I do agree with Zach's comments and we should not make most of these changes though, except for the additional ifort debug flags starting at line 27. The Makefile has already been made to accept whatever FC chosen, with default being gfortran if not specified. So, this should be OK. @zmoon Can we revert those changes? However, please lets also address the "builds with warnings on Hera" flags for ifort in this PR, as we should determine what in canopy-app is causing this. Thanks for the testing! |
…ag options work without warning
Quazi,
The FC=ifort can be argument given when compiling. gfortran should be left
as the default, and that command is just an override.
…On Thu, Jun 8, 2023, 10:57 PM quaz115 ***@***.***> wrote:
***@***.**** commented on this pull request.
------------------------------
In src/Makefile
<#75 (comment)>
:
>
# Compiler
FC ?= gfortran
ifeq ($(FC), f77) # override possible Make default
+ FC := ifort
@zmoon <https://github.com/zmoon> @drnimbusrain
<https://github.com/drnimbusrain> , i think we need this change, When i
revert back, FC shows as gfortran and i get build error:
Fatal Error: File 'netcdf.mod' opened at (1) is not a GNU Fortran module
file
make: *** [canopy_ncf_io_mod.o] Error 1
I think we need these changes (or FC to be assigned ifort somewhere)
—
Reply to this email directly, view it on GitHub
<#75 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AGLFYNWE4MLNESZHLHLL53TXKKGKNANCNFSM6AAAAAAY77ZZUM>
.
You are receiving this because you were mentioned.Message ID:
***@***.***>
|
Agreed |
@quaz115 Thanks for checking with the FC=ifort appropriately. Seems like only changes needed then are for your additions to the ifort FC flags. The gfortran equivalent flags are having the warning: Seems like its mainly the ifort f90 standards (-stand f90) having issues with the following in canopy-app:
@zmoon Am I missing anything? We should likely fix these up for ifort. |
@quaz115 Also, can you include the development practices described in the README under This should fix the Lint formatting issues with your PR. Thanks! |
@zmoon if i follow the above steps on my local develop branch fork , would it fix the lint formatting issue on this PR or i need to re-commit the Makefile changes again and create a new PR? |
@quaz115 after you install the pre-commit hooks you can just do |
We need to use a higher standard, e.g. 2003 (for For GFortran, if desired, we can achieve this with For Intel I can't find how to do that so we can just not use |
we should probably think in a future PR to move to CMake. This will likely be a requirement for integration into CATChem later on. |
Thanks Barry, yes that is already an issue to move to CMake.
…On Fri, Jun 9, 2023, 11:53 AM Barry Baker ***@***.***> wrote:
we should probably think in a future PR to move to CMake. This will likely
be a requirement for integration into CATChem later on.
—
Reply to this email directly, view it on GitHub
<#75 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AGLFYNR7JXZP3JGL527YKH3XKNBGVANCNFSM6AAAAAAY77ZZUM>
.
You are receiving this because you were mentioned.Message ID:
***@***.***>
|
@quaz115 Do you mind making Zach's suggestions and test compiling the DEBUG mode flags for both gfortran and ifort compilers and make the commits here? We just need to have one for each and make sure no warnings are thrown. We need to use a higher standard, e.g. 2003 (for associate), but enable the compiler extensions in order to use the exit subroutine (which is not part of the Fortran standard, but is included in both GNU and Intel's extensions). For GFortran we can achieve this with -std=f2003 -fall-intrinsics. For Intel I can't find how to do that so we can just not use -stand. (Maybe you can figure out how to do it for Intel) |
FWIW, seems like they don't use |
We can include Footnotes
|
OK Zach, lets just remove -stand from the ifort DEBUG flags, and test your suggestion for gfortran: -std=f2003 -fall-intrinsics @quaz115 Can you test these in your branch and commit if both ifort and gfortran compile OK with no warnings. |
@zmoon i am getting following issue when i try to install the pre-commit hooks: pre-commit --version |
@zmoon Should NETCDF_FLIBS and NETCDF_INC also be edited to NC_FLIBS and NC_INC? and what about: FCFLAGS += -DNETCDF |
No, I don't think so.
…On Fri, Jun 9, 2023, 3:57 PM quaz115 ***@***.***> wrote:
Thanks Zach, should have done a module purge. Great! Seems just the NETCDF
to NC change is needed and the ifort CI check for this right?
… <#m_-1963340890694455230_>
On Fri, Jun 9, 2023, 2:58 PM Zachary Moon *@*.*> wrote: getting H5 errors
with gfortran testing @drnimbusrain <https://github.com/drnimbusrain>
https://github.com/drnimbusrain <https://github.com/drnimbusrain> I think
you have other modules loaded. With just Currently Loaded Modules: 1)
gnu/9.2.0 2) netcdf/4.7.2 I don't get any errors/warnings. — Reply to this
email directly, view it on GitHub <#75 (comment)
<#75 (comment)>>,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/AGLFYNQ6CKYTKABUL2WCTA3XKNW65ANCNFSM6AAAAAAY77ZZUM
<https://github.com/notifications/unsubscribe-auth/AGLFYNQ6CKYTKABUL2WCTA3XKNW65ANCNFSM6AAAAAAY77ZZUM>
. You are receiving this because you were mentioned.Message ID: @.*>
Should NETCDF_FLIBS and NETCDF_INC also be edited to NC_FLIBS and NC_INC?
—
Reply to this email directly, view it on GitHub
<#75 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AGLFYNQH6QMDGHAHSW35XETXKN5ZVANCNFSM6AAAAAAY77ZZUM>
.
You are receiving this because you were mentioned.Message ID:
***@***.***>
|
ok, just added the latest commit (tested already)
On Fri, Jun 9, 2023 at 1:19 PM Patrick Campbell ***@***.***>
wrote:
… No, I don't think so.
On Fri, Jun 9, 2023, 3:57 PM quaz115 ***@***.***> wrote:
> Thanks Zach, should have done a module purge. Great! Seems just the
NETCDF
> to NC change is needed and the ifort CI check for this right?
> … <#m_-1963340890694455230_>
> On Fri, Jun 9, 2023, 2:58 PM Zachary Moon *@*.*> wrote: getting H5
errors
> with gfortran testing @drnimbusrain <https://github.com/drnimbusrain>
> https://github.com/drnimbusrain <https://github.com/drnimbusrain> I
think
> you have other modules loaded. With just Currently Loaded Modules: 1)
> gnu/9.2.0 2) netcdf/4.7.2 I don't get any errors/warnings. — Reply to
this
> email directly, view it on GitHub <#75 (comment)
> <
#75 (comment)>>,
> or unsubscribe
>
https://github.com/notifications/unsubscribe-auth/AGLFYNQ6CKYTKABUL2WCTA3XKNW65ANCNFSM6AAAAAAY77ZZUM
> <
https://github.com/notifications/unsubscribe-auth/AGLFYNQ6CKYTKABUL2WCTA3XKNW65ANCNFSM6AAAAAAY77ZZUM>
> . You are receiving this because you were mentioned.Message ID: @.*>
>
> Should NETCDF_FLIBS and NETCDF_INC also be edited to NC_FLIBS and
NC_INC?
>
> —
> Reply to this email directly, view it on GitHub
> <
#75 (comment)>,
> or unsubscribe
> <
https://github.com/notifications/unsubscribe-auth/AGLFYNQH6QMDGHAHSW35XETXKN5ZVANCNFSM6AAAAAAY77ZZUM>
> .
> You are receiving this because you were mentioned.Message ID:
> ***@***.***>
>
—
Reply to this email directly, view it on GitHub
<#75 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/APFNFOKBLXGT3SS4ZUNLMW3XKOAMHANCNFSM6AAAAAAY77ZZUM>
.
You are receiving this because you were mentioned.Message ID:
***@***.***>
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Also need to update readme (Getting Started / Build).
Co-authored-by: Zachary Moon <[email protected]>
Co-authored-by: Zachary Moon <[email protected]>
Thanks Quazi and Zach, both options working well for me now too. Just updates to README for the build ifort option and change to 'NC' setting and maybe the CI ifort check if Zach has time. Maybe something like this Quazi?
|
Just suggesting minor addition for more clarity i think:
|
We may want to note that not supplying |
Good idea Zach. Go ahead and make the README changes Quazi. Thanks!
…On Sat, Jun 10, 2023, 9:50 AM Zachary Moon ***@***.***> wrote:
a) with gfortran, Debug flags ON and with Netcdf:
DEBUG=1 NC=1 make -C src
We may want to note that not supplying FC in your line doesn't necessary
give gfortran, since FC might already be set in the environment (seems
some module load situations do this).
—
Reply to this email directly, view it on GitHub
<#75 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AGLFYNUSEWDN4YIIUF24US3XKR3T3ANCNFSM6AAAAAAY77ZZUM>
.
You are receiving this because you were mentioned.Message ID:
***@***.***>
|
Incorporated in README.md changes |
Done! |
…Makefile to build Canopy-app with both ifort and gfortran
@zmoon are we ready to merge? |
@zmoon Did you want to add the CI changes, or merge now? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@drnimbusrain I will add to the CI in separate PR, since I will probably have to experiment a bit. Also I may add more debug flags.
Co-authored-by: Zachary Moon <[email protected]>
Co-authored-by: Zachary Moon <[email protected]>
Co-authored-by: Zachary Moon <[email protected]>
Co-authored-by: Zachary Moon <[email protected]>
OK, thank you Quazi and Zach for these updates! |
#FCFLAGS := -g -warn all -implicitnone -O1 -stand f90 -error-limit 5 #Equivalent to gfortran Debug flags, builds with warnings on Hera
FCFLAGS := -g -warn all -check bounds -traceback #builds without warnings on Hera
-stand flag works for different Fortran version (say for Fortran 2008, f90 can be replaced by f08)
Optimization flag can also be changed accordingly (-O1, -O2 etc.)