summaryrefslogtreecommitdiffstats
path: root/configure.ac
diff options
context:
space:
mode:
authorLarry Knox <lrknox@hdfgroup.org>2012-09-27 04:49:19 (GMT)
committerLarry Knox <lrknox@hdfgroup.org>2012-09-27 04:49:19 (GMT)
commitc5371d76189dee408b9f15a46fbfbf102d009636 (patch)
tree551cf87d4fde2e1b9d821f266d8159ece36bfd4a /configure.ac
parent7702c7f760f0a4eb01059b621cf0df747153a021 (diff)
downloadhdf5-c5371d76189dee408b9f15a46fbfbf102d009636.zip
hdf5-c5371d76189dee408b9f15a46fbfbf102d009636.tar.gz
hdf5-c5371d76189dee408b9f15a46fbfbf102d009636.tar.bz2
[svn-r22819] Added H5BLD_STATIC and HDF5_USE_SHLIB to configure.ac so that if configured with --disable-static the default for HDF5_USE_SHLIB in the compile scripts will be changed to yes. This is a fix for HDFFV-8141, where the compile scripts try to link to non-existant static hdf5 libraries.
Tested on jam,koala,ostrich(h5committest) and other THG machines.
Diffstat (limited to 'configure.ac')
-rw-r--r--configure.ac15
1 files changed, 15 insertions, 0 deletions
diff --git a/configure.ac b/configure.ac
index 7f75326..b8b9f6e 100644
--- a/configure.ac
+++ b/configure.ac
@@ -194,6 +194,13 @@ AC_SUBST([enable_shared])
AC_SUBST([enable_static])
AC_SUBST([UNAME_INFO]) UNAME_INFO=`uname -a`
+## Define symbol variables to allow h5cc.in and its companions to determine
+## whether static libraries are built or not. When they are not built, the
+## compile scripts should use shared libraries by default
+
+AC_SUBST([H5BLD_STATIC]) H5BLD_STATIC=yes
+AC_SUBST([HDF5_USE_SHLIB])
+
## ----------------------------------------------------------------------
## Some platforms have broken basename, and/or xargs programs. Check
## that it actually does what it's supposed to do. Catch this early
@@ -4369,6 +4376,14 @@ AM_CONDITIONAL([BUILD_HDF5_HL_CONDITIONAL], [test "X$HDF5_HL" = "Xyes"])
## Build the Makefiles.
##
+## If $enable_static = "no", set HDF5_USE_SHLIB to "yes" so that the compile
+## scripts will default to use shared libraries instead of defaulting to
+## use static libraries. Otherwise they fail because the static libraries
+## don't exist.
+if test "X$enable_static" = "Xno"; then
+ HDF5_USE_SHLIB="yes"
+fi
+
## The directory search list
AC_SUBST([SEARCH]) SEARCH='$(srcdir) $(top_builddir)/src $(top_srcdir)/src'
cmd='echo $SEARCH |sed "s/ /'$SEARCH_SEP'/g"'