Intel® Fortran Compiler
Build applications that can scale for the future with optimized code designed for Intel® Xeon® and compatible processors.

HDF5 Installation Error in the latest Ubuntu 18.04LTS

Simchan_Y_
Beginner
2,804 Views
Hi everyone,
 
While I used HDF5 library without any problem with Ubuntu version 16.04 LTS,
 
After I upgraded Ubuntu to Ubuntu 18.04 LTS, I have trouble in installing HDF5 with Intel Fortran and C Compilers.
I successfully installed HDF5 with gcc and gfortran.
But, I need to install HDF5 with Intel Fortran and C Compilers to further usage of scientific computation codes which are only compatible with Intel compilers.
 
I installed szip-2.1.1 and zlib-1.2.11 in the path of $HOME/LIB
using
ifort version 18.0.2
icc version 18.0.2 (gcc version 7.0.0 compatibility)
icpc version 18.0.2 (gcc version 7.0.0 compatibility)
(parallel_studio_xe_2018_update2_cluster_edition, compilers_and_libraries_2018.2.199)
 
with next flags in bash profile
export CC=icc
export CXX=icpc
export FC=ifort
export F9X=ifort
export CFLAGS='-O3 -xHost -ip'
export CXXFLAGS='-O3 -xHost -ip'
export FCFLAGS='-O3 -xHost -ip'
 
and tried to install
hdf5-1.10.2
with following configuration

./configure --prefix=$HOME/LIB --with-zlib=$HOME/LIB --with-szip=$HOME/LIB LD_LIBRARY_PATH=-L/home/scyook/LIB/lib CPPFLAGS=-I/home/scyook/LIB/include --enable-fortran --enable-cxx --enable-fortran2003

However next error message appears.
checking size of size_t... configure: error: in `/home/scyook/LIB/hdf5-1.10.2':
configure: error: cannot compute sizeof (size_t)
 
these are the last parts of config.log

#define SIZEOF_INT32_T 0
#define SIZEOF_UINT32_T 0
#define SIZEOF_INT_LEAST32_T 0
#define SIZEOF_UINT_LEAST32_T 0
#define SIZEOF_INT_FAST32_T 0
#define SIZEOF_UINT_FAST32_T 0
#define SIZEOF_INT64_T 0
#define SIZEOF_UINT64_T 0
#define SIZEOF_INT_LEAST64_T 0
#define SIZEOF_UINT_LEAST64_T 0
#define SIZEOF_INT_FAST64_T 0
#define SIZEOF_UINT_FAST64_T 0

configure: exit 77

 

 
Could I get help for resolving this issue?
 
Thanks,
Shim
0 Kudos
7 Replies
Michael_S_17
New Contributor I
2,804 Views

Hi,
I can't help with your specific issue. But just in case: In the past I'd problems too after upgrading Ubuntu to a newer release. (From 14.04 to 16.04 for example). Since then I prefer to install a new Ubuntu release from scratch, and not to just upgrade an older Ubuntu release.
Best Regards
 

0 Kudos
Simchan_Y_
Beginner
2,804 Views

Hi Michael,

thank you for your comment.

I actually tried either with the new Ubuntu after formatting the original one, but I still encounter the same problem.

I also tried with two differents CFLAGS, CXXFLAGS, FCFLAGS, with '-xHost -ip', and ' '

but either in those case, there still exists same problem.

I remember that the Ubuntu releases prior to 16.04 have no problem with installing HDF5, MPICH, NETCDF libraries with Intel compilers,

but similar error was reported with 17.04(I don't know the issue is resolved currently) not only with 18.04 LTS.

Thanks

0 Kudos
Eugene_E_Intel
Employee
2,804 Views

I did a quick web search on "checking size of size_t... configure: error" issue.  It usually ends up to be the result of some issue in the configure scripts.  It's possible that the new versions of autotools (or whatever build tools used) does not like something in HDF5 configuration scripts. I recommend that you bring this issue to the attention of the owners/maintainers of HDF5 source code.

Thank you,

--Eugene

 

0 Kudos
Simchan_Y_
Beginner
2,804 Views

Eugene Epshteyn (Intel) wrote:

I did a quick web search on "checking size of size_t... configure: error" issue.  It usually ends up to be the result of some issue in the configure scripts.  It's possible that the new versions of autotools (or whatever build tools used) does not like something in HDF5 configuration scripts. I recommend that you bring this issue to the attention of the owners/maintainers of HDF5 source code.

Thank you,

--Eugene

 

 

Thank you

Actually I was reporting this issue to HDF5 support team too.

So, then I'll tell them to look for configure script.

Simchan

0 Kudos
Simchan_Y_
Beginner
2,804 Views

First, I tried again to install HDF5 after updating & upgrading the binutils, make, build-essential,

but there still existed same error.

 

So rather, I tried to downgrade my GCC, Gfortran, G++ from 7.3 to version 6.0

(which worked well in the previous version of Ubuntu 16.04LTS to install HDF5 with Intel Compilers).

 

following the

https://askubuntu.com/questions/724872/downgrade-gcc-from-5-2-1-to-4-9-ubuntu-15-10

I did something like
sudo update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-6 60 --slave /usr/bin/g++ g++ /usr/bin/g++-6 --slave /usr/bin/gfortran gfortran /usr/bin/gfortran-6
sudo update-alternatives --config gcc

 

and after downgrading the GCC,G++,Gfortran

and I successfully completed ./configure

without error.

 

But, then I encountered error from make

+===============================================
make  all-am
make[2]: Entering directory '/home/scyook/LIB/hdf5-1.10.2/src'
  CC       H5.lo
In file included from H5private.h(54),
                 from H5.c(22):
/opt/intel/compilers_and_libraries_2018.2.199/linux/compiler/include/math.h(1230): error: identifier "_LIB_VERSION_TYPE" is undefined
  _LIBIMF_EXTERN_C _LIB_VERSIONIMF_TYPE _LIBIMF_PUBVAR _LIB_VERSIONIMF;
                   ^

compilation aborted for H5.c (code 2)
Makefile:1431: recipe for target 'H5.lo' failed
make[2]: *** [H5.lo] Error 1
make[2]: Leaving directory '/home/scyook/LIB/hdf5-1.10.2/src'
Makefile:1001: recipe for target 'all' failed
make[1]: *** [all] Error 2
make[1]: Leaving directory '/home/scyook/LIB/hdf5-1.10.2/src'
Makefile:652: recipe for target 'all-recursive' failed
make: *** [all-recursive] Error 1
 

-=======================================

 

and I searched that it can be resolved by

adding below to /usr/include/math.h

+===========================================

#ifdef  __USE_MISC
/* Support for various different standard error handling behaviors.  */
typedef enum
{
  _IEEE_ = -1,  /* According to IEEE 754/IEEE 854.  */
  _SVID_,       /* According to System V, release 4.  */
  _XOPEN_,      /* Nowadays also Unix98.  */
  _POSIX_,
  _ISOC_        /* Actually this is ISO C99.  */
} _LIB_VERSION_TYPE;

/* This variable can be changed at run-time to any of the values above to
   affect floating point error handling behavior (it may also be necessary
   to change the hardware FPU exception settings).  */
extern _LIB_VERSION_TYPE _LIB_VERSION;
#endif

-===================================================

from

https://software.intel.com/en-us/forums/intel-c-compiler/topic/760979

(Actually helped me with problems in installing MPICH library too.)
 
however, I encountered another error (skipped to capture it) which seems relevant with flags.
So I set

export CFLAGS='-O3 -xHost -ip'
export CXXFLAGS='-O3 -xHost -ip'
export FCFLAGS='-O3 -xHost -ip'

(before, all of the flags were empty ' ')

and configure->make->make install

 

Finally, could install HDF5 with Intel Compilers 18.02 in Ubuntu 18.04LTS.

Also, NETCDF-C,Fortran,C++, MPICH too

0 Kudos
TimP
Honored Contributor III
2,804 Views

If you can build with gcc, gfortran, and not so ancient versions of ifort (with either gcc or icc), surely you could build with ifort and the same version of gcc.  If icc were not compatible with gcc, you would need to rebuild most of any linux distro to work with icc.  Besides, it's necessary for icpc to be compatible with the g++ versions used to build "supported" distros.  ifort requires a run-time library which is incompatible with gfortran, but it's compatible with both g++ and icpc, up to the g++ version of the supported distros.

0 Kudos
kumar__Mukesh
Beginner
2,804 Views

 Hi...

 While installing ICC and IFORT (2011 version) compiler in Ubuntu 18.04, has shown core dumped error. But I successfully installed in Ubuntu 16.04 and 14.04, and 12.04. 

ICC version =2011_10_319

IFORT version =2011_9_293

./install.sh: line 538:  6593 Segmentation fault      (core dumped) $pset_engine_binary --tmp-dir=$user_tmp --log-file=$log_file $silent_params $duplicate_params $params --PACKAGE_DIR=$fullpath

 

0 Kudos
Reply