depot/pkgs/by-name/ne/nekoray/nekobox-core.nix
Luke Granger-Brown 57725ef3ec Squashed 'third_party/nixpkgs/' content from commit 76612b17c0ce
git-subtree-dir: third_party/nixpkgs
git-subtree-split: 76612b17c0ce71689921ca12d9ffdc9c23ce40b2
2024-11-10 23:59:47 +00:00

36 lines
819 B
Nix

{
buildGoModule,
version,
src,
extraSources,
}:
buildGoModule rec {
pname = "nekobox-core";
inherit version src;
sourceRoot = "${src.name}/go/cmd/nekobox_core";
postPatch = ''
cp -r --no-preserve=all ${extraSources.libneko} ../../../../libneko
cp -r --no-preserve=all ${extraSources.sing-box-extra} ../../../../sing-box-extra
cp -r --no-preserve=all ${extraSources.sing-box} ../../../../sing-box
cp -r --no-preserve=all ${extraSources.sing-quic} ../../../../sing-quic
'';
vendorHash = "sha256-q/Co67AwJVElJnEY2O0SLLUzwlGiqazKu+fD/nnbrTk=";
ldflags = [
"-w"
"-s"
"-X github.com/matsuridayo/libneko/neko_common.Version_neko=${version}"
];
tags = [
"with_clash_api"
"with_gvisor"
"with_quic"
"with_wireguard"
"with_utls"
"with_ech"
];
}