Files
2026-06-17 14:34:09 +00:00

57 lines
1.4 KiB
Nix

{
stdenv,
lib,
fetchFromGitHub,
kernel,
kernelModuleMakeFlags,
}:
stdenv.mkDerivation rec {
name = "${pname}-${version}-${kernel.version}";
pname = "facetimehd";
version = "0.7.0.2";
# Note: When updating this revision:
# 1. Also update pkgs/os-specific/linux/firmware/facetimehd-firmware/
# 2. Test the module and firmware change via:
# a. Give some applications a try (Skype, Hangouts, Cheese, etc.)
# b. Run: journalctl -f
# c. Then close the lid
# d. Then open the lid (and maybe press a key to wake it up)
# e. see if the module loads back (apps using the camera won't
# recover and will have to be restarted) and the camera
# still works.
src = fetchFromGitHub {
owner = "patjak";
repo = "facetimehd";
rev = version;
sha256 = "sha256-6Z0mOmp+/IXx2pkcan85rvm5grxq+kGNayj9YDChdp4=";
};
preConfigure = ''
export INSTALL_MOD_PATH="$out"
'';
hardeningDisable = [ "pic" ];
nativeBuildInputs = kernel.moduleBuildDependencies;
makeFlags = kernelModuleMakeFlags ++ [
"KDIR=${kernel.dev}/lib/modules/${kernel.modDirVersion}/build"
];
meta = {
homepage = "https://github.com/patjak/bcwc_pcie";
description = "Linux driver for the Facetime HD (Broadcom 1570) PCIe webcam";
license = lib.licenses.gpl2Only;
maintainers = with lib.maintainers; [
womfoo
kraem
];
platforms = [
"i686-linux"
"x86_64-linux"
];
};
}