wireguard-go: 0.0.20230223 -> 0.0.20250522 and refactorings (#440959)

This commit is contained in:
Maximilian Bosch
2025-11-15 17:30:10 +00:00
committed by GitHub

View File

@@ -9,27 +9,23 @@
buildGoModule ( buildGoModule (
finalAttrs: finalAttrs:
let let
rev = "12269c2761734b15625017d8565745096325392f"; version = "0.0.20250522";
shortVer = "${finalAttrs.version} (${lib.substring 0 7 rev})";
in in
{ {
pname = "wireguard-go"; pname = "wireguard-go";
version = "0-unstable-2023-12-11"; inherit version;
src = fetchzip { src = fetchzip {
url = "https://git.zx2c4.com/wireguard-go/snapshot/wireguard-go-${rev}.tar.xz"; url = "https://git.zx2c4.com/wireguard-go/snapshot/wireguard-go-${version}.tar.xz";
hash = "sha256-br7/dwr/e4HvBGJXh+6lWqxBUezt5iZNy9BFqEA1bLk="; hash = "sha256-GRr8NKKb4SHd0WxmNL84eiofFHcauDDmSyNNrXermcA=";
}; };
postPatch = '' postPatch = ''
# Skip formatting tests # Skip formatting tests
rm -f format_test.go rm -f format_test.go
# Inject version
printf 'package main\n\nconst Version = "${shortVer}"' > version.go
''; '';
vendorHash = "sha256-RqZ/3+Xus5N1raiUTUpiKVBs/lrJQcSwr1dJib2ytwc="; vendorHash = "sha256-sCajxTV26jjlmgmbV4GG6hg9NkLGS773ZbFyKucvuBE=";
subPackages = [ "." ]; subPackages = [ "." ];
@@ -56,7 +52,7 @@ buildGoModule (
passthru.tests.version = testers.testVersion { passthru.tests.version = testers.testVersion {
package = wireguard-go; package = wireguard-go;
version = "v${shortVer}"; version = "v${version}";
}; };
meta = with lib; { meta = with lib; {