[Wrf-users] NCL and WRF in Linux-RedHat with ifort

Jonathan Vigh vigh at atmos.colostate.edu
Tue Feb 8 11:04:27 MST 2005


Hi Hector,
	I remember having problems compiling this when I did it a couple months
ago, but it worked with a few minor tweaks, so I made some notes for
future reference (below). These are for a Intel x586 PC running Fedora
Core 2 with Ifort 8.1. My modified make script is attached.  

	Good luck!

Jonathan


NOTES on the making of the NCL-Fortran shared object:
====================================================
I took the "make_ncl_fortran.linux" script and modified it for the Intel
compilers, renaming it "make_ncl_fortran.linux_ifort.csh". I set the
paths according to what they are on my machine. I also had to set the
shell script designator at the top to specifically be c-shell since I'm
running bash (set #!/bin/csh).

Then I ran:
$>  make_ncl_fortran.linux_ifort.csh wrf_user_fortran_util_0  

which produced the following:

vigh at euler WRF_NCL]$ make_ncl_fortran.linux_ifort.csh
wrf_user_fortran_util_0
if ( 1 == 0 ) then
echo  build for REDHAT linux and Intel compilers
 build for REDHAT linux and Intel compilers
echo  construct C wrapper for fortran code...
 construct C wrapper for fortran code...
wrapit77 -in
if ( 0 == 0 ) then
echo  wrapper generated
 wrapper generated
else
echo  compile C wrapper...
 compile C wrapper...
nhlcc -c wrf_user_fortran_util_0_W.c
gcc -DSYSV -D_POSIX_SOURCE -D_XOPEN_SOURCE -DByteSwapped -DNeedFuncProto
-ansi -O -c wrf_user_fortran_util_0_W.c -L/usr/remote/ncarg/lib
-L/usr/X11R6/lib -I/usr/remote/ncarg/include -I/usr/X11R6/include -lhlu
-lncarg -lncarg_gks -lncarg_c -lX11 -lXext -lg2c -lgcc -lm
gcc: -lhlu: linker input file unused because linking not done
gcc: -lncarg: linker input file unused because linking not done
gcc: -lncarg_gks: linker input file unused because linking not done
gcc: -lncarg_c: linker input file unused because linking not done
gcc: -lX11: linker input file unused because linking not done
gcc: -lXext: linker input file unused because linking not done
gcc: -lg2c: linker input file unused because linking not done
gcc: -lgcc: linker input file unused because linking not done
gcc: -lm: linker input file unused because linking not done
if ( 0 == 0 ) then
echo  C wrapper compiled
 C wrapper compiled
else
echo  compile fortran routine...
 compile fortran routine...
ifort -g -c wrf_user_fortran_util_0.f -L/usr/remote/ncarg/lib
-L/usr/X11R6/lib -L/usr/local/lib -I/usr/remote/ncarg/include
-I/usr/X11R6/include -lhlu -lncarg -lncarg_gks -lncarg_c -lX11
-Wl,-Bstatic -L/usr/lib/gcc-lib/i386-redhat-linux/3.3.3 -lg2c
-Wl,-Bdynamic -lm
if ( 0 == 0 ) then
echo  fortran routine compiled
 fortran routine compiled
else
echo  create shared library...
 create shared library...
ifort -shared -o wrf_user_fortran_util_0.so wrf_user_fortran_util_0.o
wrf_user_fortran_util_0_W.o
if ( 0 == 0 ) then
echo  shared library created
 shared library created
echo  library is  wrf_user_fortran_util_0.so
 library is  wrf_user_fortran_util_0.so
exit 0





On Tue, 2005-02-08 at 08:45, Hector Sepulveda wrote:
>   Hello,
> 
>     I am trying to compile the fortran shareable object for the NCL routines
> used in WRF (wrf_ncl.tar.gz package). There is a
> 
> make_ncl_fortran.linux
> 
> script, but is based on the pgf77 compiler. Has anyone compiled this in
> a Linux machine with ifort (RH V3)?
> 
>  Thank you,
> 
>       Hector
-- 
---------------------------------------------------------------------
Jonathan Vigh, Ph.D. Candidate              work phone: 970.491.8633                         
Department of Atmospheric Science           vigh at atmos.colostate.edu
Colorado State University    http://euler.atmos.colostate.edu/~vigh/
---------------------------------------------------------------------
~
-------------- next part --------------
A non-text attachment was scrubbed...
Name: make_ncl_fortran.linux_ifort.csh
Type: application/x-shellscript
Size: 1536 bytes
Desc: not available
Url : http://mailman.ucar.edu/pipermail/wrf-users/attachments/20050208/e0e9e2c0/make_ncl_fortran.linux_ifort.bin


More information about the Wrf-users mailing list