-
-
Notifications
You must be signed in to change notification settings - Fork 59
1.14.6 + cmake #255
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
1.14.6 + cmake #255
Conversation
Hi! This is the friendly automated conda-forge-linting service. I just wanted to let you know that I linted all conda-recipes in your PR ( I do have some suggestions for making it better though... For recipe/meta.yaml:
This message was generated by GitHub Actions workflow run https://github.com/conda-forge/conda-forge-webservices/actions/runs/13983615571. Examine the logs at this URL for more detail. |
52e40d4
to
5334645
Compare
recipe/meta.yaml
Outdated
{% set maj_min_ver = ".".join(version.split(".")[:2]) %} | ||
{% set build = 5 %} | ||
{% set version = "1.14.6" %} | ||
{% set maj_min_patch_ver = "_".join(version.split(".")) %} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think it would be easier to just use {{ version|replace(".", "_") }}
in the url, rather than introduce another variable.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
sure.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
{% set maj_min_patch_ver = "_".join(version.split(".")) %} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
but you also need 1_14
and not just 1_14_6
this kind of churn isn't necessary.
Lets focus on the cmake imporvements and the version update.
{% set hdf5_unix_cmds = h5_compilers + [ | ||
"h5redeploy", | ||
] %} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
i believe that this is an automake style tool
Hi! This is the friendly automated conda-forge-linting service. I failed to even lint the recipe, probably because of a conda-smithy bug 😢. This likely indicates a problem in your This message was generated by GitHub Actions workflow run https://github.com/conda-forge/conda-forge-webservices/actions/runs/13983965316. Examine the logs at this URL for more detail. |
Hi! This is the friendly automated conda-forge-linting service. I just wanted to let you know that I linted all conda-recipes in your PR ( I do have some suggestions for making it better though... For recipe/meta.yaml:
This message was generated by GitHub Actions workflow run https://github.com/conda-forge/conda-forge-webservices/actions/runs/16837980984. Examine the logs at this URL for more detail. |
fingers crossed i skipped enough tests for linux. Then it is off to osx cross compilation issues. |
@ajelenak is there some existing HDF5 build constants that you can point me to in order to bypass the checks for type sizes for OSX + arm64 |
@ajelenak @conda-forge/hdf5 i'm not sure if anybody else can jump in here. I mostly have trouble ensuring that the constants I define are getting passed through t the compilation settings. I would love to release 1.14.6 in April, but I'm not sure I will have the investigate this. LMK if anybody can help, otherwise the cmake transition may have to wait till 1.15 and we should merge #254 first. |
@hmaarrfk Where do you have the most problems? Specific platforms? Compilers? Modifying so many tests does not seem right. Is there a common underlying problem? |
Hi @ajelenak thanks for chiming in.
The bigges problems are getting through the cross compilation settings for OSX ARM. We build using a x86-64 runner, and target ARM. without emulation, alot of the "discovery code" that detects the word sizes just fails. I don't understand the build system enough to create our own overrides.
Generally speaking:
make it so that high performance scientific code fails tests. Each skipped test is thematically related to one of the 5 points above and the tests were historically skipped on conda-forge. I've just had to port over the skips to cmake (I still have some skips to port). |
It looks like it may take a while to address these kinds of problems. If you have a quicker option to release 1.14.6, I suggest to use it. |
recipe/build.sh
Outdated
export H5_PAC_FORTRAN_NATIVE_INTEGER_KIND=" 4" | ||
export H5_PAC_FORTRAN_NATIVE_REAL_SIZEOF=" 4" | ||
export H5_PAC_FORTRAN_NATIVE_REAL_KIND=" 4" | ||
export H5_PAC_FORTRAN_NATIVE_DOUBLE_SIZEOF=" 8" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@ajelenak are you saying that this kind of setting of environment variable does not ovewrite
these definitions?
https://github.com/HDFGroup/hdf5/blob/407caf1259dd03685b411f78321f823abd2666a6/config/cmake/HDF5UseFortran.cmake#L424
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't know, have to ask our CMake expert. I have only set CMake variables on the command line (-D option).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That would be very helpful in terms of helping the community improve the state of HDF5 support
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Setting env. variables is not going to affect those CMake variables. Options are setting them on the command line or in a custom cacheinit.cmake file which needs to be specified on the command line.
I know this is not the right place to ask but... is it possible to build conda packages somewhere else? I can build the library in a conda environment on my macOS arm64 laptop without any problem. If all the build tools are available to be installed in a conda environment, would it be possible to use GitHub actions to create conda packages?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There are "plans" to use github runners for OSX builds, but specific platforms are always limited. And it is difficult to guarantee access to the exact hardware. flexibility is "preffered". conda-forge/conda-forge.github.io#1781
I need to read through HDFGroup/hdf5#1203 but there is obviously a great desire to have cross compilation ability in the community beyond just OSX.
I guess you asked how you can help, helping us through the autotools -> cmake transition would be a great help.
If you had time to write a patch that enables these constants to be hardcoded that would go a long way already!!!
If you don't have time that's ok too. Maybe just let me know, and we can delay the whole cmake transition until 1.15
@hmaarrfk Intel just released IFX on conda-forge for windows in conda-forge/intel-compiler-repack-feedstock#57. If you give me a few days I can try to add support for fortran in HDF5 for windows? |
ok sounds great. I don't know if you want to use Cmake or autotools. Somebody needs to write a cmake patch for osx cross compilation. |
I have successfully added fortran support for windows using intel ifx for the It should be safe to merge these changes into this PR. Regarding
I don't have access to any osx machine, so I might not be the best candidate for this. But I can probably find some time in the coming days to give it a shot (although I cannot make any promises). |
do you have access to a linux machine? You could uninstall qemu and ensure that it can be compiled without emulation, that is the big challenge. |
if you could make it a single commit for me to cherry pick (keep the rerendering as a separate commit) that would make it easy to integrate here. |
I squashed the commits and made a single commit containing the changes. Hopefully that can be used: Krande@6e1eb99 (btw. I closed my test PR to limit the number of concurrent jobs.)
Yes, I have access to a linux machine. I can give it a shot |
@@ -72,6 +72,7 @@ requirements: | |||
- {{ stdlib('c') }} | |||
- {{ compiler('cxx') }} | |||
- {{ compiler('fortran') }} # [not win] | |||
- ifx_win-64 # [win and mpi == 'nompi'] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@Krande this is honestly a little strange. I believe that the different variants of HDF5 are abi compatible. However, here you are omitting the fortran libraries for anything where mpi != 'nompi'
is it possible to enable it on all MPI?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Also, instead of hardcoding this in the recipe, it would be better to remove the selectors here and just add
fortran_compiler: # [win]
- ifx # [win]
in CBC
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I've manually checked:
The first three don't even depend on cmake, Arch references, but then uses autotools. Ultimately, we would be trailblazing here, and unless we get help from upstream, I am tempted to move back to #254 |
@mgorny is there any synergy with gentoo package manager in moving from autotools to cmake and ensuring cross compilation works without emulation? I think it needs some patches from some1 knowledgeable in cmake and I'm not sure if you are one that can help. |
Hmm, I see they intend to drop autotools entirely, so I guess we'll have to do that. Yeah, I'll ping our folk and see if we can do something, either me or somebody else. That said, cross is not high on our priority list, so we'll probably only be addressing the problems that affect native builds. |
Okay, I've asked around and we've tried the CMake build recently and it was really bad. Unfortunately, the problem is not CMake build per se but upstream deciding to make breaking changes to And upstream's response is basically:
So basically they require you to update all the reverse dependencies before you switch to CMake. I don't know if any progress has been made on this, or if reverse dependency maintainers are even aware of the problem. |
Small update: I've looked around and it is possible that the original issue was fixed after all (or at least there are some commits that look like a fix) and the bug wasn't closed. I'm going to try to find some time to investigate this. |
@mgorny in terms of "urgency" i've decided to "punt this" until 1.15 because #254 was ready for 1 month and the author had been patiently waiting. it would be great to be "prepared" for this, but it also seems like there are some efforts in making native OSX-arm compilation a possibility. However, any help getting cmake working with cross compilation would definitely be helpful. However, if we try to do it for the same HDF5 version, we need to make sure that the Autotools ABI is compatible with that of the cmake We also just got the gift of this beautiful bug: #258 so ... |
I'll try to tackle it on the Gentoo end — here we can just bump subslot if necessary to indicate ABI incompatibility, and mask the new version for local testing. |
Okay, some good news is that it seems that CMake is now installing usable h5cc. For 1.14.6, I have used the following pull requests:
This is my work-in-progress, and I'm in process of testing reverse dependencies now: gentoo/gentoo#41704 Of course, I don't necessarily know what I'm doing. |
Okay, so far the conclusion is that I haven't seen a single package failing with hdf5 CMake version that worked with the autotools version. I've found other issues, such as packages not using hdf5 when If you need to work on more specific CMake problems, please let me know what they are :-). |
so are you saying that it is likely that CMake + autotools are ABI compatible in this case?
For conda-forge, the biggest challenge stems from the (in)ability to override certain build time variables such as I am hoping to gather more information here, and make a plea upstream to have "more first class support for cross compilation", instead of asking downstream packagers to make their own patches. It could be a win-win for all, |
No clue about ABI compatibility. I just meant that To be honest, I've taken ABI incompatibility at your word and just immediately marked it as incompatible. |
There's at least incompatibility in Fortran libraries: * SONAME:-libhdf5_f90cstub.so.310(64)
* SONAME:-libhdf5_hl_f90cstub.so.310(64)
* SONAME:-libhdf5_hl_fortran.so.310(64)
* SONAME:-libhdf5_tools.so.310(64)
* SONAME:+libhdf5hl_fortran.so.310(64)
|
To be honest, the process of marking ABI compatible/incompatible after packages have been built is rather annoying at conda-forge. So its easier to use the standard run_exports and rebuild. The rebuilding process also helps "refresh" recipes so i'm not always opposed. |
…nda-forge-pinning 2025.08.03.20.34.40
Checklist
0
(if the version changed)conda-smithy
(Use the phrase@conda-forge-admin, please rerender
in a comment in this PR for automated rerendering)