diff options
Diffstat (limited to 'pkgs/os-specific/linux')
-rw-r--r-- | pkgs/os-specific/linux/firmware/firmware-manager/default.nix | 38 | ||||
-rw-r--r-- | pkgs/os-specific/linux/firmware/system76-firmware/default.nix | 39 | ||||
-rw-r--r-- | pkgs/os-specific/linux/kernel/linux-4.14.nix | 4 | ||||
-rw-r--r-- | pkgs/os-specific/linux/kernel/linux-4.19.nix | 4 | ||||
-rw-r--r-- | pkgs/os-specific/linux/kernel/linux-4.4.nix | 4 | ||||
-rw-r--r-- | pkgs/os-specific/linux/kernel/linux-4.9.nix | 4 | ||||
-rw-r--r-- | pkgs/os-specific/linux/kernel/linux-5.4.nix | 4 | ||||
-rw-r--r-- | pkgs/os-specific/linux/kernel/linux-5.8.nix | 4 | ||||
-rw-r--r-- | pkgs/os-specific/linux/system76-acpi/default.nix | 43 | ||||
-rw-r--r-- | pkgs/os-specific/linux/system76-io/default.nix | 38 | ||||
-rw-r--r-- | pkgs/os-specific/linux/system76/default.nix | 44 |
11 files changed, 214 insertions, 12 deletions
diff --git a/pkgs/os-specific/linux/firmware/firmware-manager/default.nix b/pkgs/os-specific/linux/firmware/firmware-manager/default.nix new file mode 100644 index 0000000000000..e98de6bbe9e8e --- /dev/null +++ b/pkgs/os-specific/linux/firmware/firmware-manager/default.nix @@ -0,0 +1,38 @@ +{ rustPlatform, lib, fetchFromGitHub, lzma, pkgconfig, openssl, dbus, glib, udev, cairo, pango, atk, gdk-pixbuf, gtk3, wrapGAppsHook }: +rustPlatform.buildRustPackage rec { + pname = "firmware-manager"; + version = "0.1.1"; + + src = fetchFromGitHub { + owner = "pop-os"; + repo = pname; + rev = version; + sha256 = "0x9604jsflqxvbkfp139mzjicpyx8v21139jj8bp88c14ngvmdlw"; + }; + + nativeBuildInputs = [ pkgconfig wrapGAppsHook ]; + + buildInputs = [ lzma openssl dbus glib udev cairo pango atk gdk-pixbuf gtk3 ]; + + depsExtraArgs.postPatch = "make prefix='$(out)' toml-gen"; + + postPatch = '' + sed -i 's|etc|$(prefix)/etc|' Makefile + ''; + + buildPhase = "make prefix='$(out)'"; + + installPhase = "make prefix='$(out)' install"; + + cargoSha256 = "0byc0pqa1w2qnfrx3psrzdq1c8qjslbmzxg872b9v6fr5d4c9cvg"; + + doCheck = false; + + meta = { + description = "Graphical frontend for firmware management"; + homepage = "https://github.com/pop-os/firmware-manager"; + license = lib.licenses.gpl3; + maintainers = [ lib.maintainers.shlevy ]; + platforms = lib.platforms.linux; + }; +} diff --git a/pkgs/os-specific/linux/firmware/system76-firmware/default.nix b/pkgs/os-specific/linux/firmware/system76-firmware/default.nix new file mode 100644 index 0000000000000..40598abac9211 --- /dev/null +++ b/pkgs/os-specific/linux/firmware/system76-firmware/default.nix @@ -0,0 +1,39 @@ +{ rustPlatform, lib, fetchFromGitHub, lzma, pkgconfig, openssl, dbus, efibootmgr, makeWrapper }: +rustPlatform.buildRustPackage rec { + pname = "system76-firmware"; + # Check Makefile when updating, make sure postInstall matches make install + version = "1.0.17"; + + src = fetchFromGitHub { + owner = "pop-os"; + repo = pname; + rev = version; + sha256 = "0cnrskfk3sam90lfpgsraqs4bx9yz8rxhwfs8rxdri04lakxgghg"; + }; + + nativeBuildInputs = [ pkgconfig makeWrapper ]; + + buildInputs = [ lzma openssl dbus ]; + + cargoBuildFlags = [ "--workspace" ]; + + cargoSha256 = "06jrmxy68glcmbn9px29wc0s8pqdn26iy4jn3c246dapv1zvbb4s"; + + # Purposefully don't install systemd unit file, that's for NixOS + postInstall = '' + install -D -m -0644 data/system76-firmware-daemon.conf $out/etc/dbus-1/system.d/system76-firmware-daemon.conf + + for bin in $out/bin/system76-firmware-* + do + wrapProgram $bin --prefix PATH : "${efibootmgr}/bin" + done + ''; + + meta = { + description = "Tools for managing firmware updates for system76 devices."; + homepage = "https://github.com/pop-os/system76-firmware"; + license = lib.licenses.gpl3; + maintainers = [ lib.maintainers.shlevy ]; + platforms = lib.platforms.linux; + }; +} diff --git a/pkgs/os-specific/linux/kernel/linux-4.14.nix b/pkgs/os-specific/linux/kernel/linux-4.14.nix index 58721a2a6427a..e0c370c59466b 100644 --- a/pkgs/os-specific/linux/kernel/linux-4.14.nix +++ b/pkgs/os-specific/linux/kernel/linux-4.14.nix @@ -3,7 +3,7 @@ with stdenv.lib; buildLinux (args // rec { - version = "4.14.198"; + version = "4.14.199"; # modDirVersion needs to be x.y.z, will automatically add .0 if needed modDirVersion = if (modDirVersionArg == null) then concatStringsSep "." (take 3 (splitVersion "${version}.0")) else modDirVersionArg; @@ -13,6 +13,6 @@ buildLinux (args // rec { src = fetchurl { url = "mirror://kernel/linux/kernel/v4.x/linux-${version}.tar.xz"; - sha256 = "00xmij2l4qmx1s07hplxkn9ddlwiyalh2l5fqdk6d8v031cbmyhy"; + sha256 = "1yflafb0n783igghk6d392pk6lbk3p2w7y01ams08f1b4qm47wq2"; }; } // (args.argsOverride or {})) diff --git a/pkgs/os-specific/linux/kernel/linux-4.19.nix b/pkgs/os-specific/linux/kernel/linux-4.19.nix index d50535e5d3289..aebded8cb7390 100644 --- a/pkgs/os-specific/linux/kernel/linux-4.19.nix +++ b/pkgs/os-specific/linux/kernel/linux-4.19.nix @@ -3,7 +3,7 @@ with stdenv.lib; buildLinux (args // rec { - version = "4.19.146"; + version = "4.19.147"; # modDirVersion needs to be x.y.z, will automatically add .0 if needed modDirVersion = if (modDirVersionArg == null) then concatStringsSep "." (take 3 (splitVersion "${version}.0")) else modDirVersionArg; @@ -13,6 +13,6 @@ buildLinux (args // rec { src = fetchurl { url = "mirror://kernel/linux/kernel/v4.x/linux-${version}.tar.xz"; - sha256 = "0jl17yk3fpz0sx203l9l1fj5bly3jgsyr8hy5qa6py99fbk0qnim"; + sha256 = "19nnx61v7c0102ik1rjan0kdsj8av8v7iqz5vm3v3kjllmjmvr2x"; }; } // (args.argsOverride or {})) diff --git a/pkgs/os-specific/linux/kernel/linux-4.4.nix b/pkgs/os-specific/linux/kernel/linux-4.4.nix index 937149c571c73..c6f9b6ddb47c5 100644 --- a/pkgs/os-specific/linux/kernel/linux-4.4.nix +++ b/pkgs/os-specific/linux/kernel/linux-4.4.nix @@ -1,11 +1,11 @@ { stdenv, buildPackages, fetchurl, perl, buildLinux, ... } @ args: buildLinux (args // rec { - version = "4.4.236"; + version = "4.4.237"; extraMeta.branch = "4.4"; src = fetchurl { url = "mirror://kernel/linux/kernel/v4.x/linux-${version}.tar.xz"; - sha256 = "1v1mx16x1crnxf4pix0bhw40lq89n7wpd66gjc2mhxi75h6x6i80"; + sha256 = "1q6hwjwvlsikgr8b04l7v2jia2wyqxgbli6i7y20aq49h13ap2qk"; }; } // (args.argsOverride or {})) diff --git a/pkgs/os-specific/linux/kernel/linux-4.9.nix b/pkgs/os-specific/linux/kernel/linux-4.9.nix index 116e40fed7822..c6d29d2d8a521 100644 --- a/pkgs/os-specific/linux/kernel/linux-4.9.nix +++ b/pkgs/os-specific/linux/kernel/linux-4.9.nix @@ -1,11 +1,11 @@ { stdenv, buildPackages, fetchurl, perl, buildLinux, ... } @ args: buildLinux (args // rec { - version = "4.9.236"; + version = "4.9.237"; extraMeta.branch = "4.9"; src = fetchurl { url = "mirror://kernel/linux/kernel/v4.x/linux-${version}.tar.xz"; - sha256 = "1ma2z0nvby4qyxzi3vxa28f0wvlnl74njk6cryjrqaksq6161qp7"; + sha256 = "07w6mwgh7i3bvg1w3w5i9kgxjmvqr7cv7nzrmx7j9p6cq295gv41"; }; } // (args.argsOverride or {})) diff --git a/pkgs/os-specific/linux/kernel/linux-5.4.nix b/pkgs/os-specific/linux/kernel/linux-5.4.nix index 90f191c3681b6..046007c58e64f 100644 --- a/pkgs/os-specific/linux/kernel/linux-5.4.nix +++ b/pkgs/os-specific/linux/kernel/linux-5.4.nix @@ -3,7 +3,7 @@ with stdenv.lib; buildLinux (args // rec { - version = "5.4.66"; + version = "5.4.67"; # modDirVersion needs to be x.y.z, will automatically add .0 if needed modDirVersion = if (modDirVersionArg == null) then concatStringsSep "." (take 3 (splitVersion "${version}.0")) else modDirVersionArg; @@ -13,6 +13,6 @@ buildLinux (args // rec { src = fetchurl { url = "mirror://kernel/linux/kernel/v5.x/linux-${version}.tar.xz"; - sha256 = "1cnsrz21kcf0h7krpv9p1a7n59mybr5ii0jdi3yc3x3lcwvk06gz"; + sha256 = "196avi0950qrd0lxdpdsl6lxa51f20sz476mcl1i5islbnfbsxf1"; }; } // (args.argsOverride or {})) diff --git a/pkgs/os-specific/linux/kernel/linux-5.8.nix b/pkgs/os-specific/linux/kernel/linux-5.8.nix index 14abb483eee71..d9567b20e03e4 100644 --- a/pkgs/os-specific/linux/kernel/linux-5.8.nix +++ b/pkgs/os-specific/linux/kernel/linux-5.8.nix @@ -3,7 +3,7 @@ with stdenv.lib; buildLinux (args // rec { - version = "5.8.10"; + version = "5.8.11"; # modDirVersion needs to be x.y.z, will automatically add .0 if needed modDirVersion = if (modDirVersionArg == null) then concatStringsSep "." (take 3 (splitVersion "${version}.0")) else modDirVersionArg; @@ -13,6 +13,6 @@ buildLinux (args // rec { src = fetchurl { url = "mirror://kernel/linux/kernel/v5.x/linux-${version}.tar.xz"; - sha256 = "1wjsdc93xilag0pk205m2q0ixmpp93ql5qj0fm3qlqddgxm14vlx"; + sha256 = "0jy0yrrixzql9dlk9305w98pja2pm6ijrdbai326595pnk740n9y"; }; } // (args.argsOverride or {})) diff --git a/pkgs/os-specific/linux/system76-acpi/default.nix b/pkgs/os-specific/linux/system76-acpi/default.nix new file mode 100644 index 0000000000000..b7c0e27669da4 --- /dev/null +++ b/pkgs/os-specific/linux/system76-acpi/default.nix @@ -0,0 +1,43 @@ +{ stdenv, fetchFromGitHub, kernel }: +let + version = "1.0.1"; + sha256 = "0jmm9h607f7k20yassm6af9mh5l00yih5248wwv4i05bd68yw3p5"; +in +stdenv.mkDerivation { + name = "system76-acpi-module-${version}-${kernel.version}"; + + passthru.moduleName = "system76_acpi"; + + src = fetchFromGitHub { + owner = "pop-os"; + repo = "system76-acpi-dkms"; + rev = version; + inherit sha256; + }; + + hardeningDisable = [ "pic" ]; + + nativeBuildInputs = kernel.moduleBuildDependencies; + + buildFlags = [ + "KERNEL_DIR=${kernel.dev}/lib/modules/${kernel.modDirVersion}/build" + ]; + + installPhase = '' + install -D system76_acpi.ko $out/lib/modules/${kernel.modDirVersion}/misc/system76_acpi.ko + mkdir -p $out/lib/udev/hwdb.d + mv lib/udev/hwdb.d/* $out/lib/udev/hwdb.d + ''; + + meta = with stdenv.lib; { + maintainers = [ maintainers.khumba ]; + license = [ licenses.gpl2Only ]; + platforms = [ "i686-linux" "x86_64-linux" ]; + broken = versionOlder kernel.version "4.14"; + description = "System76 ACPI Driver (DKMS)"; + homepage = "https://github.com/pop-os/system76-acpi-dkms"; + longDescription = '' + This provides the system76_acpi in-tree driver for systems missing it. + ''; + }; +} diff --git a/pkgs/os-specific/linux/system76-io/default.nix b/pkgs/os-specific/linux/system76-io/default.nix new file mode 100644 index 0000000000000..dac1e2db1e383 --- /dev/null +++ b/pkgs/os-specific/linux/system76-io/default.nix @@ -0,0 +1,38 @@ +{ stdenv, fetchFromGitHub, kernel }: +let + version = "1.0.1"; + sha256 = "0qkgkkjy1isv6ws6hrcal75dxjz98rpnvqbm7agdcc6yv0c17wwh"; +in +stdenv.mkDerivation { + name = "system76-io-module-${version}-${kernel.version}"; + + passthru.moduleName = "system76_io"; + + src = fetchFromGitHub { + owner = "pop-os"; + repo = "system76-io-dkms"; + rev = version; + inherit sha256; + }; + + hardeningDisable = [ "pic" ]; + + nativeBuildInputs = kernel.moduleBuildDependencies; + + buildFlags = [ + "KERNEL_DIR=${kernel.dev}/lib/modules/${kernel.modDirVersion}/build" + ]; + + installPhase = '' + install -D system76-io.ko $out/lib/modules/${kernel.modDirVersion}/misc/system76-io.ko + ''; + + meta = with stdenv.lib; { + maintainers = [ maintainers.khumba ]; + license = [ licenses.gpl2Plus ]; + platforms = [ "i686-linux" "x86_64-linux" ]; + broken = versionOlder kernel.version "4.14"; + description = "DKMS module for controlling System76 I/O board"; + homepage = "https://github.com/pop-os/system76-io-dkms"; + }; +} diff --git a/pkgs/os-specific/linux/system76/default.nix b/pkgs/os-specific/linux/system76/default.nix new file mode 100644 index 0000000000000..02eca1d5bbd57 --- /dev/null +++ b/pkgs/os-specific/linux/system76/default.nix @@ -0,0 +1,44 @@ +{ stdenv, fetchFromGitHub, kernel }: +let + version = "1.0.9"; + sha256 = "0i4825y2vd679kdjv30ifzj1i1066d3x37z4lgk39hx16993k162"; +in +stdenv.mkDerivation { + name = "system76-module-${version}-${kernel.version}"; + + passthru.moduleName = "system76"; + + src = fetchFromGitHub { + owner = "pop-os"; + repo = "system76-dkms"; + rev = version; + inherit sha256; + }; + + hardeningDisable = [ "pic" ]; + + nativeBuildInputs = kernel.moduleBuildDependencies; + + buildFlags = [ + "KERNEL_DIR=${kernel.dev}/lib/modules/${kernel.modDirVersion}/build" + ]; + + installPhase = '' + install -D system76.ko $out/lib/modules/${kernel.modDirVersion}/misc/system76.ko + mkdir -p $out/lib/udev/hwdb.d + mv lib/udev/hwdb.d/* $out/lib/udev/hwdb.d + ''; + + meta = with stdenv.lib; { + maintainers = [ maintainers.khumba ]; + license = [ licenses.gpl2Plus ]; + platforms = [ "i686-linux" "x86_64-linux" ]; + broken = versionOlder kernel.version "4.14"; + description = "System76 DKMS driver"; + homepage = "https://github.com/pop-os/system76-dkms"; + longDescription = '' + The System76 DKMS driver. On newer System76 laptops, this driver controls + some of the hotkeys and allows for custom fan control. + ''; + }; +} |