Hello,
> Pl help in resolving the following error in compiling NCARG 4.4.0 on package
> on Linux RedHat 9. Why such error is coming? I am attaching bash file as well
> as Makefile. Following is the clip of make-output compilation log.
> gcc -ansi -O -o ictrans main.o
> ../../../.././ncarview/src/lib/libictrans/libictrans.o
> ../../../.././ncarview/src/lib/libctrans/libctrans.o
> -L../../../.././ncarview/src/lib/libcgm -lcgm
> -L../../../.././ncarview/src/lib/libncarg_ras -lncarg_ras
> -L../../../.././common/src/libncarg_c -lncarg_c -L/usr/local/ncarg/lib
> -L/usr/X11R6/lib -lX11 -lXext -lg2c -lgcc -lm
> ../../../.././ncarview/src/lib/libictrans/libictrans.o(.init+0x6): undefined
> reference to `__pgio_ini'
> ../../../.././ncarview/src/lib/libictrans/libictrans.o(.text+0x519f): In
> function `giargs_':: undefined reference to `ftn_str_copy'
> ../../../.././ncarview/src/lib/libictrans/libictrans.o(.data+0x150c): In
> function `.C2_304':: undefined reference to `pgf90_compiled'
> collect2: ld returned 1 exit status
> make[5]: *** [ictrans] Error 1
It appears that you're using the Portland Group (PGI) f90 compiler, pgf90,
to compile the Fortran source code present in NCAR Graphics.
In order to build tools such as 'ictrans,' you need to link in both PGI
C and f90 libraries. There are a number to include, noted below.
The 'technically correct' way to do make this happen throughout the NCAR
Graphics build process is to:
1. Modify your $NCARG/config/LINUX file to include the following:
#define FCompiler pgf90
#define CtoFLibraries -lpgc -lpgf90 -lpgf90_rpm1 -lpgf902 -lpgftnrtl
2. Re-run 'Configure' and specify the full path to the location of your
PGI libraries when asked to enter 'local library search path(s).'
3. Rebuild NCAR Graphics.
This should help 'gcc' resolve the undefined references at link time.
Ideally, it would be best to use the PGI C compiler (pgcc) but the mix of
the GNU C compiler and PGI f90 compiler has worked.
-Rick.
-- Rick Grubin NCAR/CISL/SCD Visualization + Enabling Technologies grubin@ucar.edu 303.497.1832 _______________________________________________ ncarg-talk mailing list ncarg-talk@ucar.edu http://mailman.ucar.edu/mailman/listinfo/ncarg-talk
This archive was generated by hypermail 2b29 : Wed Mar 02 2005 - 09:37:11 MST