diff --git a/CMakeLists.txt b/CMakeLists.txt index 73dc2d3ee28..5139cb3b4c9 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -804,7 +804,7 @@ if (Threads_FOUND) # Comment out check for C11 threads for now, since it conflicts with the # current --std=c99 compile flags at configuration time. When we switch to # --std=c11, this can be uncommented. - #CHECK_INCLUDE_FILE("threads.h" HAVE_THREADS_H) + CHECK_INCLUDE_FILE("threads.h" HAVE_THREADS_H) if (WIN32) # When Win32 is available, we use those threads set (H5_HAVE_WIN_THREADS 1) diff --git a/configure.ac b/configure.ac index 72bc8f91b76..82a3febf370 100644 --- a/configure.ac +++ b/configure.ac @@ -2237,7 +2237,7 @@ if test "X$THREADS" = "Xyes"; then # Comment out check for C11 threads for now, since it conflicts with the # current --std=c99 compile flags at configuration time. When we switch to # --std=c11, this can be uncommented. - #AC_CHECK_HEADERS([threads.h],[HAVE_THREADS_H="yes"],[HAVE_THREADS_H="no"]) + AC_CHECK_HEADERS([threads.h],[HAVE_THREADS_H="yes"],[HAVE_THREADS_H="no"]) if test "x$HAVE_THREADS_H" = "xyes"; then # Default or no --> C11 threads if test "$withval" = "default" -o "$withval" = "no" ; then diff --git a/src/H5private.h b/src/H5private.h index e253bdd5076..466f46a3074 100644 --- a/src/H5private.h +++ b/src/H5private.h @@ -1130,8 +1130,8 @@ extern char H5_lib_vers_info_g[]; #define H5CANCEL_DECL /* */ /* Disable & restore canceling the thread */ -#define H5TS_DISABLE_CANCEL /* */ -#define H5TS_RESTORE_CANCEL /* */ +#define H5TS_DISABLE_CANCEL do {} while(0) /* no-op */ +#define H5TS_RESTORE_CANCEL do {} while(0) /* no-op */ #endif #ifdef H5_HAVE_THREADSAFE @@ -1181,8 +1181,8 @@ extern char H5_lib_vers_info_g[]; #define H5DLFTT_DECL /* */ /* No locks (non-threadsafe builds) */ -#define H5_API_LOCK /* */ -#define H5_API_UNLOCK /* */ +#define H5_API_LOCK do {} while(0) /* no-op */ +#define H5_API_UNLOCK do {} while(0) /* no-op */ #endif /* H5_HAVE_THREADSAFE_API */