Skip to content
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

Fix fatal error C1083: Cannot open include file #4250

Closed
wants to merge 1 commit into from

Conversation

hyoklee
Copy link
Member

@hyoklee hyoklee commented Mar 26, 2024

@@ -23,7 +23,7 @@
#define H5_ZLIB_HEADER "zlib.h"
#endif
#if defined(H5_ZLIB_HEADER)
#include H5_ZLIB_HEADER /* "zlib.h" */
#include H5_ZLIB_HEADER "zlib.h"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't think you want both, and why does H5_ZLIB_HEADER fail since it should be exactly the same as the text you added?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

direct_chunk.c has the same include block - does it fail?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The reason it is not hard-coded is that the header file could be overridden with something different.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

direct_chunk.c has the same include block - does it fail?

No. (I guess build process failed before it reached direct_chunk.c).

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't think you want both, and why does H5_ZLIB_HEADER fail since it should be exactly the same as the text you added?

I think the problem is escape character: \"zlib.h\". How can we fix it?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That was passed in as a define so that needs fixed

Copy link
Contributor

@byrnHDF byrnHDF left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The question should be why is the H5_ZLIB_HEADER not defined correctly?

@hyoklee
Copy link
Member Author

hyoklee commented Mar 26, 2024

@byrnHDF, I set -DHDF5_ENABLE_Z_LIB_SUPPORT:BOOL=OFF.
Build failed on win10 + VS2022 + oneAPI mpicc.

@tbeu
Copy link
Contributor

tbeu commented Mar 26, 2024

By the way, why is it called HDF5_ENABLE_Z_LIB_SUPPORT and not HDF5_ENABLE_ZLIB_SUPPORT? Would make dev live easier when filtering for zlib in CMake GUI.

grafik

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants