Repository navigation
feat: vendor dlpack as dmlc/dlpack submodule; regenerate bindings; 0.3.4 - #9
Merged
Merged
Conversation
Replace the copied `vendor/dlpack/dlpack.h` with a git submodule of https://github.com/dmlc/dlpack, pinned to commit 77aafa4d (main; adds kDLTPU/kDLTPUHost). `src/bindings.rs` regenerated from the submodule is byte-identical to the committed file — no functional change. - vendor/dlpack: vendored header -> dmlc/dlpack submodule (+ .gitmodules) - build.rs: header path -> vendor/dlpack/include/dlpack/dlpack.h - Cargo.toml: `include` whitelist so the published crate ships only the crate sources + the header (+ LICENSEs), not dmlc's docs/tests/apps. The header is shipped so the opt-in `bindgen` feature also works from a crates.io checkout. Default builds still use the committed bindings (no libclang). - ci.yml regenerate-check: checkout with submodules: recursive. - bump 0.3.3 -> 0.3.4. Verified: default build + tests, `--features pyo3`, `--features bindgen` regenerates identical bindings, clippy, and `cargo publish --dry-run` (12 crate files, header present). Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Makes
vendor/dlpacka submodule of dmlc/dlpack and drivessrc/bindings.rsfrom it — while staying crates.io-publishable (no libclang for consumers).Pinned: submodule at commit
77aafa4d(dmlc/dlpack main; the kDLTPU/kDLTPUHost commit). Regenerated bindings are byte-identical to the committedbindings.rs→ zero functional change.Design (keeps it publishable):
bindings.rsstays committed (default build needs no libclang); thebindgenfeature regenerates it from the submodule, enforced by theregenerate-checkCI job (now checks out submodules).Cargo.tomlincludewhitelist ships only crate sources +dlpack.h(+ LICENSEs), not dmlc's docs/tests. Header is shipped so thebindgenfeature also works from a crates.io checkout.Verified: builds default/
pyo3/bindgen, tests, clippy, fmt,cargo publish --dry-run(12 crate files).Bump 0.3.3 → 0.3.4. After merge: dispatch release.yml to publish. (Note: 0.3.3 stays the version kornia-rs's in-flight rc.2 depends on; identical bindings, so no rush to re-pin.)
🤖 Generated with Claude Code