[ncl-install] Library problem - a script in NCL
Negin Moghaddam
negin.f.moghaddam at gmail.com
Wed Jul 22 00:39:47 MDT 2015
Hi Orion,
After fixing the library for NCAR, I ran the following scritp after putting
the plot_points.ans, *.csh, *.dat, and *.f in the working folder.
[neginm at civ-1215x Subsurface-Modelling-Monash]$ ncargf77 -o plot_points.x
plot_points.f
/usr/bin/gfortran -fPIC -fno-second-underscore -fno-range-check -fopenmp -O
-o plot_points.x plot_points.f -L/usr/local/ncl-6.3.0/lib -L/usr/lib64
-lncarg -lncarg_gks -lncarg_c -lX11 -lXext -lcairo -lfontconfig -lpixman-1
-lfreetype -lexpat -lpng -lz -lpthread -lXrender -lbz2
[neginm at civ-1215x Subsurface-Modelling-Monash]$ ls
plot_points.ans
plot_points.csh
plot_points.csh~
plot_points.dat
plot_points.f
plot_points.x
Then I tried:
[neginm at civ-1215x Subsurface-Modelling-Monash]$ chmod 755 plot_points.csh
[neginm at civ-1215x Subsurface-Modelling-Monash]$ ls
plot_points.csh
plot_points.csh~
plot_points.dat
plot_points.f
plot_points.x
However, when I run the code as :
[neginm at civ-1215x Subsurface-Modelling-Monash]$ plot_points.csh
bash: plot_points.csh: command not found
Or with
[neginm at civ-1215x Subsurface-Modelling-Monash]$ ./plot_points.csh
./plot_points.csh: line 1: plot_points.x: command not found
ctrans: Can't open metafile(plot_points.cgm) [ No such file or directory ]
GPL Ghostscript 8.70 (2009-07-31)
Copyright (C) 2009 Artifex Software, Inc. All rights reserved.
This software comes with NO WARRANTY: see the file PUBLIC for details.
The pdf and ps files came out with no content.
I checked the web and it said, the outcome of running ncargf77 should
include *.cgm which I noticed in second line of your script is one of the
inputs.
I used the test example for NCAR as :
[neginm at civ-1215x ~]$ ncargex cpex08 -clean
NCAR Graphics Fortran Example <cpex08>
Copying cpex08.f
Copying cpexcc.f
Compiling and linking...
/usr/bin/gfortran -fPIC -fno-second-underscore -fno-range-check -fopenmp -O
-o cpex08 cpexcc.f cpex08.f -L/usr/local/ncl-6.3.0/lib -L/usr/lib64 -lncarg
-lncarg_gks -lncarg_c -lX11 -lXext -lcairo -lfontconfig -lpixman-1
-lfreetype -lexpat -lpng -lz -lpthread -lXrender -lbz2
Executing <cpex08>...
PLOT TITLE WAS EXAMPLE 8
INTEGER WORKSPACE USED 120
REAL WORKSPACE USED 400
AREA MAP SPACE USED 93250
PLOT TITLE WAS EXAMPLE 8
INTEGER WORKSPACE USED 120
REAL WORKSPACE USED 400
AREA MAP SPACE USED 866064
Metafile file is named cpex08.ncgm. The ncgm meta data file was built, but
nothing as a picture or graph came out.
Could you please let me know why ncgm file did not built for my script and
how I can fix it?
Thank you
On Fri, Jul 17, 2015 at 12:26 PM, Orion Poplawski <orion at cora.nwra.com>
wrote:
> On 07/16/2015 07:19 PM, Negin Moghaddam wrote:
>
>> Hello Orion,
>>
>> I installed all the following missing libraries but I got another error
>> which I think relates to cairo.
>>
>> Could you please help me to solve this issue. Thank you.
>>
>> libraries installed:
>>
>> libX11-devel
>> libX11
>> libXt
>> libXext-devel
>> cairo-devel
>> libpng
>> expat-devel
>> bzip2-devel
>>
>> The error is:
>>
>> [neginm at civ-1215x ~]$ ncargex cpex08 -clean
>>
>> NCAR Graphics Fortran Example <cpex08>
>>
>> Copying cpex08.f
>>
>> Copying cpexcc.f
>>
>> Compiling and linking...
>> /usr/bin/gfortran -fPIC -fno-second-underscore -fno-range-check -fopenmp
>> -O -o cpex08 cpexcc.f cpex08.f -L/usr/local/ncl-6.3.0/lib
>> -L/usr/X11R6/lib64 -lncarg -lncarg_gks -lncarg_c -lX11 -lXext -lcairo
>> -lfontconfig -lpixman-1 -lfreetype -lexpat -lpng -lz -lpthread -lXrender
>> -lbz2
>> /usr/local/ncl-6.3.0/lib/libncarg_gks.a(cro.o): In function
>> `cro_OpenWorkstation':
>> cro.c:(.text+0x3efd): undefined reference to
>> `cairo_recording_surface_create'
>> /usr/local/ncl-6.3.0/lib/libncarg_gks.a(cro.o): In function
>> `cro_ClearWorkstation':
>> cro.c:(.text+0x4be5): undefined reference to
>> `cairo_recording_surface_create'
>> collect2: ld returned 1 exit status
>>
>> The compile and link failed.
>>
>
>
> Looks like other's have run into this. See:
>
> http://mailman.ucar.edu/pipermail/ncl-install/2015-March/001747.html
>
> --
> Orion Poplawski
> Technical Manager 303-415-9701 x222
> NWRA/CoRA Division FAX: 303-415-9702
> 3380 Mitchell Lane orion at cora.nwra.com
> Boulder, CO 80301 http://www.cora.nwra.com
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mailman.ucar.edu/pipermail/ncl-install/attachments/20150722/3e17fe78/attachment.html
More information about the ncl-install
mailing list