From 648bb304871bb8f477200a343be66b667cb17cde Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Christian=20K=C3=B6gler?= Date: Sat, 30 Dec 2023 22:16:41 +0100 Subject: [PATCH] linux.tbs: 2018.04.18 -> 20231210 --- pkgs/os-specific/linux/tbs/default.nix | 31 ++++++++++++++++---------- 1 file changed, 19 insertions(+), 12 deletions(-) diff --git a/pkgs/os-specific/linux/tbs/default.nix b/pkgs/os-specific/linux/tbs/default.nix index 54268693454c..5805a400c1e2 100644 --- a/pkgs/os-specific/linux/tbs/default.nix +++ b/pkgs/os-specific/linux/tbs/default.nix @@ -1,31 +1,38 @@ -{ stdenv, lib, fetchFromGitHub, kernel, kmod, perl, patchutils, perlPackages }: +{ stdenv, lib, fetchFromGitHub, kernel, kmod, patchutils, perlPackages }: let media = fetchFromGitHub rec { name = repo; owner = "tbsdtv"; repo = "linux_media"; - rev = "efe31531b77efd3a4c94516504a5823d31cdc776"; - sha256 = "1533qi3sb91v00289hl5zaj4l35r2sf9fqc6z5ky1vbb7byxgnlr"; + rev = "d0a7e44358f28064697e0eed309db03166dcd83b"; + hash = "sha256-BTHlnta5qv2bdPjD2bButwYGpwR/bq99/AUoZqTHHYw="; }; build = fetchFromGitHub rec { name = repo; owner = "tbsdtv"; repo = "media_build"; - rev = "a0d62eba4d429e0e9d2c2f910fb203e817cac84b"; - sha256 = "1329s7w9xlqjqwkpaqsd6b5dmzhm97jw0c7c7zzmmbdkl289i4i4"; + rev = "88764363a3e3d36b3c59a0a2bf2244e262035d47"; + hash = "sha256-LFTxYVPudflxqYTSBIDNkTrGs09MOuYBXwpGYqWfEFQ="; }; -in stdenv.mkDerivation { +in +stdenv.mkDerivation { pname = "tbs"; - version = "2018.04.18-${kernel.version}"; + version = "20231210-${kernel.version}"; srcs = [ media build ]; sourceRoot = build.name; + # https://github.com/tbsdtv/linux_media/wiki preConfigure = '' make dir DIR=../${media.name} + make allyesconfig + sed --regexp-extended --in-place v4l/.config \ + -e 's/(^CONFIG.*_RC.*=)./\1n/g' \ + -e 's/(^CONFIG.*_IR.*=)./\1n/g' \ + -e 's/(^CONFIG_VIDEO_VIA_CAMERA=)./\1n/g' ''; postPatch = '' @@ -44,12 +51,12 @@ in stdenv.mkDerivation { buildFlags = [ "VER=${kernel.modDirVersion}" ]; installFlags = [ "DESTDIR=$(out)" ]; - hardeningDisable = [ "all" ]; + hardeningDisable = [ "pic" ]; - nativeBuildInputs = [ patchutils kmod perl perlPackages.ProcProcessTable ] - ++ kernel.moduleBuildDependencies; + nativeBuildInputs = [ patchutils kmod perlPackages.ProcProcessTable ] + ++ kernel.moduleBuildDependencies; - postInstall = '' + postInstall = '' find $out/lib/modules/${kernel.modDirVersion} -name "*.ko" -exec xz {} \; ''; @@ -59,6 +66,6 @@ in stdenv.mkDerivation { license = licenses.gpl2; maintainers = with maintainers; [ ck3d ]; priority = -1; - broken = true; + broken = kernel.kernelOlder "4.14" || kernel.kernelAtLeast "6.6"; }; }