Hi Johannes
On 19/07/2025 22:53, Johannes Schindelin wrote:
Hi Ezekiel,
On Thu, 17 Jul 2025, Ezekiel Newren via GitGitGadget wrote:
diff --git a/rust/xdiff/src/lib.rs b/rust/xdiff/src/lib.rs
index e69de29bb2d1..96975975a1ba 100644
--- a/rust/xdiff/src/lib.rs
+++ b/rust/xdiff/src/lib.rs
@@ -0,0 +1,7 @@
+
+
+#[no_mangle]
+unsafe extern "C" fn xxh3_64(ptr: *const u8, size: usize) -> u64 {
+ let slice = std::slice::from_raw_parts(ptr, size);
+ xxhash_rust::xxh3::xxh3_64(slice)
+}
I know that this is a pretty small file, but I do notice that it does not
have a license header.
This reminds me of the unfortunate oversight to be careful about making
(and keeping) libgit.a's source files compatible with libgit2's license to
nurture a fruitful exchange between those two projects.
I'm not sure I follow your reasoning here. libgit2 was started after git
and chose to use an incompatible license. I wasn't around at the time
but isn't there a list of git contributors who are happy to re-license
their contributions with the linking exception used by libgit2?
With Rust, we still have a really good chance to learn from history and
avoid that mistake: Gitoxide is a very exciting project with clear overlap
in its mission to implement Git functionality in Rust. Gitoxide is
dual-licensed under the Apache License v2 and the MIT license (see
https://github.com/GitoxideLabs/gitoxide?tab=readme-ov-file#license).
Would you mind adding a license header to that file that explicitly allows
the contents of the file to be used in Gitoxide, to get the Rust effort
started on a good foot?
I wary of that for two reasons. Firstly over time it is de-facto
re-licensing git as the amount of rust code grows and the amount of C
code shrinks which deserves a wider discussion. Secondly it makes it
harder to convert our C code which is licensed under GPL2 (or in the
case of xdiff LGPL) to rust if the rust code uses a different license.
If someone wants to start a discussion about re-licensing git (and is
prepared to do all of the associated admin in the event that it happens)
then by all means do so but I don't think it we want to slip such a
change into this series.
Thanks
Phillip