diff options
Diffstat (limited to 'pkgs/os-specific/linux')
9 files changed, 144 insertions, 9 deletions
diff --git a/pkgs/os-specific/linux/bluez/default.nix b/pkgs/os-specific/linux/bluez/default.nix index 6af83e4cf64..040b8fc8478 100644 --- a/pkgs/os-specific/linux/bluez/default.nix +++ b/pkgs/os-specific/linux/bluez/default.nix @@ -3,9 +3,11 @@ , fetchurl , alsa-lib , dbus +, ell , glib , json_c , libical +, docutils , pkg-config , python3 , readline @@ -19,16 +21,17 @@ ]; in stdenv.mkDerivation rec { pname = "bluez"; - version = "5.58"; + version = "5.60"; src = fetchurl { url = "mirror://kernel/linux/bluetooth/${pname}-${version}.tar.xz"; - sha256 = "1wgiv8cqya6n1w5fz24cb8q401bhn5aa6s7g95l26rzblmsmw1n8"; + sha256 = "sha256-cQmZWA0B7lnsWF5efAf9lO3e3AAaom/nRkxUb52UUwQ="; }; buildInputs = [ alsa-lib dbus + ell glib json_c libical @@ -38,6 +41,7 @@ in stdenv.mkDerivation rec { ]; nativeBuildInputs = [ + docutils pkg-config python3.pkgs.wrapPython ]; @@ -60,6 +64,7 @@ in stdenv.mkDerivation rec { "--enable-library" "--enable-cups" "--enable-pie" + "--enable-external-ell" "--with-dbusconfdir=${placeholder "out"}/share" "--with-dbussystembusdir=${placeholder "out"}/share/dbus-1/system-services" "--with-dbussessionbusdir=${placeholder "out"}/share/dbus-1/services" @@ -72,7 +77,6 @@ in stdenv.mkDerivation rec { "--enable-nfc" "--enable-sap" "--enable-sixaxis" - "--enable-wiimote" ]; # Work around `make install' trying to create /var/lib/bluetooth. diff --git a/pkgs/os-specific/linux/g15daemon/default.nix b/pkgs/os-specific/linux/g15daemon/default.nix index c670fc86d13..118a17c4c8f 100644 --- a/pkgs/os-specific/linux/g15daemon/default.nix +++ b/pkgs/os-specific/linux/g15daemon/default.nix @@ -65,7 +65,7 @@ stdenv.mkDerivation rec { patches = let patch = fname: sha256: fetchurl rec { - url = "https://git.archlinux.org/svntogit/community.git/plain/trunk/${pname}-${version}-${fname}.patch?h=packages/${pname}"; + url = "https://raw.githubusercontent.com/archlinux/svntogit-community/c0b0b6d4d6d7b79eca68123b20e0c9fb82e1c6e1/g15daemon/trunk/${pname}-${version}-${fname}.patch"; name = "${fname}.patch"; inherit sha256; }; diff --git a/pkgs/os-specific/linux/kernel/common-config.nix b/pkgs/os-specific/linux/kernel/common-config.nix index 355e653c8ea..fce451ee889 100644 --- a/pkgs/os-specific/linux/kernel/common-config.nix +++ b/pkgs/os-specific/linux/kernel/common-config.nix @@ -846,6 +846,8 @@ let X86_AMD_PLATFORM_DEVICE = yes; X86_PLATFORM_DRIVERS_DELL = whenAtLeast "5.12" yes; + LIRC = mkMerge [ (whenOlder "4.16" module) (whenAtLeast "4.17" yes) ]; + } // optionalAttrs (stdenv.hostPlatform.system == "x86_64-linux" || stdenv.hostPlatform.system == "aarch64-linux") { # Enable CPU/memory hotplug support # Allows you to dynamically add & remove CPUs/memory to a VM client running NixOS without requiring a reboot diff --git a/pkgs/os-specific/linux/kernel/manual-config.nix b/pkgs/os-specific/linux/kernel/manual-config.nix index f874762267a..fda2881a8d2 100644 --- a/pkgs/os-specific/linux/kernel/manual-config.nix +++ b/pkgs/os-specific/linux/kernel/manual-config.nix @@ -119,7 +119,7 @@ let # This way kernels can be bit-by-bit reproducible depending on settings # (e.g. MODULE_SIG and SECURITY_LOCKDOWN_LSM need to be disabled). # See also https://kernelnewbies.org/BuildId - sed -i Makefile -e 's|--build-id|--build-id=none|' + sed -i Makefile -e 's|--build-id=[^ ]*|--build-id=none|' patchShebangs scripts/ld-version.sh ''; diff --git a/pkgs/os-specific/linux/kinect-audio-setup/default.nix b/pkgs/os-specific/linux/kinect-audio-setup/default.nix new file mode 100644 index 00000000000..94ae4806cf2 --- /dev/null +++ b/pkgs/os-specific/linux/kinect-audio-setup/default.nix @@ -0,0 +1,91 @@ +{ lib +, stdenv +, fetchgit +, requireFile +, pkg-config +, libusb1 +, p7zip +}: + +let + # The last known good firmware package to have been tested + # by the upstream projet. + # The firmware URL is hardcoded in the upstream project's installation script + firmwareUrl = "https://download.microsoft.com/download/F/9/9/F99791F2-D5BE-478A-B77A-830AD14950C3/KinectSDK-v1.0-beta2-x86.msi"; + # The original URL "https://research.microsoft.com/en-us/um/legal/kinectsdk-tou_noncommercial.htm" + # redirects to the following url: + licenseUrl = "https://www.microsoft.com/en-us/legal/terms-of-use"; +in +stdenv.mkDerivation rec { + pname = "kinect-audio-setup"; + + # On update: Make sure that the `firmwareURL` is still in sync with upstream. + # If the project structure hasn't changed you can find the URL in the + # `kinect_fetch_fw` file in the project source. + version = "0.5"; + + # This is an MSI or CAB file + FIRMWARE = requireFile rec { + name = "UACFirmware"; + sha256 = "08a2vpgd061cmc6h3h8i6qj3sjvjr1fwcnwccwywqypz3icn8xw1"; + message = '' + In order to install the Kinect Audio Firmware, you need to download the + non-redistributable firmware from Microsoft. + The firmware is available at ${firmwareUrl} and the license at ${licenseUrl} . + Save the file as UACFirmware and use "nix-prefetch-url file://\$PWD/UACFirmware" to + add it to the Nix store. + ''; + }; + + src = fetchgit { + url = "git://git.ao2.it/kinect-audio-setup.git"; + rev = "v${version}"; + sha256 = "sha256-bFwmWh822KvFwP/0Gu097nF5K2uCwCLMB1RtP7k+Zt0="; + }; + + # These patches are not upstream because the project has seen no + # activity since 2016 + patches = [ + ./libusb-1-import-path.patch + ./udev-rules-extra-devices.patch + ]; + + nativeBuildInputs = [ p7zip libusb1 pkg-config ]; + + makeFlags = [ + "PREFIX=$(out)" + "DESTDIR=$(out)" + "FIRMWARE_PATH=$(out)/lib/firmware/UACFirmware" + "LOADER_PATH=$(out)/libexec/kinect_upload_fw" + ]; + + buildPhase = '' + runHook preBuild + make -C kinect_upload_fw kinect_upload_fw $makeFlags "''${makeFlagsArray[@]}" + runHook postBuild + ''; + + installPhase = '' + runHook preInstall + mkdir -p $out/libexec/ $out/lib/firmware $out/lib/udev/rules.d + + install -Dm755 kinect_upload_fw/kinect_upload_fw $out/libexec/ + + # 7z extract "assume yes on all queries" "only extract/keep files/directories matching UACFIRMWARE.* recursively" + 7z e -y -r "${FIRMWARE}" "UACFirmware.*" >/dev/null + # The filename is bound to change with the Firmware SDK + mv UACFirmware.* $out/lib/firmware/UACFirmware + + make install_udev_rules $makeFlags "''${makeFlagsArray[@]}" + + runHook postInstall + ''; + + meta = with lib; { + description = "Tools to enable audio input from the Microsoft Kinect sensor device"; + homepage = "https://git.ao2.it/kinect-audio-setup.git"; + maintainers = with maintainers; [ berbiche ]; + platforms = platforms.linux; + license = licenses.unfree; + }; +} diff --git a/pkgs/os-specific/linux/kinect-audio-setup/libusb-1-import-path.patch b/pkgs/os-specific/linux/kinect-audio-setup/libusb-1-import-path.patch new file mode 100644 index 00000000000..a0c5ad99f9f --- /dev/null +++ b/pkgs/os-specific/linux/kinect-audio-setup/libusb-1-import-path.patch @@ -0,0 +1,23 @@ +commit 02fd6c4355809e1bff7c66d478e88f30bedde13b +Author: Nicolas Berbiche <nicolas@normie.dev> +Date: Wed May 5 23:14:56 2021 -0400 + + fix libusb include for Linux + +diff --git a/kinect_upload_fw/kinect_upload_fw.c b/kinect_upload_fw/kinect_upload_fw.c +index 1bd4102..351c94f 100644 +--- a/kinect_upload_fw/kinect_upload_fw.c ++++ b/kinect_upload_fw/kinect_upload_fw.c +@@ -35,7 +35,12 @@ + #include <stdlib.h> + #include <string.h> + #include <errno.h> ++ ++#if defined(__FreeBSD__) || defined(__NetBSD__) || defined(_WIN32) + #include <libusb.h> ++#else ++#include <libusb-1.0/libusb.h> ++#endif + + #include "endian.h" + diff --git a/pkgs/os-specific/linux/kinect-audio-setup/udev-rules-extra-devices.patch b/pkgs/os-specific/linux/kinect-audio-setup/udev-rules-extra-devices.patch new file mode 100644 index 00000000000..d58b970c7c0 --- /dev/null +++ b/pkgs/os-specific/linux/kinect-audio-setup/udev-rules-extra-devices.patch @@ -0,0 +1,15 @@ +commit afaaa77b0a03811f86428cf264397b60dd795549 +Author: Nicolas Berbiche <nicolas@normie.dev> +Date: Thu May 6 00:10:37 2021 -0400 + + Add support for other Kinect device in udev + +diff --git a/contrib/55-kinect_audio.rules.in b/contrib/55-kinect_audio.rules.in +index 25ea713..9e1b69f 100644 +--- a/contrib/55-kinect_audio.rules.in ++++ b/contrib/55-kinect_audio.rules.in +@@ -1,2 +1,4 @@ + # Rule to load the Kinect UAC firmware on the "generic" usb device + ACTION=="add", SUBSYSTEMS=="usb", ATTRS{idVendor}=="045e", ATTRS{idProduct}=="02ad", RUN+="@LOADER_PATH@ @FIRMWARE_PATH@" ++# Rule to load the Kinect UAC firmware on another supported device ++ACTION=="add", SUBSYSTEMS=="usb", ATTRS{idVendor}=="045e", ATTRS{idProduct}=="02bb", RUN+="@LOADER_PATH@ @FIRMWARE_PATH@" diff --git a/pkgs/os-specific/linux/linuxptp/default.nix b/pkgs/os-specific/linux/linuxptp/default.nix index 4f58c9f3f2a..4c14d2ecae3 100644 --- a/pkgs/os-specific/linux/linuxptp/default.nix +++ b/pkgs/os-specific/linux/linuxptp/default.nix @@ -3,11 +3,11 @@ stdenv.mkDerivation rec { pname = "linuxptp"; - version = "3.1"; + version = "3.1.1"; src = fetchurl { url = "mirror://sourceforge/linuxptp/${pname}-${version}.tgz"; - sha256 = "0zff502w3nlycgv2ad8cy8nd0hqf34kzpzcygi7prp0lrw8mp3zm"; + sha256 = "1nf0w4xyzg884v8blb81zkk6q8p6zbiq9lx61jdqwbbzkdgqbmll"; }; postPatch = '' diff --git a/pkgs/os-specific/linux/syslinux/default.nix b/pkgs/os-specific/linux/syslinux/default.nix index 0f69cb13fcd..4ca7f50b7d1 100644 --- a/pkgs/os-specific/linux/syslinux/default.nix +++ b/pkgs/os-specific/linux/syslinux/default.nix @@ -23,12 +23,12 @@ stdenv.mkDerivation { sha256 = "06ifgzbpjj4picpj17zgprsfi501zf4pp85qjjgn29i5rs291zni"; }) (fetchurl { - url = "https://git.archlinux.org/svntogit/packages.git/plain/trunk/0005-gnu-efi-version-compatibility.patch?id=821c3da473d1399d930d5b4a086e46a4179eaa45"; + url = "https://raw.githubusercontent.com/archlinux/svntogit-packages/821c3da473d1399d930d5b4a086e46a4179eaa45/trunk/0005-gnu-efi-version-compatibility.patch"; name = "0005-gnu-efi-version-compatibility.patch"; sha256 = "1mz2idg8cwn0mvd3jixxynhkn7rhmi5fp8cc8zznh5f0ysfra446"; }) (fetchurl { - url = "https://git.archlinux.org/svntogit/packages.git/plain/trunk/0025-reproducible-build.patch?id=821c3da473d1399d930d5b4a086e46a4179eaa45"; + url = "https://raw.githubusercontent.com/archlinux/svntogit-packages/821c3da473d1399d930d5b4a086e46a4179eaa45/trunk/0025-reproducible-build.patch"; name = "0025-reproducible-build.patch"; sha256 = "0qk6wc6z3648828y3961pn4pi7xhd20a6fqn6z1mnj22bbvzcxls"; }) |