summaryrefslogtreecommitdiffstats
path: root/configure.ac
diff options
context:
space:
mode:
Diffstat (limited to 'configure.ac')
-rw-r--r--configure.ac135
1 files changed, 87 insertions, 48 deletions
diff --git a/configure.ac b/configure.ac
index ca4d4b6..c68caab 100644
--- a/configure.ac
+++ b/configure.ac
@@ -6,12 +6,10 @@
##
## This file is part of HDF5. The full HDF5 copyright notice, including
## terms governing use, modification, and redistribution, is contained in
-## the files COPYING and Copyright.html. COPYING can be found at the root
-## of the source code distribution tree; Copyright.html can be found at the
-## root level of an installed copy of the electronic HDF5 document set and
-## is linked from the top-level documents page. It can also be found at
-## http://hdfgroup.org/HDF5/doc/Copyright.html. If you do not have
-## access to either file, you may request a copy from help@hdfgroup.org.
+## the COPYING file, which can be found at the root of the source code
+## distribution tree, or in https://support.hdfgroup.org/ftp/HDF5/releases.
+## If you do not have access to either file, you may request a copy from
+## help@hdfgroup.org.
## ----------------------------------------------------------------------
## Initialize configure.
@@ -26,7 +24,7 @@ AC_PREREQ([2.69])
## NOTE: Do not forget to change the version number here when we do a
## release!!!
##
-AC_INIT([HDF5], [1.11.0], [help@hdfgroup.org])
+AC_INIT([HDF5], [1.11.2], [help@hdfgroup.org])
AC_CONFIG_SRCDIR([src/H5.c])
AC_CONFIG_HEADERS([src/H5config.h])
@@ -101,6 +99,7 @@ AC_CONFIG_COMMANDS([pubconf], [
AC_CANONICAL_HOST
AC_SUBST([CPPFLAGS])
AC_SUBST([JNIFLAGS])
+AC_SUBST([AR_FLAGS])
## H5_CFLAGS (and company) are for CFLAGS that should be used on HDF5, but
## not exported to h5cc (or h5fc, etc.)
@@ -141,6 +140,7 @@ JNIFLAGS="${JNIFLAGS}"
JAVACFLAGS="${JAVACFLAGS}"
JAVAFLAGS="${JAVAFLAGS}"
LDFLAGS="${LDFLAGS}"
+AR_FLAGS="${AR_FLAGS}"
## Configure may need to alter any of the *FLAGS variables in order for
## various checks to work correctly. Save the user's value here so it
@@ -587,11 +587,11 @@ if test "X$HDF_FORTRAN" = "Xyes"; then
AC_DEFINE([FORTRAN_HAVE_STORAGE_SIZE], [1], [Define if we have Fortran intrinsic STORAGE_SIZE])
fi
- if test "X$HAVE_C_SIZEOF_FORTRAN" = "Xyes"; then
+ if test "X$HAVE_C_SIZEOF_FORTRAN" = "Xyes"; then
AC_DEFINE([FORTRAN_HAVE_C_SIZEOF], [1], [Define if we have Fortran intrinsic C_SIZEOF])
fi
- if test "X$HAVE_SIZEOF_FORTRAN" = "Xyes"; then
+ if test "X$HAVE_SIZEOF_FORTRAN" = "Xyes"; then
AC_DEFINE([FORTRAN_HAVE_SIZEOF], [1], [Define if we have Fortran intrinsic SIZEOF])
fi
@@ -606,7 +606,7 @@ if test "X$HDF_FORTRAN" = "Xyes"; then
## Is C_LONG_DOUBLE different from C_DOUBLE
FORTRAN_C_LONG_DOUBLE_IS_UNIQUE="0"
- if test "X$FORTRAN_HAVE_C_LONG_DOUBLE"; then
+ if test "$FORTRAN_HAVE_C_LONG_DOUBLE" = "1"; then
PAC_PROG_FC_C_LONG_DOUBLE_EQ_C_DOUBLE
if test "X$C_LONG_DOUBLE_IS_UNIQUE_FORTRAN" = "Xyes"; then
FORTRAN_C_LONG_DOUBLE_IS_UNIQUE="1"
@@ -759,12 +759,17 @@ fi
## Check which archiving tool to use. This needs to be done before
## the AM_PROG_LIBTOOL macro.
##
-
if test -z "$AR"; then
AC_CHECK_PROGS([AR], [ar xar], [:], [$PATH])
fi
AC_SUBST([AR])
+# Set the default ar flags to cr
+# The Automake default is to use cru and the 'u' causes ar
+# to emit warnings on some platforms.
+AR_FLAGS=cr
+
+
## Export the AR macro so that it will be placed in the libtool file
## correctly.
export AR
@@ -920,14 +925,13 @@ H5_FORTRAN_SHARED="no"
if test "X${HDF_FORTRAN}" = "Xyes" && test "X${enable_shared}" != "Xno"; then
AC_MSG_CHECKING([if shared Fortran libraries are supported])
H5_FORTRAN_SHARED="yes"
-
- ## Disable fortran shared libraries on Mac. (MAM - 03/30/11)
-
+ ## tell libtool to do the right thing with COMMON symbols, this fixes
+ ## corrupt values with COMMON and EQUIVALENCE when building shared
+ ## Fortran libraries on OSX with gnu and Intel compilers (HDFFV-2772).
case "`uname`" in
Darwin*)
- H5_FORTRAN_SHARED="no"
- CHECK_WARN="Shared Fortran libraries not currently supported on Mac."
- ;;
+ H5_LDFLAGS="$H5_LDFLAGS -Wl,-commons,use_dylibs"
+ ;;
esac
## Report results of check(s)
@@ -1065,6 +1069,7 @@ esac
case "`uname`" in
CYGWIN*)
AC_CHECK_HEADERS([io.h sys/timeb.h])
+ UNAME_CYGWIN="yes"
;;
MINGW*)
AC_CHECK_HEADERS([io.h winsock2.h sys/timeb.h])
@@ -1254,10 +1259,11 @@ AC_ARG_WITH([fnord],
])
## ----------------------------------------------------------------------
-## Is the dmalloc present? It has a header file `dmalloc.h' and a library
-## `-ldmalloc' and their locations might be specified with the `--with-dmalloc'
-## command-line switch. The value is an include path and/or a library path.
-## If the library path is specified then it must be preceded by a comma.
+## Is dmalloc (debug malloc library) requested? It has a header file
+## `dmalloc.h' and a library `-ldmalloc' and their locations might be
+## specified with the `--with-dmalloc' command-line switch. The value
+## is an include path and/or a library path. If the library path is
+## specified then it must be preceded by a comma.
##
AC_SUBST([HAVE_DMALLOC])
@@ -1943,26 +1949,17 @@ AC_DEFINE_UNQUOTED([PRINTF_LL_WIDTH], ["$hdf5_cv_printf_ll"],
[Width for printf() for type `long long' or `__int64', use `ll'])
## ----------------------------------------------------------------------
-## Deprecate old ways of determining debug/production build
-## These can probably be removed in the future (1.10.1?)
+## Remove old ways of determining debug/production build.
+## These were used in 1.8.x and earlier. We should probably keep these checks
+## around to help people migrate to 1.10.x and newer versions.
##
AC_ARG_ENABLE([debug],
- [AS_HELP_STRING([--enable-debug],
- [DEPRECATED: use --enable-build-mode=debug])],
- [DEPRECATED_DEBUG=$enableval])
-
-if test "X-$DEPRECATED_DEBUG" != "X-" ; then
- AC_MSG_ERROR([--enable-debug is deprecated, use --enable-build-mode=debug instead.])
-fi
+ [AS_HELP_STRING([--enable-debug], [DEPRECATED: use --enable-build-mode=debug])],
+ [AC_MSG_ERROR([--enable-debug is deprecated, use --enable-build-mode=debug instead.])])
AC_ARG_ENABLE([production],
- [AS_HELP_STRING([--enable-production],
- [DEPRECATED: use --enable-build-mode=production])],
- [DEPRECATED_PRODUCTION=$enableval])
-
-if test "X-$DEPRECATED_PRODUCTION" != "X-" ; then
- AC_MSG_ERROR([--enable-production is deprecated, use --enable-build-mode=production instead.])
-fi
+ [AS_HELP_STRING([--enable-production], [DEPRECATED: use --enable-build-mode=production])],
+ [AC_MSG_ERROR([--enable-production is deprecated, use --enable-build-mode=production instead.])])
## ----------------------------------------------------------------------
@@ -2246,7 +2243,7 @@ AC_SUBST([INTERNAL_DEBUG_OUTPUT])
## are not listed in the "all" packages list.
##
## all_packages="AC,B,B2,D,F,FA,FL,FS,HL,I,O,S,ST,T,Z"
-all_packages="AC,B2,D,F,HL,I,O,S,ST,T,Z"
+all_packages="AC,B2,CX,D,F,HL,I,O,S,ST,T,Z"
case "X-$INTERNAL_DEBUG_OUTPUT" in
X-yes|X-all)
@@ -3349,6 +3346,27 @@ else
STATIC_SHARED="none"
fi
+if test "X$HDF_FORTRAN" = "Xyes"; then
+
+ ### libtool does not pass the correct argument linking (-Wl,-Wl,,) for the NAG Fortran compiler
+ ### on Linux (other OSs have not been tested).
+ ### Therefore, detect if we are using the NAG Fortran compiler, and replace the wl="-Wl," for Fortran to
+ ### wl="-Wl,-Wl,," in the libtool file. (HDFFV-10037)
+ case "`uname`" in
+ Linux*)
+
+ fortran_linux_linker_option="-Wl,"
+ if test "X$FC_BASENAME" = "Xnagfor"; then
+ fortran_linux_linker_option="-Wl,-Wl,,"
+ fi
+
+ ## Set the correct linker option for use in h5fc.in markup
+ AC_SUBST([fortran_linux_linker_option])
+ ;;
+ esac
+
+fi
+
## ----------------------------------------------------------------------
## Set a macro if shared library is enabled.
##
@@ -3358,16 +3376,17 @@ AC_CONFIG_FILES([src/libhdf5.settings
Makefile
src/Makefile
test/Makefile
+ test/H5srcdir_str.h
test/testcheck_version.sh
test/testerror.sh
test/testflushrefresh.sh
- test/H5srcdir_str.h
test/testlibinfo.sh
test/testlinks_env.sh
test/testswmr.sh
- test/test_plugin.sh
- test/test_usecases.sh
test/testvdsswmr.sh
+ test/test_filenotclosed.sh
+ test/test_filter_plugin.sh
+ test/test_usecases.sh
testpar/Makefile
tools/Makefile
tools/lib/Makefile
@@ -3444,13 +3463,13 @@ AC_CONFIG_FILES([src/libhdf5.settings
java/test/junit.sh
java/examples/Makefile
java/examples/intro/Makefile
- java/examples/intro/runExample.sh
+ java/examples/intro/JavaIntroExample.sh
java/examples/datasets/Makefile
- java/examples/datasets/runExample.sh
+ java/examples/datasets/JavaDatasetExample.sh
java/examples/datatypes/Makefile
- java/examples/datatypes/runExample.sh
+ java/examples/datatypes/JavaDatatypeExample.sh
java/examples/groups/Makefile
- java/examples/groups/runExample.sh
+ java/examples/groups/JavaGroupExample.sh
hl/Makefile
hl/src/Makefile
hl/test/Makefile
@@ -3483,13 +3502,33 @@ AC_CONFIG_COMMANDS([.classes], [], [$MKDIR_P java/src/.classes;
AC_OUTPUT
chmod 755 tools/src/misc/h5cc
+if test "X$HDF_CXX" = "Xyes"; then
+ chmod 755 c++/src/h5c++
+fi
+
if test "X$HDF_FORTRAN" = "Xyes"; then
chmod 755 fortran/src/h5fc
-fi
+ ## libtool does not pass the correct argument linker (wl=) for the Intel Fortran compiler
+ ## on OS X, which is needed when building shared libraries on OS X. This script
+ ## replaces the 3rd occurrence, which is for Fortran, of wl="" with wl="-Wl," (HDFFV-2772)
+ case "`uname`" in
+ Darwin*)
+ cat libtool | awk '/wl=\"/{c++;if(c==3){sub("wl=\"\"","wl=\"-Wl,\"");c=0}}1' > libtool.tmp && mv -f libtool.tmp libtool && chmod 755 libtool
+ ;;
+ esac
-if test "X$HDF_CXX" = "Xyes"; then
- chmod 755 c++/src/h5c++
+ ### libtool does not pass the correct argument linking (-Wl,-Wl,,) for the NAG Fortran compiler
+ ### on Linux (other OSs have not been tested).
+ ### Therefore, detect if we are using the NAG Fortran compiler, and replace the wl="-Wl," for Fortran to
+ ### wl="-Wl,-Wl,," in the libtool file. (HDFFV-10037)
+ case "`uname`" in
+ Linux*)
+ if test "X$FC_BASENAME" = "Xnagfor"; then
+ cat libtool | awk '/BEGIN LIBTOOL TAG CONFIG: FC/{flag=1}flag&&/wl=/{$NF="wl=\"-Wl,-Wl,,\"";flag=0}1' > libtool.tmp && mv -f libtool.tmp libtool && chmod 755 libtool
+ fi
+ ;;
+ esac
fi
## HDF5 configure code created by autotools with gcc 4.9.2 is adding problematic