-
Notifications
You must be signed in to change notification settings - Fork 106
CG_SIZE_MAX not enclosed in protecting CGNS_ENUMV #816
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
Comments
Hello CG_SIZE_MAX should be a MACRO value defined in cgnstypes.h . |
cgnstypes.h is indeed being generated in the cmake build/src folder. But I get the following compilation error,
|
Have you check that CG_SIZE_MAX is or is not present in the cgnstype.h of your cmake build folder ? It may be a cmake or toolchain issue since the code has been tested with gcc 14 without any issue. You should try to clean up the build and do a new install. |
I did a clean configure/compile but this does not change the compile errors. Protecting with CGNS_ENUMV removes the errors. I guess this maybe a Mac specific issue with gcc-14. |
As already mentioned CG_SIZE_MAX is a MACRO defined value, it is not an enum. Thus, good for you if it works with your modification but we won't do this kind of incoherent modification to the CGNS MLL code. |
@pavanakumar, I can reproduce your error. I'll look into an alternative solution. Thanks. |
@brtnfld does the "inttypes.h" header exists on MACOS or was it removed ? |
I'm still investigating, but it seems to be a CMake issue. An Autotools build does not have any issues. I did reproduce the error before but did a fresh install, and I can no longer reproduce the reported error. With scoping off, it always seems to work. But with scoping on, it does fail to compile the Fortran tests.
|
I think it has to do with doing an Autotools build in the source directory and then a CMake build using that source directory, at least for me. If you clone the source, do a CMake build; it has no issues with scoping on or off. @pavanakumar, can you try that? |
Using a fresh CGNS install, I have no issues with CMake or Autotools, with and without scoping using GCC 14.2.0 on Macs. If you still do, then can you provide your CGNS build options? |
Here are my build options
I tried with/without scoping and also disabled mem debug. I get the same compiler error. Note that I use HDF5 v1.14.3 compiled against MPICH v4.3.0b1 and Cmake v3.31.2. |
@pavanakumar The develop branch has been updated to help cmake identify your issue. |
@brtnfld I don't mind keeping this issue open. But as we currently do not manage to reproduce the issue and the MacOS CI build works perfectly well I suggest removing the blocking flag and add a low priority. |
I'm sorry. I had to rebuild mpich with GCC 14.2, which takes forever. The original reproducer was from a CGNS directory that I use for a playground. Once I used a clean CGNS checkout, I could not reproduce the error regardless of whether an Autotools build was also there. It always works for parallel or serial. I should have asked what version of CGNS this is. I agree; we will push this to version 4.6.0 with a lower status. I'll go ahead and merge your recent update to master for the release. |
CG_SIZE_MAX must be protected using the macro CGNS_ENUMV. Otherwise it throws compile errors in gcc version 14.2.0 (Homebrew GCC 14.2.0_1).
Giving below the patch (diff)
The text was updated successfully, but these errors were encountered: