summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJames Laird <jlaird@hdfgroup.org>2005-09-01 20:31:46 (GMT)
committerJames Laird <jlaird@hdfgroup.org>2005-09-01 20:31:46 (GMT)
commitc7808fa57eb9923b15d06e170dda140e72139ab8 (patch)
treeb28fc1ffc690d88bd061ae1c0d34fc9f529ea459
parenta5f1aa713fa4a34752fd6ad0e6d9b7d9c31a8d18 (diff)
downloadhdf5-c7808fa57eb9923b15d06e170dda140e72139ab8.zip
hdf5-c7808fa57eb9923b15d06e170dda140e72139ab8.tar.gz
hdf5-c7808fa57eb9923b15d06e170dda140e72139ab8.tar.bz2
[svn-r11334] Purpose:
Feature: checking configure flags (bug #90) Description: Some configure flags don't work together. Configure now exits with a sensible error message if one of these combinations is specified. Solution: The following flags will throw errors: --enable-cxx and --enable-parallel --enable-cxx and --enable-threadsafe --enable-threadsafe and --enable-parallel --enable-fphdf5 and --enable-fortran Platforms tested: mir, modi4, heping Misc. update:
-rwxr-xr-xconfigure26
-rw-r--r--configure.in25
2 files changed, 51 insertions, 0 deletions
diff --git a/configure b/configure
index d0374b5..f22654e 100755
--- a/configure
+++ b/configure
@@ -44818,6 +44818,12 @@ if test "${enable_threadsafe+set}" = set; then
THREADSAFE=$enableval
fi;
+if test "X${HDF_CXX}" != "X" && test "X${THREADSAFE}" != "X"; then
+ { { echo "$as_me:$LINENO: error: --enable-cxx and --enable-threadsafe flags are incompatible" >&5
+echo "$as_me: error: --enable-cxx and --enable-threadsafe flags are incompatible" >&2;}
+ { (exit 1); exit 1; }; }
+fi
+
case "X-$THREADSAFE" in
X-|X-no)
echo "$as_me:$LINENO: result: no" >&5
@@ -48106,6 +48112,18 @@ if test "${enable_parallel+set}" = set; then
fi;
+if test "X${HDF_CXX}" != "X" && test "X${enable-parallel}" != "X"; then
+ { { echo "$as_me:$LINENO: error: --enable-cxx and --enable-parallel flags are incompatible" >&5
+echo "$as_me: error: --enable-cxx and --enable-parallel flags are incompatible" >&2;}
+ { (exit 1); exit 1; }; }
+fi
+
+if test "X${THREADSAFE}" != "X" && test "X${enable-parallel}" != "X"; then
+ { { echo "$as_me:$LINENO: error: --enable-threadsafe and --enable-parallel flags are incompatible" >&5
+echo "$as_me: error: --enable-threadsafe and --enable-parallel flags are incompatible" >&2;}
+ { (exit 1); exit 1; }; }
+fi
+
echo "$as_me:$LINENO: checking for parallel support files" >&5
echo $ECHO_N "checking for parallel support files... $ECHO_C" >&6
case "X-$enable_parallel" in
@@ -49867,8 +49885,16 @@ if test "${enable_fphdf5+set}" = set; then
else
FPHDF5="no"
fi;
+
if test "X$FPHDF5" = "Xyes"; then
+ if test "X$${FPHDF5}" != "X" && test "X${HDF_FORTRAN}" != "X"; then
+ { { echo "$as_me:$LINENO: error: --enable-fphdf5 and --enable-fortran flags are incompatible" >&5
+echo "$as_me: error: --enable-fphdf5 and --enable-fortran flags are incompatible" >&2;}
+ { (exit 1); exit 1; }; }
+ fi
+
+
cat >>confdefs.h <<\_ACEOF
#define HAVE_FPHDF5 1
_ACEOF
diff --git a/configure.in b/configure.in
index d72ea3a..a4e659e 100644
--- a/configure.in
+++ b/configure.in
@@ -1308,6 +1308,12 @@ AC_ARG_ENABLE([threadsafe],
[Enable thread safe capability])],
THREADSAFE=$enableval)
+dnl The --enable-threadsafe flag is not compatible with --enable-cxx.
+dnl If the user tried to specify both flags, throw an error.
+if test "X${HDF_CXX}" != "X" && test "X${THREADSAFE}" != "X"; then
+ AC_MSG_ERROR([--enable-cxx and --enable-threadsafe flags are incompatible])
+fi
+
case "X-$THREADSAFE" in
X-|X-no)
AC_MSG_RESULT([no])
@@ -2027,6 +2033,17 @@ AC_ARG_ENABLE([parallel],
[AC_HELP_STRING([--enable-parallel],
[Search for MPI-IO and MPI support files])])
+dnl The --enable-parallel flag is not compatible with --enable-cxx.
+dnl If the user tried to specify both flags, throw an error.
+if test "X${HDF_CXX}" != "X" && test "X${enable-parallel}" != "X"; then
+ AC_MSG_ERROR([--enable-cxx and --enable-parallel flags are incompatible])
+fi
+
+dnl --enable-parallel is also incompatible with --enable-threadsafe.
+if test "X${THREADSAFE}" != "X" && test "X${enable-parallel}" != "X"; then
+ AC_MSG_ERROR([--enable-threadsafe and --enable-parallel flags are incompatible])
+fi
+
AC_MSG_CHECKING([for parallel support files])
case "X-$enable_parallel" in
X-|X-no|X-none)
@@ -2237,7 +2254,15 @@ if test -n "$PARALLEL"; then
interface [default=no]])],
[FPHDF5=$enableval],
[FPHDF5="no"])
+
if test "X$FPHDF5" = "Xyes"; then
+
+ dnl The --enable-fphdf5 flag is not compatible with --enable-fortran.
+ dnl If the user tried to specify both flags, throw an error.
+ if test "X$${FPHDF5}" != "X" && test "X${HDF_FORTRAN}" != "X"; then
+ AC_MSG_ERROR([--enable-fphdf5 and --enable-fortran flags are incompatible])
+ fi
+
AC_DEFINE(HAVE_FPHDF5, 1,
[Define if we want flexible parallel HDF5 support])
AC_MSG_RESULT([yes])