Skip to content

Commit

Permalink
Stat st blocks fix 110 (#249)
Browse files Browse the repository at this point in the history
* close #195. (#196)

* Update HDF5PluginMacros.cmake

* Update HDF5PluginMacros.cmake

* Modify temporary rpath for testing in java example scripts. (#230)

* Fixes Autotools detection of the st_blocks field in stat (#246)

* Fixes Autotools detection of the st_blocks field in stat

The Autotools and CMake will now both correctly determine if the
stat struct has the st_blocks field and set H5_HAVE_STAT_ST_BLOCKS
appropriately.

* Fixes a typo in configure.ac

Co-authored-by: H. Joe Lee <[email protected]>
Co-authored-by: Dana Robinson <[email protected]>
  • Loading branch information
3 people authored Jan 11, 2021
1 parent 0a72966 commit ef6421f
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 3 deletions.
4 changes: 2 additions & 2 deletions configure.ac
Original file line number Diff line number Diff line change
Expand Up @@ -1962,10 +1962,10 @@ esac


## ----------------------------------------------------------------------
## Does the struct stat have the st_blocks field? This field is not Posix.
## Does the struct stat have the st_blocks field? This field is not POSIX.
##
AC_MSG_CHECKING([for st_blocks in struct stat])
AC_COMPILE_IFELSE([AC_LANG_PROGRAM[[
AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[
#include <sys/stat.h>]],[[struct stat sb; sb.st_blocks=0;]])],
[AC_DEFINE([HAVE_STAT_ST_BLOCKS], [1],
[Define if struct stat has the st_blocks field])
Expand Down
11 changes: 10 additions & 1 deletion release_docs/RELEASE.txt
Original file line number Diff line number Diff line change
Expand Up @@ -183,7 +183,16 @@ Bug Fixes since HDF5-1.10.7 release

Configuration
-------------
-
- Fixes Autotools determination of the stat struct having an st_blocks field

A missing parenthesis in an autoconf macro prevented building the test
code used to determine if the stat struct contains the st_blocks field.
Now that the test functions correctly, the H5_HAVE_STAT_ST_BLOCKS #define
found in H5pubconf.h will be defined correctly on both the Autotools and
CMake. This #define is only used in the tests and does not affect the
HDF5 C library.

(DER - 2021/07/01, HDFFV-11201)

Performance
-------------
Expand Down

0 comments on commit ef6421f

Please sign in to comment.