hhoeflin / hdf5r

Other
81 stars 23 forks source link

Consider `pkg-config` for finding the compiler flags? #227

Open dipterix opened 3 months ago

dipterix commented 3 months ago

This issue is a continuation of https://github.com/hhoeflin/hdf5r/issues/165

Background:

Recently homebrew has changed their HDF5 from using autoconf to cmake. The result is h5cc -show (used by configure.ac) is broken, causing hdf5r to crash during compiling.

Besides, HDF5Groups have a discussion of kicking autotools out and embrace cmake (https://www.hdfgroup.org/2022/11/can-we-remove-the-autotools/) in its new versions.

Currently if you are using Mac and install the newest HDF5, it's most likely that the HDF5 is configured with cmake and pkg-config is installed (brew list it as the dependence). In fact, Python package h5py uses pkgconfig to determine the flags too.

Maybe it's time to consider adding pkg-config as a back-up method in case h5cc -show results in error?

hhoeflin commented 3 months ago

Would you consider making a PR?

On Wed, Jul 24, 2024, 05:03 Dipterix Wang @.***> wrote:

This issue is a continuation of #165 https://github.com/hhoeflin/hdf5r/issues/165

Background:

Recently homebrew has changed their HDF5 from using autoconf to cmake https://github.com/Homebrew/homebrew-core/blob/510e60db60d1142cea1fc1ec246fdbed4af4430e/Formula/h/hdf5.rb#L46. The result is h5cc -show (used by configure.ac) is broken, causing hdf5r to crash during compiling.

Besides, HDF5Groups have a discussion of kicking autotools out and embrace cmake (https://www.hdfgroup.org/2022/11/can-we-remove-the-autotools/) in its new versions.

Currently if you are using Mac and install the newest HDF5, it's most likely that the HDF5 is configured with cmake and pkg-config is installed (brew list it as the dependence). In fact, Python package h5py uses pkgconfig to determine the flags too.

Maybe it's time to consider adding pkg-config as a back-up method in case h5cc -show results in error?

— Reply to this email directly, view it on GitHub https://github.com/hhoeflin/hdf5r/issues/227, or unsubscribe https://github.com/notifications/unsubscribe-auth/AASGMYRXDRNXFCIBGAEO7EDZN4KQFAVCNFSM6AAAAABLLSMUISVHI2DSMVQWIX3LMV43ASLTON2WKOZSGQZDMNBYGI2DSMY . You are receiving this because you are subscribed to this thread.Message ID: @.***>

dipterix commented 3 months ago

Let me see what I can do. I notice that there is no header file for 1.14.3 in inst folder. I wonder if that's OK?

hhoeflin commented 3 months ago

That is ok. The interface is frozen for 1.12

On Wed, Jul 24, 2024, 14:42 Dipterix Wang @.***> wrote:

Let me see what I can do. I notice that there is no header file for 1.14.3 in inst folder. I wonder if that's OK?

— Reply to this email directly, view it on GitHub https://github.com/hhoeflin/hdf5r/issues/227#issuecomment-2247817429, or unsubscribe https://github.com/notifications/unsubscribe-auth/AASGMYQOV27IZWY3CLHHQFTZN6OMJAVCNFSM6AAAAABLLSMUISVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDENBXHAYTONBSHE . You are receiving this because you commented.Message ID: @.***>