18 Commits
Author SHA1 Message Date
scivisionandscivision d006fb8d3a CMake Fortran float128 check simplification / correction (#6584)
* CMake bracket-quote Fortran float128 check

this eliminates ambiguous escaping flagged by CMake CMP0219 warning

* CMake fix test escaping

---------

Co-authored-by: scivision <scivision@users.noreply.github.com>
2026-08-06 12:16:06 -05:00
tbeu 7acc58fc86 CMake: Preserve _GNU_SOURCE in CMAKE_REQUIRED_DEFINITIONS for MinGW/Cygwin (#6396)
The earlier block (line 164-167) adds _GNU_SOURCE to
CMAKE_REQUIRED_DEFINITIONS and via add_definitions for MinGW/Cygwin.
However, the later 'MinGW and Cygwin' block overwrites
CMAKE_REQUIRED_DEFINITIONS using CURRENT_TEST_DEFINITIONS (which is
undefined/empty), discarding _GNU_SOURCE. This causes subsequent
configure checks like vasprintf to not see _GNU_SOURCE in their test
definitions.

Use CMAKE_REQUIRED_DEFINITIONS instead of CURRENT_TEST_DEFINITIONS
to append to the existing definitions (which already include
_GNU_SOURCE) rather than replacing them.

Fixes #5885
2026-05-12 10:41:56 -05:00
jhendersonHDF 2952bb9216 Mark several CMake variables as advanced (#6321) 2026-03-27 11:30:23 -05:00
Julien Schueller d58638be09 CMake: Fix Fortran cross-compilation support
Refactor the cross-compilation infrastructure to rely on the standard
CMAKE_CROSSCOMPILING_EMULATOR variable instead of the custom
CROSSCOMPILING_PATH environment hack.

Key changes:
- Removed `ENVIRONMENT "${CROSSCOMPILING_PATH}"` from all test definitions.
- Updated custom commands (e.g., H5match_types, H5_gen) to invoke the
  emulator explicitly when cross-compiling.
- Updated ConfigureChecks.cmake and HDF5UseFortran.cmake to enable
  `try_run` checks when an emulator is defined.
- Added config/toolchain/mingw-w64-x86-64-wine.sh wrapper to automatically
  locate MinGW runtime libraries (like libgfortran) for Wine execution.
- Cleaned up toolchain files to remove hardcoded emulator paths, deferring
  configuration to the build environment.
2026-02-13 14:45:02 -06:00
jhendersonHDF 2ddfed18df Rewrite complex number configuration logic to fix re-configuration issue and improve clarity (#6080) 2025-12-05 11:24:55 -06:00
Matt L 10c2ddc3cb Implement fallback for systems without qsort_r (#5931)
Also includes a new workflow to test FreeBSD, which has a different qsort signature and was previously untested
Resolves #5896
2025-11-02 22:06:34 -06:00
Allen Byrne fb35cde24a Rework Fortran configure to allow cross compile overrides (#5720)
Behavior:
Modify HDF5UseFortran.cmake to handle cross-compilation by providing default KINDs and sizes when CMAKE_CROSSCOMPILING is true.
Default values for INTEGER and REAL KINDs and their sizes are set when cross-compiling.
Error messages are adjusted to reflect cross-compilation scenarios.
Logic:
Conditional checks added for CMAKE_CROSSCOMPILING to determine if default values should be used.
Default values include INTEGER KINDs {1,2,4,8,16} and REAL KINDs {4,8,10,16}.
Default sizes for native kinds are set to 4 for INTEGER and REAL, and 8 for DOUBLE PRECISION when cross-compiling.
Misc:
Adjustments to verbose messages to indicate when defaults are used during cross-compilation.
2025-10-12 17:30:46 -05:00
Dana Robinson 5be9b57ccc Remove checks for sys/types.h (#5821)
This is present on all systems we support, including Windows. There is
no reason to check for it or hide its inclusion behind ifdefs.
2025-09-15 12:38:08 -05:00
Dana Robinson 8bcb79444b Don't include features.h in H5public.h (#5818)
This file is intended for internal glibc use and should not be included
from user code. Instead, you are supposed to set appropriate feature
test macros like _POSIX_C_SOURCE before including C/POSIX library
headers, which we already do.
2025-09-15 08:16:53 -05:00
Allen Byrne f44c9eac01 Add AI generated (reviewed) comments for config CMake files (#5696) 2025-08-12 13:28:19 -05:00
Allen Byrne ed5c07223a Create a file containing the major CMake options (#5666) 2025-07-18 14:47:02 -05:00
Allen Byrne 968cc9dd44 Add script to test examples with h5*cc pkg-config wrappers (#5486) 2025-07-16 13:57:43 -05:00
Allen Byrne 0509e66208 Add cmake_dependent_option command (#5635)
* Add subfiling option to cmake_dependent option format
* Set the default option state to a hard value
2025-07-12 10:16:54 -05:00
Allen Byrne df20da2979 Remove references to autotools options in documentation/comments (#5619) 2025-06-21 13:28:00 -05:00
0743df227f Add documentation and s3proxy testing for ROS3 VFD (#5560)
Adds workflow to build ROS3 VFD and optionally build aws-c-s3 library
from source or use package managers

Adds testing of ROS3 VFD with s3proxy and docker

Adds new H5Pset_fapl_ros3_endpoint()/H5Pget_fapl_ros3_endpoint() API
functions to set/get an alternative endpoint URL to use when opening
files with the ROS3 VFD

Cleans up warnings in tools and tests related to ROS3 VFD structure size

Co-authored-by: Larry Knox <lrknox@hdfgroup.org>
Co-authored-by: Allen Byrne <50328838+byrnHDF@users.noreply.github.com>
2025-06-19 16:22:49 -05:00
Dana Robinson c83266821b Remove checks for dev_t being a scalar type (#5567) 2025-06-09 16:15:56 -05:00
75fff3ed06 Re-write ROS3 VFD S3 backend to use AWS' C S3 library (#5548)
* Re-write ROS3 VFD S3 backend to use AWS' C S3 library

Replaces the ROS3 VFD's libcurl-based S3 backend with a new
backend which uses the aws-c-s3 library

Adds support for sourcing credentials from standard AWS
configuration files, environment variables, etc. with a
fallback to anonymous credentials when credentials can't be
found

Adds support for sourcing AWS region from standard AWS
configuration files and environment variables

Adds support for new environment variables HDF5_ROS3_VFD_DEBUG,
HDF5_ROS3_VFD_LOG_LEVEL and HDF5_ROS3_VFD_LOG_FILE for debugging
purposes

Replaces function to load testing credentials in the ros3.c and
s3comms.c tests with new function that delegates to the aws-c-s3
library for better compatibility with standard AWS configuration
files and environment variables

Adds support for s3:// object URIs

Adds HTTP User-Agent header in form of
'libhdf5/<hdf5_version> (vfd:ros3) libaws-c-s3'

Co-authored-by: Larry Knox <lrknox@hdfgroup.org>
Co-authored-by: Allen Byrne <50328838+byrnHDF@users.noreply.github.com>
2025-05-29 17:51:29 -05:00
Allen Byrne aa9784ea25 Refactor the config/cmake folder #5446 (#5540)
* Update config/examples/HDF5AsSubdirMacros.cmake
* Move f90 config file and remove m4 dir
2025-05-22 11:20:51 -05:00