linuxPackages.amneziawg: init at 1.0.20240711

This commit is contained in:
AveryanAlex 2024-08-01 23:34:17 +03:00
parent 4c97b427ec
commit 45c4b954af
No known key found for this signature in database
GPG Key ID: 3C23C7BD99452036
2 changed files with 53 additions and 0 deletions

View File

@ -0,0 +1,51 @@
{
lib,
stdenv,
fetchFromGitHub,
srcOnly,
kernel,
nix-update-script,
}:
stdenv.mkDerivation (finalAttrs: {
pname = "amneziawg";
version = "1.0.20240711";
src = fetchFromGitHub {
owner = "amnezia-vpn";
repo = "amneziawg-linux-kernel-module";
rev = "refs/tags/v${finalAttrs.version}";
hash = "sha256-WOcBTxetVz2Sr62c+2aGNyohG2ydi+R+az+4qHbKprI=";
};
sourceRoot = "${finalAttrs.src.name}/src";
hardeningDisable = [ "pic" ];
nativeBuildInputs = kernel.moduleBuildDependencies;
buildFlags = [
"apply-patches"
"module"
];
makeFlags =
kernel.makeFlags
++ [ "KERNELDIR=${kernel.dev}/lib/modules/${kernel.modDirVersion}/build" ]
++ lib.optional (lib.versionAtLeast kernel.version "5.6") "KERNEL_SOURCE_DIR=${srcOnly kernel}";
enableParallelBuilding = true;
installFlags = [
"DEPMOD=true"
"INSTALL_MOD_PATH=${placeholder "out"}"
];
passthru.updateScript = nix-update-script { };
meta = {
description = "Kernel module for the AmneziaWG";
homepage = "https://amnezia.org";
license = lib.licenses.gpl2Only;
maintainers = with lib.maintainers; [ averyanalex ];
platforms = lib.platforms.linux;
};
})

View File

@ -321,6 +321,8 @@ in {
akvcam = callPackage ../os-specific/linux/akvcam { };
amneziawg = callPackage ../os-specific/linux/amneziawg { };
apfs = callPackage ../os-specific/linux/apfs { };
ax99100 = callPackage ../os-specific/linux/ax99100 {};