Portland Group Fortran Compiler compiles the XBC
option tree and other X-Midas
host primitives written in Fortran (see X-Midas Backwards
Compatibility (XBC) for details on X-Midas host primitives in NeXtMidas).
Some PGI Fortran Compiler installations are not setup properly causing errors when building XBC. For example:
nM> make all xbc ... INFO: Compiling /opt/midas/nxm282/nxm/host/newrate.for [BUILDOPT] /usr/bin/ld: /crtbeginS.o: No such file: No such file or directory ...The issue here is that the PGI compiler setup file at <PGI_INSTALL_DIR>/bin/localrc (e.g. /usr/pgi/linux86/5.2/bin/localrc) does not point at the gcc installation. The key info here is that the linker was not finding one of the "C" run-time object file (as it was trying to look for it in the root directory)
/usr/pgi/linux86/5.2/bin/makelocalrc -x `pwd`
<PGI_INSTALL_DIR>/bin/localrc
setup file as follows
(e.g. on a RHEL4 system):
set LFC=-lg2c; set LDSO=/lib/ld-linux.so.2; set GCCDIR=/usr/lib/gcc/i386-redhat-linux/3.4.6/; set GCCINC=/usr/lib/gcc/i386-redhat-linux/3.4.6/include; set G77DIR=/usr/lib/gcc/i386-redhat-linux/3.4.6/; set LOCALRC=YES; set THROW=__THROW=;