12 # The last known good firmware package to have been tested
13 # by the upstream projet.
14 # The firmware URL is hardcoded in the upstream project's installation script
15 firmwareUrl = "https://download.microsoft.com/download/F/9/9/F99791F2-D5BE-478A-B77A-830AD14950C3/KinectSDK-v1.0-beta2-x86.msi";
16 # The original URL "https://research.microsoft.com/en-us/um/legal/kinectsdk-tou_noncommercial.htm"
17 # redirects to the following url:
18 licenseUrl = "https://www.microsoft.com/en-us/legal/terms-of-use";
20 stdenv.mkDerivation rec {
21 pname = "kinect-audio-setup";
23 # On update: Make sure that the `firmwareURL` is still in sync with upstream.
24 # If the project structure hasn't changed you can find the URL in the
25 # `kinect_fetch_fw` file in the project source.
28 # This is an MSI or CAB file
29 FIRMWARE = requireFile rec {
31 sha256 = "08a2vpgd061cmc6h3h8i6qj3sjvjr1fwcnwccwywqypz3icn8xw1";
33 In order to install the Kinect Audio Firmware, you need to download the
34 non-redistributable firmware from Microsoft.
35 The firmware is available at ${firmwareUrl} and the license at ${licenseUrl} .
36 Save the file as UACFirmware and use "nix-prefetch-url file://\$PWD/UACFirmware" to
37 add it to the Nix store.
42 url = "git://git.ao2.it/kinect-audio-setup.git";
44 hash = "sha256-bFwmWh822KvFwP/0Gu097nF5K2uCwCLMB1RtP7k+Zt0=";
47 # These patches are not upstream because the project has seen no
50 ./libusb-1-import-path.patch
51 ./udev-rules-extra-devices.patch
63 "FIRMWARE_PATH=$(out)/lib/firmware/UACFirmware"
64 "LOADER_PATH=$(out)/libexec/kinect_upload_fw"
69 make -C kinect_upload_fw kinect_upload_fw $makeFlags "''${makeFlagsArray[@]}"
75 mkdir -p $out/libexec/ $out/lib/firmware $out/lib/udev/rules.d
77 install -Dm755 kinect_upload_fw/kinect_upload_fw $out/libexec/
79 # 7z extract "assume yes on all queries" "only extract/keep files/directories matching UACFIRMWARE.* recursively"
80 7z e -y -r "${FIRMWARE}" "UACFirmware.*" >/dev/null
81 # The filename is bound to change with the Firmware SDK
82 mv UACFirmware.* $out/lib/firmware/UACFirmware
84 make install_udev_rules $makeFlags "''${makeFlagsArray[@]}"
90 description = "Tools to enable audio input from the Microsoft Kinect sensor device";
91 homepage = "https://git.ao2.it/kinect-audio-setup.git";
92 maintainers = with maintainers; [ berbiche ];
93 platforms = platforms.linux;
94 license = licenses.unfree;