From c794e90ebba22dc6b6f7840702288dbdf2fceefe Mon Sep 17 00:00:00 2001 From: alper-han <89567766+alper-han@users.noreply.github.com> Date: Fri, 28 Feb 2025 16:35:31 +0300 Subject: [PATCH] linuxPackages.r8125: 9.014.01 -> 9.015.00 The package has been updated to use the debian repo. Signed-off-by: John Titor <50095635+JohnRTitor@users.noreply.github.com> --- pkgs/os-specific/linux/r8125/default.nix | 41 +++++++++++------------- 1 file changed, 18 insertions(+), 23 deletions(-) diff --git a/pkgs/os-specific/linux/r8125/default.nix b/pkgs/os-specific/linux/r8125/default.nix index 3b2bdb45e812..71d34528657d 100644 --- a/pkgs/os-specific/linux/r8125/default.nix +++ b/pkgs/os-specific/linux/r8125/default.nix @@ -1,24 +1,20 @@ { stdenv, lib, - fetchFromGitHub, + fetchFromGitLab, kernel, }: stdenv.mkDerivation rec { pname = "r8125"; - # On update please verify (using `diff -r`) that the source matches the - # realtek version. - version = "9.014.01"; + version = "9.015.00"; - # This is a mirror. The original website[1] doesn't allow non-interactive - # downloads, instead emailing you a download link. - # [1] https://www.realtek.com/en/component/zoo/category/network-interface-controllers-10-100-1000m-gigabit-ethernet-pci-express-software - src = fetchFromGitHub { - owner = "louistakepillz"; + src = fetchFromGitLab { + domain = "salsa.debian.org"; + owner = "debian"; repo = "r8125"; - rev = version; - sha256 = "sha256-vYgAOmKFQZDKrZsS3ynXB0DrT3wU0JWzNTYO6FyMG9M="; + rev = "upstream/${version}"; + sha256 = "sha256-RA7rvvF2Ngeu+hSACBbKfAJgLbPqhaXG14DH2NmztTE="; }; hardeningDisable = [ "pic" ]; @@ -36,17 +32,16 @@ stdenv.mkDerivation rec { buildFlags = [ "modules" ]; - meta = with lib; { - homepage = "https://github.com/louistakepillz/r8125"; - downloadPage = "https://www.realtek.com/en/component/zoo/category/network-interface-controllers-10-100-1000m-gigabit-ethernet-pci-express-software"; - description = "Realtek r8125 driver"; - longDescription = '' - A kernel module for Realtek 8125 2.5G network cards. - ''; - # r8125 has been integrated into the kernel as of v5.9.1 - broken = lib.versionAtLeast kernel.version "5.9.1"; - license = licenses.gpl2Plus; - platforms = platforms.linux; - maintainers = with maintainers; [ peelz ]; + installPhase = '' + mkdir -p $out/lib/modules/${kernel.modDirVersion}/kernel/drivers/net/ethernet/realtek + cp src/r8125.ko $out/lib/modules/${kernel.modDirVersion}/kernel/drivers/net/ethernet/realtek/ + ''; + + meta = { + homepage = "https://salsa.debian.org/debian/r8125"; + description = "Realtek r8125 2.5G Ethernet driver"; + license = lib.licenses.gpl2Plus; + platforms = lib.platforms.linux; + maintainers = [ lib.maintainers.peelz ]; }; }