Skip to content

static build for Windows using GitHub Actions #215

@DavidBJaffe

Description

@DavidBJaffe

I am trying to build for Windows using GitHub Actions. I had a version that built using

hdf5 = { git = "https://github.com/aldanor/hdf5-rust", branch = "master", default-features=false }
hdf5-sys = { git = "https://github.com/aldanor/hdf5-rust", branch = "master", default-features=false, features = ["static","zlib"] }

however the executable that is built gives an error H5Dread(): can't read data: inflateInit() failed, perhaps the same problem as in #206. So I tried

hdf5 = { git = "https://github.com/aldanor/hdf5-rust", branch = "master", default-features=false }
hdf5-sys = { git = "https://github.com/aldanor/hdf5-rust", branch = "master", default-features=false, features = ["static","zlib"] }
libz-sys = { version = "1", features = ["zlib-ng"], default-features = false }

However, this does not build. I get the error message

error: could not find native static library `z`, perhaps an -L flag is missing?
error: could not compile `hdf5-sys` due to previous error

In the yaml file for GitHub Actions, I have just cargo build --release, but am guessing I need something else. Any ideas?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions