check_version()
{
if [ -z "$HDF5HOME" ]; then
- #echo "HDF5HOME doesn't set"
return 1
fi
check_lib_version libhdf5.so.0.0.0 ${HDF5HOME}/lib
if [ "$?" -ne "0" ]; then
return 1
fi
-#check libhdf5.settings file in a ${HDF5HOME}/lib
check_lib_version libhdf5.settings ${HDF5HOME}/lib
if [ "$?" -eq "0" ]; then
- #check that libhdf5.settings file contains following entry:
- #HDF5 Version: hdf5-1.4.4
- entry=`grep "HDF5 Version:" ${HDF5HOME}/lib/libhdf5.settings`
- ver=`echo $entry | awk '{print $3}'`
+ ver=`grep "HDF5 Version:" ${HDF5HOME}/lib/libhdf5.settings | awk '{print $3}'`
if [ "$ver" = "1.4.4" ]; then
- #echo "The product ${PRODUCT} has been already installed on yours system"
return 0
fi
fi
{
cat > ${INSTALL_WORK}/env_${PRODUCT_TYPE}.sh <<EOF
#$DELIM ${PRODUCT_TYPE} $DELIM
-export HDF5HOME=\${INSTALL_ROOT}/hdf5-1.4.4
+export HDF5HOME=\${INSTALL_ROOT}/${PRODUCT}
export PATH=\${HDF5HOME}/bin:\$PATH
export LD_LIBRARY_PATH=\${HDF5HOME}/lib:\${LD_LIBRARY_PATH}
##
install_source()
{
-echo "The installation of hdf5 1.4.4 from sources is not supported!"
-return 1
+make_env ${INSTALL_ROOT} ${INSTALL_WORK} "${PRODUCT_SEQUENCE}" ${PRODUCT_TYPE}
+source ${INSTALL_WORK}/$SHRC
+
+check_jb tar xfz ${SOURCE_DIR}/hdf5-1.4.4.tar.gz -C ${INSTALL_WORK}
+cd ${PRODUCT_WORK}
+makedir ${PRODUCT_DIR}
+check_job ${PRODUCT_DIR}/CONFIGURE.LOG \
+ ./configure --prefix=${PRODUCT_DIR} --enable-threadsafe --enable-hdf5v1_2 \
+ --enable-stream-vfd --disable-hsizet --with-pthread=/usr/include,/usr/lib
+GCC=`which gcc`
+cat >> ${PRODUCT_DIR}/MAKE0.LOG <<EOF
+used gcc=$GCC
+EOF
+check_job ${PRODUCT_DIR}/MAKE0.LOG make
+# 1
+sed -e 's%$(srcdir)/usr%/usr%g' ./src/.depend > ./src/.dependnew
+mv ./src/.dependnew ./src/.depend
+cat >> ${PRODUCT_DIR}/MAKE1.LOG <<EOF
+used gcc=$GCC
+EOF
+check_job ${PRODUCT_DIR}/MAKE1.LOG make
+# 2
+sed -e 's%$(srcdir)/usr%/usr%g' ./test/.depend > ./test/.dependnew
+mv ./test/.dependnew ./test/.depend
+cat >> ${PRODUCT_DIR}/MAKE2.LOG <<EOF
+used gcc=$GCC
+EOF
+check_job ${PRODUCT_DIR}/MAKE2.LOG make
+# 3
+sed -e 's%$(srcdir)/usr%/usr%g' ./tools/lib/.depend > ./tools/lib/.dependnew
+mv ./tools/lib/.dependnew ./tools/lib/.depend
+cat >> ${PRODUCT_DIR}/MAKE3.LOG <<EOF
+used gcc=$GCC
+EOF
+check_job ${PRODUCT_DIR}/MAKE3.LOG make
+# 4
+sed -e 's%$(srcdir)/usr%/usr%g' ./tools/h5dump/.depend > ./tools/h5dump/.dependnew
+mv ./tools/h5dump/.dependnew ./tools/h5dump/.depend
+cat >> ${PRODUCT_DIR}/MAKE4.LOG <<EOF
+used gcc=$GCC
+EOF
+check_job ${PRODUCT_DIR}/MAKE4.LOG make
+# 5
+sed -e 's%$(srcdir)/usr%/usr%g' ./tools/h5ls/.depend > ./tools/h5ls/.dependnew
+mv ./tools/h5ls/.dependnew ./tools/h5ls/.depend
+cat >> ${PRODUCT_DIR}/MAKE5.LOG <<EOF
+used gcc=$GCC
+EOF
+check_job ${PRODUCT_DIR}/MAKE5.LOG make
+# 6
+sed -e 's%$(srcdir)/usr%/usr%g' ./tools/misc/.depend > ./tools/misc/.dependnew
+mv ./tools/misc/.dependnew ./tools/misc/.depend
+cat >> ${PRODUCT_DIR}/MAKE6.LOG <<EOF
+used gcc=$GCC
+EOF
+check_job ${PRODUCT_DIR}/MAKE6.LOG make
+# 7
+#sed -e 's%$(srcdir)/usr%/usr%g' ./examples/.depend > ./examples/.dependnew
+#mv ./examples/.dependnew ./examples/.depend
+#cat >> ${PRODUCT_DIR}/MAKE7.LOG <<EOF
+#used gcc=$GCC
+#EOF
+#check_job ${PRODUCT_DIR}/MAKE7.LOG make
+##
+#check_job ${PRODUCT_DIR}/MAKECHECK.LOG make check
+check_job ${PRODUCT_DIR}/MAKEINSTALL.LOG make install
+
+#du -sk ${PRODUCT_WORK} > ${PRODUCT_DIR}/size.log
+rm -fr ${PRODUCT_WORK}
+print_env
}
install_binary()