diff options
author | Jerome Soumagne <jsoumagne@hdfgroup.org> | 2019-02-21 22:39:37 (GMT) |
---|---|---|
committer | Jerome Soumagne <jsoumagne@hdfgroup.org> | 2019-02-21 22:39:37 (GMT) |
commit | bcf5c400c06bf06820b25c37eceaa97245f15f1f (patch) | |
tree | 38c116e724cc4ffb97a4a5d4f8eea4b657466fdd /config/cmake/H5pubconf.h.in | |
parent | b901552b1ca315db8b27ea090011f2f557491d46 (diff) | |
download | hdf5-bcf5c400c06bf06820b25c37eceaa97245f15f1f.zip hdf5-bcf5c400c06bf06820b25c37eceaa97245f15f1f.tar.gz hdf5-bcf5c400c06bf06820b25c37eceaa97245f15f1f.tar.bz2 |
Fix CMake H5_HAVE_THREADSAFE to set value in H5pubconf.h
Add REQUIRED to find_package(Threads)
Link against thread library if static and not WIN32 platform
Diffstat (limited to 'config/cmake/H5pubconf.h.in')
-rw-r--r-- | config/cmake/H5pubconf.h.in | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/config/cmake/H5pubconf.h.in b/config/cmake/H5pubconf.h.in index 273adb5..9e7b8b7 100644 --- a/config/cmake/H5pubconf.h.in +++ b/config/cmake/H5pubconf.h.in @@ -390,8 +390,13 @@ /* Define to 1 if you have the <szlib.h> header file. */ #cmakedefine H5_HAVE_SZLIB_H @H5_HAVE_SZLIB_H@ +#if defined(_WIN32) && !defined(H5_BUILT_AS_DYNAMIC_LIB) +/* Not supported on WIN32 platforms with static linking */ +/* #undef H5_HAVE_THREADSAFE */ +#else /* Define if we have thread safe support */ -#cmakedefine H5_HAVE_THREADSAFE @H5_HAVE_THREADSAFE@ +# cmakedefine H5_HAVE_THREADSAFE @H5_HAVE_THREADSAFE@ +#endif /* Define if timezone is a global variable */ #cmakedefine H5_HAVE_TIMEZONE @H5_HAVE_TIMEZONE@ |