compile errors related to gcc libraries

Hi,
  I am trying to compile one of the larger programs of mine that uses hdf5 (I say larger because, I was able to compile several of the example programs successfully).

The linking to the hdf libraries on my system looks like this:

HDF_LIB = /usr/opt/hdf/5-1.6.5/intel-9.0/lib/libhdf5_fortran.a\
                  /usr/opt/hdf/5-1.6.5/intel-9.0/lib/libhdf5.a\
                  /usr/lib/libm.a\
                  /usr/lib/libz.a

On compiling the program I get an error as follows:

/usr/opt/hdf/5-1.6.5/intel-9.0/lib/libhdf5_fortran.a(H5Pf.o): In function `h5pset_fapl_multi_c_':
H5Pf.c:(.text+0x199d): undefined reference to `__fixunssfdi'

After going through some of the FAQs on the hdf support page, I figured that could be due to the linking of gcc library being absent. So I added that and now my linking looks like this

HDF_LIB = /usr/opt/hdf/5-1.6.5/intel-9.0/lib/libhdf5_fortran.a\

                  /usr/opt/hdf/5-1.6.5/intel-9.0/lib/libhdf5.a\

                  /usr/lib/libm.a\

                  /usr/lib/libz.a

                  /usr/lib/gcc/i686-pc-linux-gnu/3.4.6/libgcc.a

But now I get different errors related to multiple function definition that looks like this

/usr/opt/intel/fc/9.0/lib/libirc_s.a(udiv64_gcc.o): In function `__udivdi3':
div64_gcc.s:(.text+0x50): multiple definition of `__udivdi3'
/usr/lib/gcc/i686-pc-linux-gnu/3.4.6/libgcc.a(_udivdi3.oS):: first defined here
ld: Warning: size of symbol `__udivdi3' changed from 288 in /usr/lib/gcc/i686-pc-linux-gnu/3.4.6/libgcc.a(_udivdi3.oS) to 272 in /usr/opt/intel/fc/9.0/lib/libirc_s.a(udiv64_gcc.o)
/usr/opt/intel/fc/9.0/lib/libirc_s.a(urem64_gcc.o): In function `__umoddi3':
urem64_gcc.s:(.text+0x50): multiple definition of `__umoddi3'
/usr/lib/gcc/i686-pc-linux-gnu/3.4.6/libgcc.a(_umoddi3.oS):: first defined here

Does anyone have any idea. I searched all around google for errors like this, but cudnt find any.

Thanks in advance for your help.

Abhilash Chandy.

···

____________________________________________________________________________________
Looking for last minute shopping deals?
Find them fast with Yahoo! Search. http://tools.search.yahoo.com/newsearch/category.php?category=shopping

----------------------------------------------------------------------
This mailing list is for HDF software users discussion.
To subscribe to this list, send a message to hdf-forum-subscribe@hdfgroup.org.
To unsubscribe, send a message to hdf-forum-unsubscribe@hdfgroup.org.

Abhilash,

Error sounds very familiar. Please try to link with gcc_s library instead of gcc. See comment under http://www.hdfgroup.org/hdf5-quest.html#install-build
"How to build using gcc and Intel or Lahey Fortran?"

Upgrade to Intel 9.1 will also resolve the problem.

And I didn't forget about compression problem. I will take a look at it as soon as I can.

Elena

···

At 12:50 PM -0800 1/29/08, abhilash chandy wrote:

Hi,
  I am trying to compile one of the larger programs of mine that uses hdf5 (I say larger because, I was able to compile several of the example programs successfully).

The linking to the hdf libraries on my system looks like this:

HDF_LIB = /usr/opt/hdf/5-1.6.5/intel-9.0/lib/libhdf5_fortran.a\
                  /usr/opt/hdf/5-1.6.5/intel-9.0/lib/libhdf5.a\
                  /usr/lib/libm.a\
                  /usr/lib/libz.a

On compiling the program I get an error as follows:

/usr/opt/hdf/5-1.6.5/intel-9.0/lib/libhdf5_fortran.a(H5Pf.o): In function `h5pset_fapl_multi_c_':
H5Pf.c:(.text+0x199d): undefined reference to `__fixunssfdi'

After going through some of the FAQs on the hdf support page, I figured that could be due to the linking of gcc library being absent. So I added that and now my linking looks like this

HDF_LIB = /usr/opt/hdf/5-1.6.5/intel-9.0/lib/libhdf5_fortran.a\

                  /usr/opt/hdf/5-1.6.5/intel-9.0/lib/libhdf5.a\

                  /usr/lib/libm.a\

                  /usr/lib/libz.a

                  /usr/lib/gcc/i686-pc-linux-gnu/3.4.6/libgcc.a

But now I get different errors related to multiple function definition that looks like this

/usr/opt/intel/fc/9.0/lib/libirc_s.a(udiv64_gcc.o): In function `__udivdi3':
div64_gcc.s:(.text+0x50): multiple definition of `__udivdi3'
/usr/lib/gcc/i686-pc-linux-gnu/3.4.6/libgcc.a(_udivdi3.oS):: first defined here
ld: Warning: size of symbol `__udivdi3' changed from 288 in /usr/lib/gcc/i686-pc-linux-gnu/3.4.6/libgcc.a(_udivdi3.oS) to 272 in /usr/opt/intel/fc/9.0/lib/libirc_s.a(udiv64_gcc.o)
/usr/opt/intel/fc/9.0/lib/libirc_s.a(urem64_gcc.o): In function `__umoddi3':
urem64_gcc.s:(.text+0x50): multiple definition of `__umoddi3'
/usr/lib/gcc/i686-pc-linux-gnu/3.4.6/libgcc.a(_umoddi3.oS):: first defined here

Does anyone have any idea. I searched all around google for errors like this, but cudnt find any.

Thanks in advance for your help.

Abhilash Chandy.

____________________________________________________________________________________
Looking for last minute shopping deals? Find them fast with Yahoo! Search. http://tools.search.yahoo.com/newsearch/category.php?category=shopping

----------------------------------------------------------------------
This mailing list is for HDF software users discussion.
To subscribe to this list, send a message to hdf-forum-subscribe@hdfgroup.org.
To unsubscribe, send a message to hdf-forum-unsubscribe@hdfgroup.org.

--

------------------------------------------------------------
Elena Pourmal
The HDF Group
1901 So First ST.
Suite C-2
Champaign, IL 61820

epourmal@hdfgroup.org
(217)333-0238 (office)
(217)333-9049 (fax)
------------------------------------------------------------