Skip to content

Add more comprehensive CI tests for packaging #472

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

Draft
wants to merge 6 commits into
base: master
Choose a base branch
from

Conversation

silvanshade
Copy link
Contributor

This PR subsumes #464.

This PR fixes #462.

CC @BurningEnlightenment

Copy link
Collaborator

@BurningEnlightenment BurningEnlightenment left a comment

Choose a reason for hiding this comment

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

I need to get some time to finally add CMakePresets for the common dev and CI configuartions…

- name: build libblake3
run: cmake --build c/build --target install
- name: configure blake3-examples
run: cmake --fresh -S c/examples -B c/examples/build -G Ninja -DCMAKE_VERBOSE_MAKEFILE=1 "-DCMAKE_INSTALL_PREFIX=${{ github.workspace }}/examples/target" "-DBLAKE3_DIR=${{ github.workspace }}/target/lib/cmake/blake3"
Copy link
Collaborator

Choose a reason for hiding this comment

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

Maybe it'd be cleaner if we used export(PACKAGE / the CMake user package registry1 for this. Thoughts?

Footnotes

  1. https://cmake.org/cmake/help/v3.9/manual/cmake-packages.7.html#package-registry

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Do you mean just for simplifying the test or more generally for release deployment?

I guess I'm not sure how that would look compared to what it is doing now. Maybe you can give an example?

Copy link
Collaborator

Choose a reason for hiding this comment

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

I'll implement a draft today

@BurningEnlightenment BurningEnlightenment self-requested a review April 19, 2025 13:37
@BurningEnlightenment BurningEnlightenment self-assigned this Apr 19, 2025
@BurningEnlightenment BurningEnlightenment marked this pull request as draft April 19, 2025 13:38
@BurningEnlightenment
Copy link
Collaborator

I will continue to work on this next week, but feel free to fix stuff or leave feedback in the meantime.

@BurningEnlightenment
Copy link
Collaborator

@oconnor663 do you think it would make sense to employ a GitHub Actions path filter to only run CI checks for the actually affected stuff? https://docs.github.com/en/actions/writing-workflows/workflow-syntax-for-github-actions#onpushpull_requestpull_request_targetpathspaths-ignore

@oconnor663
Copy link
Member

We could, but there are some pitfalls to watch out for. For example, the Rust crate depends on both c/blake3_avx512.c and c/blake3_neon.c, in addition to all the assembly files under c/. Also both test_vectors/ and c/blake3_c_rust_bindings/ depend on reference_impl/. So far I haven't been particularly bothered by long CI times, so I haven't wanted to risk duplicating the dependency tree in CI configs and getting something wrong over time. What do you think?

Use CMakePresets to drive the test project configuration instead of
hardcoding flags into the build scripts.
@oconnor663
Copy link
Member

Double checking: There's nothing in this PR that we'd want to hold the v1.8.2 release for, correct?

@silvanshade
Copy link
Contributor Author

Nothing mandatory in this PR. In the future it would be useful to have this in place to help catch configuration issues though.

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.

Create CI checks for CMake exported targets & pkg-config importability
3 participants