-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Update dependencies and package versions
- Loading branch information
Showing
7 changed files
with
124 additions
and
27 deletions.
There are no files selected for viewing
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,61 @@ | ||
{ | ||
globals, | ||
config, | ||
self', | ||
inputs', | ||
pkgs, | ||
system, | ||
... | ||
}: let | ||
recipe = { | ||
lib, | ||
fetchFromGitHub, | ||
buildGoModule, | ||
sources, | ||
platforms, | ||
}: | ||
buildGoModule rec { | ||
inherit (sources.clash-meta) pname version src; | ||
|
||
vendorHash = "sha256-tvPR5kAta4MlMTwjfxwVOacRr2nVpfalbN08mfxml64="; | ||
|
||
# Do not build testing suit | ||
excludedPackages = ["./test"]; | ||
|
||
ldflags = [ | ||
"-s" | ||
"-w" | ||
"-X github.com/MetaCubeX/mihomo/constant.Version=${version}" | ||
]; | ||
|
||
tags = [ | ||
"with_gvisor" | ||
]; | ||
|
||
# network required | ||
doCheck = false; | ||
|
||
postInstall = '' | ||
mv $out/bin/mihomo $out/bin/clash-meta | ||
''; | ||
|
||
meta = with lib; { | ||
description = "Another Clash Kernel"; | ||
homepage = "https://github.com/MetaCubeX/mihomo"; | ||
changelog = "https://github.com/MetaCubeX/mihomo/releases/tag/${version}"; | ||
license = licenses.gpl3Only; | ||
maintainers = with maintainers; [yousiki]; | ||
mainProgram = "clash-meta"; | ||
inherit platforms; | ||
}; | ||
}; | ||
|
||
sources = pkgs.callPackage (globals.root + /_sources/generated.nix) {}; | ||
|
||
platforms = import globals.inputs.default-systems; | ||
|
||
package = pkgs.callPackage recipe {inherit sources platforms;}; | ||
in | ||
if builtins.elem system platforms | ||
then package | ||
else null |
This file contains 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
This file contains 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