Skip to content

Conversation

@Ericson2314
Copy link
Member

Motivation

Fix #9980

Context

Upstream PR asked us ot help break chicken and egg problem by doing this here libgit2/libgit2#7149 (comment)


Add 👍 to pull requests you find important.

The Nix maintainer team uses a GitHub project board to schedule and track reviews.

@github-actions github-actions bot added the fetching Networking with the outside (non-Nix) world, input locking label Nov 9, 2025
];

postInstall = (attrs.postInstall or "") + ''
substituteInPlace $(find $dev/include -type f) --replace-quiet '#include "git2/' '#include "git2-experimental/'
Copy link
Member Author

Choose a reason for hiding this comment

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

@ethomson I don't know if this is Nixpkg's fault, or upstream libgit2's fault, but I noticed that may of the header still refer to git2/ despite the install location changing to git2-experimental.

I did this quick hack to stay unblocked and git on to the more interesting bits, bu it would be good to get that fixed upstream if it is indeed an upstream issue.

Just patch the package for now, but we should make Nixpkgs provide what
we need (whether that the experimental variant, or a 2.x release with
the new API made non-experimental) before releasing this change.
This experimental interface is likely to become stable with libgit2 2.0.
Note that for Nix-native information we should *not* do length tricks,
but instead always rely on an explicit algorithm. This hack should be
only for foreign hash literals.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

fetching Networking with the outside (non-Nix) world, input locking

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Support the sha256 git object format

1 participant