[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

19990920: Building UNIDATA McIDAS-X 7.60 on RedHat 6.0 Linux



>From: Rene Lobato <rlobato@200.13.36.34>
>Organization: Instituto Mexicano de Tecnologia del Agua
>Keywords: 199909202133.PAA25556 McIDAS-X 7.60 RedHat Linux 6.0

Rene,

>There is a problem that we do not know how to handle it. At the time when
>we are using the command:
>
>                               make all
>
>We have a series of errors that we think that something else is missing.
>The platform in which we are installing MCIDAS in a LINUX (Red Hat 6.0). I
>am sending as an attachement the output of the compiling and linking as
>"makelog.tar.gz"
>
>We have looked at the FAQ but have not found anything related.
>
>Thanks for your help !!!

There are at least two possibilities for the build failure you are seeing.

1) I did not support RedHat 6.0 Linux before the bugfix addendum I
   made on September 14.  Looking back through the FTP logs on our FTP
   server seems to indicate that you grabbed the 7.60 distribution on
   or before September 10.  You will need to FTP and install the addenda
   that is located in:

machine: ftp.unidata.ucar.edu
directory: unix/760/bugfix
file: mcupdate.tar.Z

The process is:

cd ~mcidas/mcidas7.6/update
ftp ftp.unidata.ucar.edu
  <user>
  <pass>
  cd unix/760/bugfix
  binary
  get mcupdate.tar.Z
  quit
./mcunpack

After you address the second issue below, you should be able to build
7.60 successfully.

2) Output from the 'makelog' file that you included as an attachment
   indicates that you missed the Notes and Warnings section of
   the McIDAS-X online documentation:

   Notes and Warnings
   http://www.unidata.ucar.edu/packages/mcidas/mcx/warnings_mcx.html

   In this page, I warn gcc/f2c users that they will need to take
   special care to link against the static f2c library (libf2c.a)
   instead of the dynamic one.  The Notes and Warnings section reads:

gcc/f2c Users

For all Supported Platforms, McIDAS-X 7.60 is configured to be able to use
a combination of the GNU gcc and AT&T f2c utilities. In previous releases,
one also needed the Perl script fort77, but that has been replaced by the
Bourne shell script mcfc that is bundled with McIDAS-X.

To use gcc/f2c, one must: 

     use a version of gcc greater than or equal to 2.7.3 
     use a version of f2c released on or after August 1997 
     use the static f2c library, libf2c.a, when linking

     You need to link against the static f2c library, libf2c.a, since the
     shared version does not contain the needed entry point MAIN__.

     after your distribution is unpacked edit mcidas7.6/src/makefile and:

         change:
         VENDOR= -vendor

         to:
         VENDOR= 

One way to insure use of libf2c.a is illustrated in the following: 

As root: 

     Type: ln -s /usr/lib/libf2c.a /usr/local/lib/libf2c.a

As mcidas: 

Define the environment variable LD_LIBRARY_PATH so that the /user/local/lib
directory is searched before others when programs are linked. For C-shell
users, LD_LIBRARY_PATH would be set in .cshrc: 

     Type: cd /home/mcidas

     Edit .chsrc and add:

     setenv LD_LIBRARY_PATH /usr/local/lib:/lib:/usr/lib

After modifying .cshrc, make sure to make the changes active in your session: 

     Type: source .cshrc


  The link output from your copy of 'makelog' indicates that you are
  running into the exact situation noted above: the missing MAIN__
  entry point:

./mccomp -O -vendor -I. -I../netcdf/libsrc -c convdlmc.c
gcc -c -O -ansi -D_GNU_SOURCE -I/usr/X11R6/include -O -I. -I../netcdf/libsrc con
vdlmc.c
compile convdlmc.c:             done
./mccomp -O -vendor -I. -I../netcdf/libsrc -c convdlmf.f
mcfc -c -O convdlmf.f
convdlmf.f:
   convdlm:
   nchars:
   len_trim:
compile convdlmf.f:             done
./mccomp -O -s -vendor -o convdlm convdlmc.o convdlmf.o
mcfc -s -O -o convdlm convdlmc.o convdlmf.o -L/usr/local/lib -L/usr/X11R6/lib -l
f2c -ldl -lm
/usr/lib/libf2c.so: undefined reference to `MAIN__'
collect2: ld returned 1 exit status


After you grab and install the bugfix addendum and make a link of libf2c.a
into /usr/local/lib (actually, any directory that will be included at
the beginning of LD_LIBRARY_PATH and does not contain the shared f2c
library, libf2c.so), you should be able to build the distribution successfully:

cd ~mcidas/mcidas7.6/src
make clobber
make all

Please let me know if you have any problems after doing the above.

Tom Yoksas