[Octopus-devel] [PATCH] Fix --disable-openmp

Tobias Burnus tobias.burnus at physik.fu-berlin.de
Mon Jul 7 18:56:55 WEST 2008


Tobias Burnus wrote:
> Hi,
>
> using --disable-openmp was regarded as synonym for --enable-openmp 
> which was quite puzzling.
And now also giving no argument means disabling. Sorry for the bug.

Tobias

Index: configure.ac
===================================================================
--- configure.ac        (revision 4361)
+++ configure.ac        (working copy)
@@ -86,10 +86,18 @@
 dnl complex wave-functions in the ground-state, and in debug mode.

 dnl these are the --enable/--disable possible in octopus
-AC_ARG_ENABLE(single, AS_HELP_STRING([--enable-single], [octopus in single precision]), [SINGLE_PRECISION=1])
+AC_ARG_ENABLE(single, AS_HELP_STRING([--enable-single], [octopus in single precision]))
 AC_ARG_ENABLE(debug, AS_HELP_STRING([--disable-debug], [debug mode]), [DEBUG=${enableval}])
-AC_ARG_ENABLE(openmp, AS_HELP_STRING([--enable-openmp], [Multi-threaded parallel version using OpenMP (experimental)]), [USE_OMP=1])
+AC_ARG_ENABLE(openmp, AS_HELP_STRING([--enable-openmp], [Multi-threaded parallel version using OpenMP (experimental)]))

+if test -n "${enable_single}" -a x"${enable_single}" != x"no"; then
+  SINGLE_PRECISION=1
+fi
+
+if test -n "${enable_single}" -a x"${enable_openmp}" != x"no"; then
+  USE_OMO=1
+fi
+
 dnl the MPI has a special treatment
 AC_ARG_ENABLE(mpi, AS_HELP_STRING([--enable-mpi(=PATH)], [Parallel version]))
 case $enable_mpi in




More information about the Octopus-devel mailing list